PolyTerrain reference
Authoritative defaults: Gems/PolyTerrain/Registry/polyterrain.setreg. Public headers live under Gems/PolyTerrain/Code/Include/PolyTerrain/.
Settings Registry
Prefix: /O3DE/PolyTerrain/.
| Key | Default | Purpose |
|---|---|---|
Enabled | false | Master switch; registers system components and bridges |
EditorModeEnabled | false | Six-tab Poly Terrain Mode |
PreviewRebuildBudgetMs | 1.5 | Per-stroke preview rebuild budget (ms); async Job when JobContext exists |
DebugOverlayEnabled | false | ImGui Poly Partition Diagnostics |
VtEnabled | false | Runtime VT bridge |
GpuPreviewEnabled | false | GPU preview sculpt path |
RuntimeWeightRewriteEnabled | false | Runtime weight stamps |
CollisionDominantReweightEnabled | false | Re-cook dominant triangle materials after rewrite |
CollisionConvexReweightEnabled | false | Update convex hull materials in place after rewrite |
PcgRuntimeExecutionEnabled | false | Allow PCG graph outputs outside the editor |
TabletPressureEnabled | true (code default) | Scale brush strength from tablet pressure |
PaintChannelInspectorEnabled | true (code default) | Paint-mode single-channel debug view |
Related (World Streaming): /WorldStreaming/PolyPartitionSignatureMismatchKick — optional consecutive mismatch count before terminate (default 0 = off).
EBus selection
| Need | Bus | Header |
|---|---|---|
| Register / dirty / RebuildPreview / diagnostics | PolyPartitionSystemRequestBus | PolyPartitionBus.h |
| BuildCompiledSections / section list | PolyPartitionRequestBus | PolyPartitionBus.h |
| RayIntersectD / SampleWeightChannelD / GetUnifiedSurfacePointD | PolyPartitionDataRequestBus | PolyPartitionBus.h |
| Preview / compiled / weight change notifies | PolyPartitionNotificationBus | PolyPartitionBus.h |
| VT trail stamp | PolyPartitionVtRequestBus | PolyPartitionVtBus.h |
| Weight stamp / overlay serialize | PolyPartitionWeightRewriteRequestBus | PolyPartitionWeightRewrite.h |
| PCG query / write / spawn / ExecuteGraph / PCG state I/O | PolyPartitionPcgRequestBus | PolyPartitionPcg.h |
Editor automation buses (BehaviorContext, Automation scope) include brush stamp injection and modifier enable / ordering helpers used by editor tests.
C++ examples
#include <PolyTerrain/PolyPartitionBus.h>
// Incremental bake
PolyTerrain::PolyPartitionRequestBus::Event(
partitionEntityId,
&PolyTerrain::PolyPartitionRequests::BuildCompiledSections,
true);
// Unified surface (mesh preferred, heightfield fallback)
PolyTerrain::PolyPartitionSurfaceHit hit;
PolyTerrain::PolyPartitionDataRequestBus::BroadcastResult(
hit,
&PolyTerrain::PolyPartitionDataRequests::GetUnifiedSurfacePointD,
worldPosD);
Python
Module: azlmbr.poly_terrain.
import azlmbr.bus as bus
import azlmbr.poly_terrain as poly_terrain
poly_terrain.PolyPartitionRequestBus(
bus.Event, 'BuildCompiledSections', partition_entity_id, True)
cloud = poly_terrain.PolyPartitionPcgRequestBus(
bus.Broadcast, 'QuerySurface', partition_entity_id, 'Sculpt', False)
Batch erosion example: Gems/PolyTerrain/Editor/Scripts/polypartition_batch_apply_modifier.py
Run: pyRunFile @gemroot:PolyTerrain@/Editor/Scripts/polypartition_batch_apply_modifier.py
Asset extensions
| Extension | Role |
|---|---|
.polypartitiondefinition | MPD |
.transformerpipeline | Standalone Transformer Pipeline asset |
.polypartition | Exported builder source snapshot |
.polypartitionsection | Compiled section binary (MPSC) |
.polypartitionweights | Baked weight textures |
.vt | Runtime virtual texture settings |
.polypcggraph | PCG graph asset |
Further reading
Component field tables: Components.