Navigation
API > API/Plugins > API/Plugins/Water
| Name | FWaterQuadTree |
| Type | struct |
| Header File | /Engine/Plugins/Experimental/Water/Source/Runtime/Public/WaterQuadTree.h |
| Include Path | #include "WaterQuadTree.h" |
Syntax
struct FWaterQuadTree
Structs
| Name | Remarks |
|---|---|
| FFarMeshData | Contains everything needed to render the far mesh. |
| FNode | |
| FNodeData | Contains all the node data of the quad tree. Root node is Nodes[0] |
| FStagingInstanceData | |
| FTraversalDesc | Output of the quadtree when asking to traverse it for visible water tiles |
| FTraversalOutput | Output of the quadtree when asking to traverse it for visible water tiles |
Enums
Public
| Name | Remarks |
|---|---|
| FWaterQuadTree |
Constants
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| NumStreams | int32 | WaterQuadTree.h |
Variables
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| bIsGPUQuadTree | bool | WaterQuadTree.h | ||
| bIsReadOnly | bool | If true, the tree may not change | WaterQuadTree.h | |
| BreadthFirstOrder | TArray< int32 > | Node indices ordered by breadth first ordering | WaterQuadTree.h | |
| ExtentInTiles | FIntPoint | WaterQuadTree.h | ||
| FarMeshData | FWaterQuadTree::FFarMeshData | WaterQuadTree.h | ||
| LeafSize | float | WaterQuadTree.h | ||
| MaxLeafCount | int32 | WaterQuadTree.h | ||
| NodeData | FWaterQuadTree::FNodeData | WaterQuadTree.h | ||
| TileRegion | FBox2D | This is the bounding box that describes where the water tiles can be generated. | WaterQuadTree.h | |
| TreeDepth | int32 | WaterQuadTree.h | ||
| WaterBodyRasterInfos | TArray< FWaterBodyQuadTreeRasterInfo > | WaterQuadTree.h | ||
| WaterMaterials | TArray< FMaterialRenderProxy * > | WaterQuadTree.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void AddFarMesh
(
FMaterialRenderProxy* InFarMeshMaterial, |
Add an automatically generated mesh (8 quads) skirt around InInnerRegion which extends out InFarDistanceMeshExtent, is placed at Z value InFarDistanceMeshHeight and is rendered using InFarMeshMaterial | WaterQuadTree.h | |
void AddLake
(
const TArray< FVector2D >& InPoly, |
Add Lake by giving a closed spline that represents the lake | WaterQuadTree.h | |
void AddOcean
(
const TArray< FVector2D >& InPoly, |
Add Ocean by giving a closed spline that represents the land mass for this ocean. | WaterQuadTree.h | |
void AddWaterBodyRasterInfo
(
const FWaterBodyQuadTreeRasterInfo& InWaterBodyRasterInfo |
WaterQuadTree.h | ||
uint32 AddWaterBodyRenderData
(
const FWaterBodyRenderData& InWaterBodyRenderData |
Add water body render data to this tree. | WaterQuadTree.h | |
void AddWaterTilesInsideBounds
(
const FBox& InBounds, |
Add tiles that intersect InBounds recursively from the root node. | WaterQuadTree.h | |
void BuildMaterialIndices() |
Assign an index to each material | WaterQuadTree.h | |
void BuildWaterTileInstanceData
(
const FTraversalDesc& InTraversalDesc, |
Build the instance data needed to render the water tiles from a given point of view. | WaterQuadTree.h | |
TArray< FBoxSphereBounds > ComputeNodeBounds
(
int32 MaxNumBounds, |
WaterQuadTree.h | ||
uint32 GetAllocatedSize() |
Total memory dynamically allocated by this object | WaterQuadTree.h | |
FBox GetBounds() |
Get bounds of the root node if there is one, otherwise some default box | WaterQuadTree.h | |
FBox GetBoundsIncludingFarMesh() |
Get bounds of the root node if there is one (including far mesh), otherwise some default box | WaterQuadTree.h | |
float GetLeafSize() |
Get cached leaf world size of one side of the tile (same applies for X and Y) | WaterQuadTree.h | |
int32 GetMaxLeafCount () |
Number of maximum leaf nodes on one side, same applies for X and Y. | WaterQuadTree.h | |
int32 GetNodeCount() |
Total node count in the tree, including inner nodes, root node and leaf nodes | WaterQuadTree.h | |
FIntPoint GetResolution() |
WaterQuadTree.h | ||
FBox2D GetTileRegion() |
Return the 2D region containing water tiles. Tiles can not be generated outside of this region | WaterQuadTree.h | |
int32 GetTreeDepth() |
Max depth of the tree | WaterQuadTree.h | |
const TArray< FWaterBodyQuadTreeRasterInfo > & GetWaterBodyRasterInfos() |
WaterQuadTree.h | ||
const TArray< FWaterBodyRenderData > & GetWaterBodyRenderData() |
WaterQuadTree.h | ||
const TArray< FMaterialRenderProxy * > & GetWaterMaterials() |
WaterQuadTree.h | ||
void InitTree
(
const FBox2D& InBounds, |
Initialize the tree. | WaterQuadTree.h | |
bool IsGPUQuadTree() |
WaterQuadTree.h | ||
bool QueryInterpolatedTileBaseHeightAtLocation
(
const FVector2D& InWorldLocationXY, |
Bilinear interpolation between four neighboring base height samples around InWorldLocationXY. | WaterQuadTree.h | |
bool QueryTileBaseHeightAtLocation
(
const FVector2D& InWorldLocationXY, |
Walks down the tree and returns the tile height at InWorldLocationXY in OutWorldHeight. | WaterQuadTree.h | |
bool QueryTileBoundsAtLocation
(
const FVector2D& InWorldLocationXY, |
Walks down the tree and returns the tile bounds at InWorldLocationXY in OutWorldBounds. | WaterQuadTree.h | |
void Unlock
(
bool bPruneRedundantNodes |
Unlock to make it read-only. | WaterQuadTree.h |
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static float GetLODDistance
(
int32 InLODLevel, |
Calculate the world distance to a LOD | WaterQuadTree.h |