Modifier and Type | Class and Description |
---|---|
static class |
MergedFOV.MergeType
Used when constructing a MergedFOV to indicate what kind of merge should be performed.
|
Constructor and Description |
---|
MergedFOV() |
Modifier and Type | Method and Description |
---|---|
float[][] |
calculateFOV(float[][] resistanceMap,
int startx,
int starty,
float radius)
Calculates the Field of View in the same manner as the version with more
parameters.
|
float[][] |
calculateFOV(float[][] resistanceMap,
int startx,
int starty,
float force,
float decay,
RadiusStrategy radiusStrategy)
Calculates the Field Of View for the provided map from the given x, y
coordinates.
|
public float[][] calculateFOV(float[][] resistanceMap, int startx, int starty, float force, float decay, RadiusStrategy radiusStrategy)
FOVSolver
calculateFOV
in interface FOVSolver
resistanceMap
- the grid of cells to calculate onstartx
- the horizontal component of the starting locationstarty
- the vertical component of the starting locationforce
- the power of the raydecay
- how much the light is reduced for each whole integer step in
distanceradiusStrategy
- provides a means to calculate the radius as desiredpublic float[][] calculateFOV(float[][] resistanceMap, int startx, int starty, float radius)
FOVSolver
calculateFOV
in interface FOVSolver
resistanceMap
- the grid of cells to calculate on