Struct DebugGrid
A DEBUG GRID sub-block (09 § 15): the replication grid every push session's cells are keyed on. Sent to a debugging session with its first
frame and with every RESET.
public readonly struct DebugGrid : IEquatable<DebugGrid>
- Implements
- Inherited Members
Remarks
GRID := f64 originX | f64 originY | f64 originZ | f64 cellM | varu dimX | varu dimY | varu dimZ (dimZ = 1 in a flat grid)
Cell (cx, cy, cz) spans [origin + c·cell, origin + (c + 1)·cell) on each axis.
Constructors
DebugGrid(double, double, double, double, int, int, int)
A DEBUG GRID sub-block (09 § 15): the replication grid every push session's cells are keyed on. Sent to a debugging session with its first
frame and with every RESET.
public DebugGrid(double OriginX, double OriginY, double OriginZ, double CellM, int DimX, int DimY, int DimZ)
Parameters
OriginXdoubleThe grid's lowest x, in metres.
OriginYdoubleThe grid's lowest y.
OriginZdoubleThe grid's lowest z.
CellMdoubleThe cell side, in metres.
DimXintCells along x.
DimYintCells along y.
DimZintCells along z; 1 in a flat grid.
Remarks
GRID := f64 originX | f64 originY | f64 originZ | f64 cellM | varu dimX | varu dimY | varu dimZ (dimZ = 1 in a flat grid)
Cell (cx, cy, cz) spans [origin + c·cell, origin + (c + 1)·cell) on each axis.
Fields
MaxBytes
The largest payload Write(ref WireWriter) produces.
public const int MaxBytes = 47
Field Value
Properties
CellM
The cell side, in metres.
public double CellM { get; init; }
Property Value
DimX
Cells along x.
public int DimX { get; init; }
Property Value
DimY
Cells along y.
public int DimY { get; init; }
Property Value
DimZ
Cells along z; 1 in a flat grid.
public int DimZ { get; init; }
Property Value
OriginX
The grid's lowest x, in metres.
public double OriginX { get; init; }
Property Value
OriginY
The grid's lowest y.
public double OriginY { get; init; }
Property Value
OriginZ
The grid's lowest z.
public double OriginZ { get; init; }
Property Value
Methods
Deconstruct(out double, out double, out double, out double, out int, out int, out int)
public void Deconstruct(out double OriginX, out double OriginY, out double OriginZ, out double CellM, out int DimX, out int DimY, out int DimZ)
Parameters
Equals(object)
public override bool Equals(object obj)
Parameters
objobject
Returns
Equals(DebugGrid)
public bool Equals(DebugGrid other)
Parameters
otherDebugGrid
Returns
GetHashCode()
public override int GetHashCode()
Returns
Read(ReadOnlySpan<byte>)
Reads a payload.
public static DebugGrid Read(ReadOnlySpan<byte> payload)
Parameters
payloadReadOnlySpan<byte>The sub-block's payload.
Returns
- DebugGrid
The grid.
Exceptions
- WireFormatException
The payload is truncated or has bytes left over.
ToString()
public override string ToString()
Returns
Write(ref WireWriter)
Writes the payload, without the sub-block's type and length.
public void Write(ref WireWriter w)
Parameters
wWireWriterThe writer.
Operators
operator ==(DebugGrid, DebugGrid)
public static bool operator ==(DebugGrid left, DebugGrid right)
Parameters
Returns
operator !=(DebugGrid, DebugGrid)
public static bool operator !=(DebugGrid left, DebugGrid right)