A 2D grid of byte values that can be stored in grayscale PNG files.
More...
|
| ByteGrid (int width, int height) |
|
| ByteGrid (byte[,] data) |
|
float | SampledRead (float x, float y) |
| Performs bilinear interpolation to get values lying between discrete grid points. More...
|
|
bool | IsInRange (float x, float y) |
| Returns true if the specified coordinates are within the bounds of the grid. More...
|
|
override unsafe Bitmap | GenerateBitmap () |
| Generates a bitmap representation of the grid.
|
|
T | ClampedRead (int x, int y) |
| Reads a value in the grid and automatically clamps out of bound values of x or y . More...
|
|
void | Save ([NotNull, Localizable(false)] string path) |
| Saves the grid to a PNG file. More...
|
|
void | Save ([NotNull] Stream stream) |
| Saves the grid to a PNG stream. More...
|
|
|
int | Width |
| The width of the grid (number of values along the X axis). More...
|
|
int | Height |
| The height of the grid (number of values along the Y axis). More...
|
|
| Grid (int width, int height) |
| Creates a new empty grid. More...
|
|
| Grid (T[,] data) |
| Creates a new grid based on an existing array. More...
|
|
internal readonly T [,] | Data |
| The internal array containing the values. More...
|
|
virtual T | this[int x, int y] [get, set] |
|
A 2D grid of byte values that can be stored in grayscale PNG files.
◆ IsInRange()
bool OmegaEngine.Values.ByteGrid.IsInRange |
( |
float |
x, |
|
|
float |
y |
|
) |
| |
Returns true
if the specified coordinates are within the bounds of the grid.
◆ Load()
static ByteGrid OmegaEngine.Values.ByteGrid.Load |
( |
[NotNull] Stream |
stream | ) |
|
|
inlinestatic |
Loads a grid from a PNG stream.
◆ SampledRead()
float OmegaEngine.Values.ByteGrid.SampledRead |
( |
float |
x, |
|
|
float |
y |
|
) |
| |
|
inline |
Performs bilinear interpolation to get values lying between discrete grid points.
The documentation for this class was generated from the following file:
- OmegaEngine/Values/ByteGrid.cs