|
bwmodel
A modeling environment for Minecraft Bedwars
|
#include <heatmap.h>
Public Member Functions | |
| void | concentrate_at (std::vector< std::pair< int, int > > points) |
| void | filter (int kernel_radius) |
| void | merge_with (HeatMap &other) |
Public Member Functions inherited from bwmodel::GridInterface< double, int > | |
| int | width () const |
| int | height () const |
Static Public Member Functions | |
| static std::unique_ptr< HeatMap > | uniform (int width, int height) |
Protected Member Functions | |
| const Grid< double > & | backing () const override |
Protected Member Functions inherited from bwmodel::GridInterface< double, int > | |
| void | assert_grid_invariant () |
A two-dimensional probability distribution.
|
overrideprotectedvirtual |
Internally retrieves the backing (nested vector) for helper function generation in GridInterface.
Implements bwmodel::GridInterface< double, int >.
| void bwmodel::HeatMap::concentrate_at | ( | std::vector< std::pair< int, int > > | points | ) |
Concentrates all of the distribution at the given points.
| void bwmodel::HeatMap::filter | ( | int | kernel_radius | ) |
Assigns each point in the heat map to the average of its neighbors within a square of size kernel_radius.
| void bwmodel::HeatMap::merge_with | ( | HeatMap & | other | ) |
TODO: document. basically this is when you have one player kill another so you can know they are in the same location but you don't know where so you just adjust both players location heat maps to reflect this. the other player obviously just gets put back at their base but you get the idea.
|
static |
Creates a uniformly-distributed heat map with dimensions width and height.