Water Meshes

  • UWaterSubsystem

    • Handles all the intersections and such through FWaterBodyManager

  • AWaterZoneActor

    • Actor that holds the meshes

    • Adds all the new actors and uses them to separate the rendering into the transition pieces and such

    • A big volume covering the level

  • UWaterMeshComponent

    • UWaterMeshComponent::PostEditComponentMove

      • Marks the mesh as needs rebuild (bNeedsRebuild) via the AWaterZoneActor Owner of this component

    • UWaterMeshComponent::Update: Gets called on tick by the UWaterSubsystem

      • If bNeedsRebuild, calls UWaterMeshComponent::RebuildWaterMesh

    • UWaterMeshComponent::RebuildWaterMesh

      • Builds the geometry for this water mesh component

      • Gets the Dynamic Material Instance from the Water Body (UWaterBodyComponent::CreateOrUpdateWaterMID)

        • Also calls UWaterBodyComponent::SetDynamicParametersOnMID which sets global values from the UWaterSubsystem and UWaterBodyComponent and AWaterZone

        • Also gets the River to Lake and River to Ocean Transition Material Instances from the Water Body Component (which are again Dynamic Material Instances)

      • Uses a HActor as a hit proxy for the mesh in the viewport

      • Water Body Component also stores collision components

        • River: SplineMeshComponents

      • FWaterQuadTree stores the mesh data

  • FWaterMeshSceneProxy

    • The primitive that is drawn in the scene

    • Created by the WaterMeshComponent

  • TWaterVertexFactory

    • Constucts and handles the RHI data including the vertex buffer

  • FWaterMeshVertexBuffer

    • Vertex buffer for drawing the water mesh

  • TWaterInstanceDataBuffers

    • Collection of vertex buffers used by the factory

Last updated