torque Torque Game Engine Documentation
TGE Version 1.5.2

fluid Class Reference

#include <fluid.h>


Public Types

typedef f32 compute_fog_fn (f32 DeltaZ, f32 D)

Public Member Functions

 fluid (void)
 ~fluid ()
void Render (bool &EyeSubmerged)
void SetEyePosition (f32 X, f32 Y, f32 Z)
void SetFrustrumPlanes (f32 *pFrustrumPlanes)
void SetInfo (f32 &X0, f32 &Y0, f32 &SizeX, f32 &SizeY, f32 SurfaceZ, f32 WaveAmplitude, f32 &Opacity, f32 &EnvMapIntensity, s32 RemoveWetEdges, bool UseDepthMap, f32 TessellationSurface, f32 TessellationShore, f32 SurfaceParallax, f32 FlowAngle, f32 FlowRate, f32 DistortGridScale, f32 DistortMagnitude, f32 DistortTime, ColorF SpecColor, F32 SpecPower, bool tiling, u32 terrainSize, u32 terrainBlockSize)
void SetTerrainData (u16 *pTerrainData)
void SetTextures (TextureHandle Base, TextureHandle EnvMapOverTexture, TextureHandle EnvMapUnderTexture, TextureHandle ShoreTexture, TextureHandle DepthTexture, TextureHandle ShoreDepthTexture, TextureHandle SpecMaskTexture)
void SetLightMapTexture (TextureHandle LightMapTexture)
void SetFogParameters (f32 R, f32 G, f32 B, f32 VisibleDistance)
void SetFogFn (compute_fog_fn *pFogFn)
s32 IsFluidAtXY (f32 X, f32 Y) const

Data Fields

bool mTile
s32 m_SquareX0
s32 m_SquareY0
s32 m_SquaresInX
s32 m_SquaresInY
s32 m_ShowWire
s32 m_ShowNodes
s32 m_ShowBlocks
s32 m_ShowBaseA
s32 m_ShowBaseB
s32 m_ShowLightMap
s32 m_ShowEnvMap
s32 m_ShowFog

Private Member Functions

F32 DISTANCE (F32 x, F32 y, F32 z)
s32 GetAcceptBit (s32 Level, s32 IndexX, s32 IndexY) const
s32 GetRejectBit (s32 Level, s32 IndexX, s32 IndexY) const
void SetAcceptBit (s32 Level, s32 IndexX, s32 IndexY, s32 Value)
void SetRejectBit (s32 Level, s32 IndexX, s32 IndexY, s32 Value)
void BuildLowerMasks (void)
void RebuildMasks (void)
void FloodFill (u8 *pGrid, s32 x, s32 y, s32 SizeX, s32 SizeY)
void RunQuadTree (bool &EyeSubmerged)
f32 ComputeLOD (f32 Distance)
byte ComputeClipBits (f32 X, f32 Y, f32 Z)
void ProcessNode (node &Node)
void ProcessBlock (block &Block)
void ProcessBlockLODHigh (block &Block)
void ProcessBlockLODMorph (block &Block)
void ProcessBlockLODTrans (block &Block)
void ProcessBlockLODLow (block &Block)
void SetupVert (f32 X, f32 Y, f32 Distance, vertex *pV)
void InterpolateVerts (vertex *pV0, vertex *pV1, vertex *pV2, vertex *pV3, vertex *pV4, f32 LOD0, f32 LOD4)
void InterpolateVert (vertex *pV0, vertex *pV1, vertex *pV2, f32 LOD)
void ReleaseVertexMemory (void)
vertexAcquireVertices (s32 Count)
void AddTriangleIndices (s16 I1, s16 I2, s16 I3)
void CalcVertSpecular ()

Private Attributes

f32 m_DepthTexelX
f32 m_DepthTexelY
s32 m_BlocksInX
s32 m_BlocksInY
f32 m_SurfaceZ
s32 m_RemoveWetEdges
s32 m_HighResMode
plane m_Plane [6]
Point3F m_Eye
f32 m_Seconds
f32 m_BaseSeconds
rgba m_FogColor
f32 m_VisibleDistance
f32 m_Opacity
f32 m_EnvMapIntensity
f32 m_WaveAmplitude
f32 m_WaveFactor
u16 * m_pTerrain
bool m_UseDepthMap
F32 m_TessellationSurface
F32 m_TessellationShore
F32 m_SurfaceParallax
F32 m_FlowAngle
F32 m_FlowRate
F32 m_FlowMagnitudeS
F32 m_FlowMagnitudeT
F32 m_DistortGridScale
F32 m_DistortMagnitude
F32 m_DistortTime
ColorF m_SpecColor
F32 m_SpecPower
U32 m_TerrainSize
U32 m_TerrainBlockSize
U32 m_TerrainBlockShift
TextureHandle m_BaseTexture
TextureHandle m_EnvMapOverTexture
TextureHandle m_EnvMapUnderTexture
TextureHandle m_LightMapTexture
TextureHandle m_ShoreTexture
TextureHandle m_DepthTexture
TextureHandle m_ShoreDepthTexture
TextureHandle m_SpecMaskTex
f32 m_Step [5]
compute_fog_fnm_pFogFn
byte m_RejectMask [1+1+2+8+32+128]
byte m_AcceptMask [1+1+2+8+32]

Static Private Attributes

static s32 m_MaskOffset [6]
static vertexm_pVertex
static s32 m_VAllocated
static s32 m_VUsed
static s16 * m_pIndex
static s16 * m_pINext
static s16 m_IOffset
static s32 m_IAllocated
static s32 m_IUsed
static s32 m_Instances

Data Structures

struct  block
struct  node
struct  plane
struct  rgba
struct  uv
struct  vertex
struct  xyz


Member Typedef Documentation

typedef f32 fluid::compute_fog_fn(f32 DeltaZ, f32 D)


Constructor & Destructor Documentation

fluid::fluid ( void   ) 

fluid::~fluid (  ) 


Member Function Documentation

void fluid::Render ( bool &  EyeSubmerged  ) 

void fluid::SetEyePosition ( f32  X,
f32  Y,
f32  Z 
) [inline]

void fluid::SetFrustrumPlanes ( f32 *  pFrustrumPlanes  ) 

void fluid::SetInfo ( f32 &  X0,
f32 &  Y0,
f32 &  SizeX,
f32 &  SizeY,
f32  SurfaceZ,
f32  WaveAmplitude,
f32 &  Opacity,
f32 &  EnvMapIntensity,
s32  RemoveWetEdges,
bool  UseDepthMap,
f32  TessellationSurface,
f32  TessellationShore,
f32  SurfaceParallax,
f32  FlowAngle,
f32  FlowRate,
f32  DistortGridScale,
f32  DistortMagnitude,
f32  DistortTime,
ColorF  SpecColor,
F32  SpecPower,
bool  tiling,
u32  terrainSize,
u32  terrainBlockSize 
)

void fluid::SetTerrainData ( u16 *  pTerrainData  ) 

void fluid::SetTextures ( TextureHandle  Base,
TextureHandle  EnvMapOverTexture,
TextureHandle  EnvMapUnderTexture,
TextureHandle  ShoreTexture,
TextureHandle  DepthTexture,
TextureHandle  ShoreDepthTexture,
TextureHandle  SpecMaskTexture 
)

void fluid::SetLightMapTexture ( TextureHandle  LightMapTexture  ) 

void fluid::SetFogParameters ( f32  R,
f32  G,
f32  B,
f32  VisibleDistance 
)

void fluid::SetFogFn ( compute_fog_fn pFogFn  ) 

s32 fluid::IsFluidAtXY ( f32  X,
f32  Y 
) const

F32 fluid::DISTANCE ( F32  x,
F32  y,
F32  z 
) [inline, private]

s32 fluid::GetAcceptBit ( s32  Level,
s32  IndexX,
s32  IndexY 
) const [private]

s32 fluid::GetRejectBit ( s32  Level,
s32  IndexX,
s32  IndexY 
) const [private]

void fluid::SetAcceptBit ( s32  Level,
s32  IndexX,
s32  IndexY,
s32  Value 
) [private]

void fluid::SetRejectBit ( s32  Level,
s32  IndexX,
s32  IndexY,
s32  Value 
) [private]

void fluid::BuildLowerMasks ( void   )  [private]

void fluid::RebuildMasks ( void   )  [private]

void fluid::FloodFill ( u8 *  pGrid,
s32  x,
s32  y,
s32  SizeX,
s32  SizeY 
) [private]

void fluid::RunQuadTree ( bool &  EyeSubmerged  )  [private]

f32 fluid::ComputeLOD ( f32  Distance  )  [private]

byte fluid::ComputeClipBits ( f32  X,
f32  Y,
f32  Z 
) [private]

void fluid::ProcessNode ( node Node  )  [private]

void fluid::ProcessBlock ( block Block  )  [private]

void fluid::ProcessBlockLODHigh ( block Block  )  [private]

void fluid::ProcessBlockLODMorph ( block Block  )  [private]

void fluid::ProcessBlockLODTrans ( block Block  )  [private]

void fluid::ProcessBlockLODLow ( block Block  )  [private]

void fluid::SetupVert ( f32  X,
f32  Y,
f32  Distance,
vertex pV 
) [private]

void fluid::InterpolateVerts ( vertex pV0,
vertex pV1,
vertex pV2,
vertex pV3,
vertex pV4,
f32  LOD0,
f32  LOD4 
) [private]

void fluid::InterpolateVert ( vertex pV0,
vertex pV1,
vertex pV2,
f32  LOD 
) [private]

void fluid::ReleaseVertexMemory ( void   )  [private]

vertex* fluid::AcquireVertices ( s32  Count  )  [private]

void fluid::AddTriangleIndices ( s16  I1,
s16  I2,
s16  I3 
) [private]

void fluid::CalcVertSpecular (  )  [private]


Field Documentation

f32 fluid::m_DepthTexelX [private]

f32 fluid::m_DepthTexelY [private]

s32 fluid::m_BlocksInX [private]

s32 fluid::m_BlocksInY [private]

f32 fluid::m_SurfaceZ [private]

s32 fluid::m_RemoveWetEdges [private]

s32 fluid::m_HighResMode [private]

plane fluid::m_Plane[6] [private]

Point3F fluid::m_Eye [private]

f32 fluid::m_Seconds [private]

f32 fluid::m_BaseSeconds [private]

f32 fluid::m_VisibleDistance [private]

f32 fluid::m_Opacity [private]

f32 fluid::m_EnvMapIntensity [private]

f32 fluid::m_WaveAmplitude [private]

f32 fluid::m_WaveFactor [private]

u16* fluid::m_pTerrain [private]

bool fluid::m_UseDepthMap [private]

TextureHandle fluid::m_BaseTexture [private]

TextureHandle fluid::m_EnvMapOverTexture [private]

TextureHandle fluid::m_EnvMapUnderTexture [private]

TextureHandle fluid::m_LightMapTexture [private]

TextureHandle fluid::m_ShoreTexture [private]

TextureHandle fluid::m_DepthTexture [private]

TextureHandle fluid::m_ShoreDepthTexture [private]

TextureHandle fluid::m_SpecMaskTex [private]

f32 fluid::m_Step[5] [private]

s32 fluid::m_MaskOffset[6] [static, private]

byte fluid::m_RejectMask[1+1+2+8+32+128] [private]

byte fluid::m_AcceptMask[1+1+2+8+32] [private]

vertex* fluid::m_pVertex [static, private]

s32 fluid::m_VAllocated [static, private]

s32 fluid::m_VUsed [static, private]

s16* fluid::m_pIndex [static, private]

s16* fluid::m_pINext [static, private]

s16 fluid::m_IOffset [static, private]

s32 fluid::m_IAllocated [static, private]

s32 fluid::m_IUsed [static, private]

s32 fluid::m_Instances [static, private]




All Rights Reserved GarageGames.com, Inc. 1999-2005
Auto-magically Generated with Doxygen