Vixen
c7401864

FoliageVolumeComponent

scene component Core/Vixen.Rendering.Terrain/FoliageComponents.cs:33
csharp
public struct FoliageVolumeComponent

What a scene says about its painted foliage: which instances, of which types.

Read the guide page for this →

Remarks

[docs/plan/31]'s owed fifth seam — "a FoliageVolumeComponent naming a volume asset". The instances live beside the scene as a .vxfol, because fifty thousand transforms in a .vxscene is a file nobody can merge; the palette is names and numbers a review has to be able to read, and this component is the text that declares it — each entry a .vxfoliage reference, in the order the volume's chunks index.

⚠ The palette's order is load-bearing. A stored chunk names its type by index, so reordering these references re-dresses every painted stand — somebody's oaks become pines with no error anywhere. Append; do not sort.

⚠ Placement is the entity's translation, and world-painted volumes sit at the origin. The editor paints instances in world space, so a volume authored there rides an entity with no transform; the translation exists for a prefab-shaped volume placed more than once. Rotation and scale are not consumed, on TerrainComponent's no-rotation terms.

Fields and properties (3)

  • public string Volume

    Which .vxfol holds the instances.

  • public string[] Palette

    The .vxfoliage types the instances are of, in palette order.

  • public float Range

    How far from the camera cells stay uploaded, in metres. Zero takes the default.

Methods (1)

  • public static FoliageVolumeComponent Of(string volume, params string[] palette)

    A volume drawn with the usual settings.

Used by (8)

  • ArenaThirdPersonShooter
  • PbrShowcaseGamePbrShowcase
  • ComponentRegistrationVixen.Rendering.Terrain
  • TerrainExtractionSystemVixen.Rendering.Terrain
  • TerrainNodeTestsVixen.Rendering.Terrain.Tests
  • TypeRegistrationVixen.Rendering.Terrain
  • Vixen_Rendering_Terrain_FoliageVolumeComponentSerializerVixen.Rendering.Terrain
  • MaterialIconsVixen.Editor.App