Space Engineers
Classes | Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | List of all members
VRage.Voxels.MyCellCoord Struct Reference
Inheritance diagram for VRage.Voxels.MyCellCoord:

Classes

class  EqualityComparer
 

Public Member Functions

override bool Equals (object obj)
 
override int GetHashCode ()
 
 MyCellCoord (int lod, Vector3I coordInLod)
 
 MyCellCoord (int lod, ref Vector3I coordInLod)
 
void SetUnpack (UInt32 id)
 
void SetUnpack (UInt64 id)
 
UInt32 PackId32 ()
 
UInt64 PackId64 ()
 
bool IsCoord64Valid ()
 
bool Equals (MyCellCoord other)
 
override string ToString ()
 
int CompareTo (MyCellCoord other)
 

Static Public Member Functions

static int UnpackLod (UInt64 id)
 
static Vector3I UnpackCoord (UInt64 id)
 
static UInt64 PackId64Static (int lod, Vector3I coordInLod)
 
static UInt64 GetClipmapCellHash (uint clipmap, ulong cellId)
 
static bool operator== (MyCellCoord x, MyCellCoord y)
 
static bool operator!= (MyCellCoord x, MyCellCoord y)
 
static MyCellCoord ()
 

Public Attributes

const int BITS_LOD = 4
 
const int BITS_X_32 = 10
 
const int BITS_Y_32 = 8
 
const int BITS_Z_32 = 10
 
const int BITS_X_64 = 20
 
const int BITS_Y_64 = 20
 
const int BITS_Z_64 = 20
 
const int SHIFT_Z_32 = 0
 
const int SHIFT_Y_32 = SHIFT_Z_32 + BITS_Z_32
 
const int SHIFT_X_32 = SHIFT_Y_32 + BITS_Y_32
 
const int SHIFT_LOD_32 = SHIFT_X_32 + BITS_X_32
 
const int SHIFT_Z_64 = 0
 
const int SHIFT_Y_64 = SHIFT_Z_64 + BITS_Z_64
 
const int SHIFT_X_64 = SHIFT_Y_64 + BITS_Y_64
 
const int SHIFT_LOD_64 = SHIFT_X_64 + BITS_X_64
 
const int MASK_LOD = (1 << BITS_LOD) - 1
 
const int MASK_X_32 = (1 << BITS_X_32) - 1
 
const int MASK_Y_32 = (1 << BITS_Y_32) - 1
 
const int MASK_Z_32 = (1 << BITS_Z_32) - 1
 
const int MASK_X_64 = (1 << BITS_X_64) - 1
 
const int MASK_Y_64 = (1 << BITS_Y_64) - 1
 
const int MASK_Z_64 = (1 << BITS_Z_64) - 1
 
const int MAX_LOD_COUNT = 1 << BITS_LOD
 
int Lod
 0 is the most detailed. More...
 
Vector3I CoordInLod
 

Static Public Attributes

static readonly EqualityComparer Comparer = new EqualityComparer()
 

Detailed Description

Definition at line 10 of file MyCellCoord.cs.

Constructor & Destructor Documentation

VRage.Voxels.MyCellCoord.MyCellCoord ( int  lod,
Vector3I  coordInLod 
)
inline

Definition at line 65 of file MyCellCoord.cs.

VRage.Voxels.MyCellCoord.MyCellCoord ( int  lod,
ref Vector3I  coordInLod 
)
inline

Definition at line 70 of file MyCellCoord.cs.

static VRage.Voxels.MyCellCoord.MyCellCoord ( )
inlinestatic

Definition at line 187 of file MyCellCoord.cs.

Member Function Documentation

int VRage.Voxels.MyCellCoord.CompareTo ( MyCellCoord  other)
inline

Definition at line 215 of file MyCellCoord.cs.

override bool VRage.Voxels.MyCellCoord.Equals ( object  obj)
inline

Definition at line 12 of file MyCellCoord.cs.

bool VRage.Voxels.MyCellCoord.Equals ( MyCellCoord  other)
inline

Definition at line 176 of file MyCellCoord.cs.

static UInt64 VRage.Voxels.MyCellCoord.GetClipmapCellHash ( uint  clipmap,
ulong  cellId 
)
inlinestatic

Definition at line 158 of file MyCellCoord.cs.

override int VRage.Voxels.MyCellCoord.GetHashCode ( )
inline

Definition at line 18 of file MyCellCoord.cs.

bool VRage.Voxels.MyCellCoord.IsCoord64Valid ( )
inline

Definition at line 147 of file MyCellCoord.cs.

static bool VRage.Voxels.MyCellCoord.operator!= ( MyCellCoord  x,
MyCellCoord  y 
)
inlinestatic

Definition at line 171 of file MyCellCoord.cs.

static bool VRage.Voxels.MyCellCoord.operator== ( MyCellCoord  x,
MyCellCoord  y 
)
inlinestatic

Definition at line 166 of file MyCellCoord.cs.

UInt32 VRage.Voxels.MyCellCoord.PackId32 ( )
inline

Definition at line 119 of file MyCellCoord.cs.

UInt64 VRage.Voxels.MyCellCoord.PackId64 ( )
inline

Definition at line 133 of file MyCellCoord.cs.

static UInt64 VRage.Voxels.MyCellCoord.PackId64Static ( int  lod,
Vector3I  coordInLod 
)
inlinestatic

Definition at line 110 of file MyCellCoord.cs.

void VRage.Voxels.MyCellCoord.SetUnpack ( UInt32  id)
inline

Definition at line 76 of file MyCellCoord.cs.

void VRage.Voxels.MyCellCoord.SetUnpack ( UInt64  id)
inline

Definition at line 86 of file MyCellCoord.cs.

override string VRage.Voxels.MyCellCoord.ToString ( )
inline

Definition at line 181 of file MyCellCoord.cs.

static Vector3I VRage.Voxels.MyCellCoord.UnpackCoord ( UInt64  id)
inlinestatic

Definition at line 101 of file MyCellCoord.cs.

static int VRage.Voxels.MyCellCoord.UnpackLod ( UInt64  id)
inlinestatic

Definition at line 96 of file MyCellCoord.cs.

Member Data Documentation

const int VRage.Voxels.MyCellCoord.BITS_LOD = 4

Definition at line 26 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.BITS_X_32 = 10

Definition at line 28 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.BITS_X_64 = 20

Definition at line 32 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.BITS_Y_32 = 8

Definition at line 29 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.BITS_Y_64 = 20

Definition at line 33 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.BITS_Z_32 = 10

Definition at line 30 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.BITS_Z_64 = 20

Definition at line 34 of file MyCellCoord.cs.

readonly EqualityComparer VRage.Voxels.MyCellCoord.Comparer = new EqualityComparer()
static

Definition at line 213 of file MyCellCoord.cs.

Vector3I VRage.Voxels.MyCellCoord.CoordInLod

Definition at line 63 of file MyCellCoord.cs.

int VRage.Voxels.MyCellCoord.Lod

0 is the most detailed.

Definition at line 61 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.MASK_LOD = (1 << BITS_LOD) - 1

Definition at line 46 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.MASK_X_32 = (1 << BITS_X_32) - 1

Definition at line 48 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.MASK_X_64 = (1 << BITS_X_64) - 1

Definition at line 52 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.MASK_Y_32 = (1 << BITS_Y_32) - 1

Definition at line 49 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.MASK_Y_64 = (1 << BITS_Y_64) - 1

Definition at line 53 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.MASK_Z_32 = (1 << BITS_Z_32) - 1

Definition at line 50 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.MASK_Z_64 = (1 << BITS_Z_64) - 1

Definition at line 54 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.MAX_LOD_COUNT = 1 << BITS_LOD

Definition at line 56 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.SHIFT_LOD_32 = SHIFT_X_32 + BITS_X_32

Definition at line 39 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.SHIFT_LOD_64 = SHIFT_X_64 + BITS_X_64

Definition at line 44 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.SHIFT_X_32 = SHIFT_Y_32 + BITS_Y_32

Definition at line 38 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.SHIFT_X_64 = SHIFT_Y_64 + BITS_Y_64

Definition at line 43 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.SHIFT_Y_32 = SHIFT_Z_32 + BITS_Z_32

Definition at line 37 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.SHIFT_Y_64 = SHIFT_Z_64 + BITS_Z_64

Definition at line 42 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.SHIFT_Z_32 = 0

Definition at line 36 of file MyCellCoord.cs.

const int VRage.Voxels.MyCellCoord.SHIFT_Z_64 = 0

Definition at line 41 of file MyCellCoord.cs.


The documentation for this struct was generated from the following file: