Space Engineers
Classes | Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes | Static Protected Attributes | Properties | List of all members
VRage.Voxels.MyClipmap Class Reference

Classes

struct  VoxelKey
 

Public Types

enum  CellState { CellState.Invalid, CellState.Pending, CellState.Loaded }
 

Public Member Functions

delegate VRageMath.ContainmentType PruningFunc (ref BoundingBox bb, bool lazy)
 
 MyClipmap (uint id, MyClipmapScaleEnum scaleGroup, MatrixD worldMatrix, Vector3I sizeLod0, IMyClipmapCellHandler cellProvider, Vector3D massiveCenter, float massiveRadius, PruningFunc prunningFunc)
 
void UpdateWorldAABB (out BoundingBoxD worldAabb)
 
void UpdateWorldMatrix (ref MatrixD worldMatrix, bool sortCellsIntoCullObjects)
 
void LoadContent ()
 
void UnloadContent ()
 
void InvalidateRange (Vector3I minCellLod0, Vector3I maxCellLod0)
 
void UpdateCell (MyRenderMessageUpdateClipmapCell msg)
 
void DebugDraw ()
 
void DebugDrawMergedMeshCells ()
 
void RequestMergeAll ()
 
bool IsDitheringInProgress ()
 
Vector3I LodSizeMinusOne (int lod)
 

Static Public Member Functions

static void UnloadCache ()
 
static bool UpdateLodRanges (float[][] lodDistances)
 
static void ComputeLodViewBounds (MyClipmapScaleEnum scale, int lod, out float min, out float max)
 
static void AddToUpdate (Vector3D cameraPos, MyClipmap clipmap)
 
static void RemoveFromUpdate (MyClipmap clipmap)
 
static void UpdateQueued (Vector3D cameraPos, Vector3 cameraForward, float farPlaneDistance, float largeDistanceFarPlane)
 
static void DebugDrawClipmaps ()
 
static void DebugDrawMergedCells ()
 

Static Public Attributes

static Func< BoundingFrustumDCameraFrustumGetter
 
static bool UseCache = true
 
static bool NeedsResetCache = false
 
static LRUCache< UInt64, MyClipmap_CellDataCellsCache
 
static bool UseDithering = true
 
static bool UseLodCut = true
 
static bool UseQueries = true
 
static readonly Vector4[] LOD_COLORS
 
static float[][] DebugRanges
 

Static Protected Attributes

static Dictionary< UInt64, MyClipmap_CellDataPendingCacheCellData = new Dictionary<UInt64, MyClipmap_CellData>()
 
static int ClippingCacheHits = 0
 
static int ClippingCacheMisses = 0
 

Properties

MatrixD WorldMatrix [get]
 
uint Id [get]
 
static float[][] LodRangeGroups [get]
 

Detailed Description

Definition at line 14 of file MyClipmap.cs.

Member Enumeration Documentation

Enumerator
Invalid 
Pending 
Loaded 

Definition at line 33 of file MyClipmap.LodLevel.cs.

Constructor & Destructor Documentation

VRage.Voxels.MyClipmap.MyClipmap ( uint  id,
MyClipmapScaleEnum  scaleGroup,
MatrixD  worldMatrix,
Vector3I  sizeLod0,
IMyClipmapCellHandler  cellProvider,
Vector3D  massiveCenter,
float  massiveRadius,
PruningFunc  prunningFunc 
)
inline

Definition at line 71 of file MyClipmap.cs.

Member Function Documentation

static void VRage.Voxels.MyClipmap.AddToUpdate ( Vector3D  cameraPos,
MyClipmap  clipmap 
)
inlinestatic

Definition at line 80 of file MyClipmap.Update.cs.

static void VRage.Voxels.MyClipmap.ComputeLodViewBounds ( MyClipmapScaleEnum  scale,
int  lod,
out float  min,
out float  max 
)
inlinestatic

Definition at line 72 of file MyClipmap.Update.cs.

void VRage.Voxels.MyClipmap.DebugDraw ( )
inline

Definition at line 288 of file MyClipmap.cs.

static void VRage.Voxels.MyClipmap.DebugDrawClipmaps ( )
inlinestatic

Definition at line 158 of file MyClipmap.Update.cs.

static void VRage.Voxels.MyClipmap.DebugDrawMergedCells ( )
inlinestatic

Definition at line 170 of file MyClipmap.Update.cs.

void VRage.Voxels.MyClipmap.DebugDrawMergedMeshCells ( )
inline

Definition at line 296 of file MyClipmap.cs.

void VRage.Voxels.MyClipmap.InvalidateRange ( Vector3I  minCellLod0,
Vector3I  maxCellLod0 
)
inline
Parameters
minCellLod0Inclusive.
maxCellLod0Inclusive.

Definition at line 125 of file MyClipmap.cs.

bool VRage.Voxels.MyClipmap.IsDitheringInProgress ( )
inline

Definition at line 320 of file MyClipmap.cs.

void VRage.Voxels.MyClipmap.LoadContent ( )
inline

Definition at line 110 of file MyClipmap.cs.

Vector3I VRage.Voxels.MyClipmap.LodSizeMinusOne ( int  lod)
inline

Definition at line 331 of file MyClipmap.cs.

delegate VRageMath.ContainmentType VRage.Voxels.MyClipmap.PruningFunc ( ref BoundingBox  bb,
bool  lazy 
)
static void VRage.Voxels.MyClipmap.RemoveFromUpdate ( MyClipmap  clipmap)
inlinestatic

Definition at line 90 of file MyClipmap.Update.cs.

void VRage.Voxels.MyClipmap.RequestMergeAll ( )
inline

Definition at line 314 of file MyClipmap.cs.

static void VRage.Voxels.MyClipmap.UnloadCache ( )
inlinestatic

Definition at line 301 of file MyClipmap.cs.

void VRage.Voxels.MyClipmap.UnloadContent ( )
inline

Definition at line 115 of file MyClipmap.cs.

void VRage.Voxels.MyClipmap.UpdateCell ( MyRenderMessageUpdateClipmapCell  msg)
inline

Definition at line 153 of file MyClipmap.cs.

static bool VRage.Voxels.MyClipmap.UpdateLodRanges ( float  lodDistances[][])
inlinestatic

Definition at line 49 of file MyClipmap.Update.cs.

static void VRage.Voxels.MyClipmap.UpdateQueued ( Vector3D  cameraPos,
Vector3  cameraForward,
float  farPlaneDistance,
float  largeDistanceFarPlane 
)
inlinestatic

Definition at line 114 of file MyClipmap.Update.cs.

void VRage.Voxels.MyClipmap.UpdateWorldAABB ( out BoundingBoxD  worldAabb)
inline

Definition at line 94 of file MyClipmap.cs.

void VRage.Voxels.MyClipmap.UpdateWorldMatrix ( ref MatrixD  worldMatrix,
bool  sortCellsIntoCullObjects 
)
inline

Definition at line 100 of file MyClipmap.cs.

Member Data Documentation

Func<BoundingFrustumD> VRage.Voxels.MyClipmap.CameraFrustumGetter
static

Definition at line 30 of file MyClipmap.cs.

LRUCache<UInt64, MyClipmap_CellData> VRage.Voxels.MyClipmap.CellsCache
static

Definition at line 59 of file MyClipmap.cs.

int VRage.Voxels.MyClipmap.ClippingCacheHits = 0
staticprotected

Definition at line 61 of file MyClipmap.cs.

int VRage.Voxels.MyClipmap.ClippingCacheMisses = 0
staticprotected

Definition at line 62 of file MyClipmap.cs.

float [][] VRage.Voxels.MyClipmap.DebugRanges
static

Definition at line 24 of file MyClipmap.Update.cs.

readonly Vector4 [] VRage.Voxels.MyClipmap.LOD_COLORS
static
Initial value:
=
{
new Vector4( 1, 0, 0, 1 ),
new Vector4( 0, 1, 0, 1 ),
new Vector4( 0, 0, 1, 1 ),
new Vector4( 1, 1, 0, 1 ),
new Vector4( 0, 1, 1, 1 ),
new Vector4( 1, 0, 1, 1 ),
new Vector4( 0.5f, 0, 1, 1 ),
new Vector4( 0.5f, 1, 0, 1 ),
new Vector4( 1, 0, 0.5f, 1 ),
new Vector4( 0, 1, 0.5f, 1 ),
new Vector4( 1, 0.5f, 0, 1 ),
new Vector4( 0, 0.5f, 1, 1 ),
new Vector4( 0.5f, 1, 1, 1 ),
new Vector4( 1, 0.5f, 1, 1 ),
new Vector4( 1, 1, 0.5f, 1 ),
new Vector4( 0.5f, 0.5f, 1, 1 ),
}

Definition at line 264 of file MyClipmap.cs.

bool VRage.Voxels.MyClipmap.NeedsResetCache = false
static

Definition at line 58 of file MyClipmap.cs.

Dictionary<UInt64, MyClipmap_CellData> VRage.Voxels.MyClipmap.PendingCacheCellData = new Dictionary<UInt64, MyClipmap_CellData>()
staticprotected

Definition at line 60 of file MyClipmap.cs.

bool VRage.Voxels.MyClipmap.UseCache = true
static

Definition at line 57 of file MyClipmap.cs.

bool VRage.Voxels.MyClipmap.UseDithering = true
static

Definition at line 64 of file MyClipmap.cs.

bool VRage.Voxels.MyClipmap.UseLodCut = true
static

Definition at line 65 of file MyClipmap.cs.

bool VRage.Voxels.MyClipmap.UseQueries = true
static

Definition at line 66 of file MyClipmap.cs.

Property Documentation

uint VRage.Voxels.MyClipmap.Id
get

Definition at line 92 of file MyClipmap.cs.

float [][] VRage.Voxels.MyClipmap.LodRangeGroups
staticget

Definition at line 78 of file MyClipmap.Update.cs.

MatrixD VRage.Voxels.MyClipmap.WorldMatrix
get

Definition at line 69 of file MyClipmap.cs.


The documentation for this class was generated from the following files: