Bounded Water Object¶
-
class BoundedWaterObject¶
Public Functions
-
virtual void RestoreDeviceObjects(crossplatform::RenderPlatform *r)¶
Platform-dependent function called when initializing the water object.
-
void InvalidateDeviceObjects()¶
Platform-dependent function called when uinitializing the water object.
-
void PreRenderUpdate(crossplatform::GraphicsDeviceContext &deviceContext, float real_time_seconds)¶
Once per-frame update. Do this before any rendering each frame.
-
vec4 *getWaterProbeOutputs()¶
Get the Array of results from the water probes associated with this water object.
-
void setWaterProbeOutputs(vec4 *outputs)¶
Set the Array of results from the water probes associated with this water object.
-
vec4 *getWaterProbePositions()¶
Get the Array of positions of the water probes associated with this water object.
-
void setWaterProbePosition(int ID, vec3 pos)¶
Set the Array of positions of the water probes associated with this water object.
-
crossplatform::StructuredBuffer<vec4> *getWaterProbeOutputsBuffer()¶
Get a pointer to the probe outputs buffer.
-
void setWaterWaveletsSimulator(simul::terrain::WaterWaveletsSimulator *o)¶
Set the water wavelets simulator that this water object will use to generate its surface.
-
void setWaterGlobals(simul::terrain::globalWaterValues *newWaterGlobals)¶
Set the global water values.
-
simul::terrain::localWaterValues *getWaterValues()¶
Get a pointer the water values of this water object.
-
void setCustomWaterMesh(const WaterMeshObjectValues *newObject)¶
Set a given mesh object as the shape of the water object.
-
void updateCustomWaterMesh(const WaterMeshObjectValues *Object)¶
Update a given mesh object.
-
WaterMeshObjectValues *getCustomWaterMesh()¶
Get the current mesh object.
-
void removeCustomWaterMesh()¶
Remove the water mesh.
-
void updateLODs()¶
Update the LOD values depending on the size of the object.
-
void updateQuadDensity(vec3 camPos)¶
Update the level of detail of the surface of the water object depending on how far away the camera is.
-
void setLocation(vec3 newLocation)¶
Set the location of the center of the water object.
-
vec3 getLocation()¶
Get the location of the center of the water object.
-
void setDimension(vec3 newDimension)¶
Set the dimension of the center of the water object.
-
vec3 getDimension()¶
Get the dimension of the center of the water object.
-
void setRotation(float newRotation)¶
Set the rotation of the center of the water object.
-
float getRotation()¶
Get the rotation of the center of the water object.
-
int2 getQuadDensity()¶
Get the dimensions of how many quads the surface of the water object is using.
-
uint getTotalVerticies()¶
Get the total verticies used to render the water object.
-
virtual void RestoreDeviceObjects(crossplatform::RenderPlatform *r)¶
-
struct WaterMeshObjectValues¶
Struct for mesh objects used in water rendering.