Navigation
API > API/Runtime > API/Runtime/Landscape > API/Runtime/Landscape/ULandscapeInfo
References
| Module | Landscape |
| Header | /Engine/Source/Runtime/Landscape/Classes/LandscapeInfo.h |
| Include | #include "LandscapeInfo.h" |
| Source | /Engine/Source/Runtime/Landscape/Private/Landscape.cpp |
bool GetOverlappedComponents
(
const FTransform & InAreaWorldTransform,
const FBox2D & InAreaExtents,
TMap< FIntPoint, ULandscapeComponent * > & OutOverlappedComponents,
FIntRect & OutComponentIndicesBoundingRect
)
Remarks
Retrieve the components currently loaded that overlap with a given "window" area true if at least one overlapped component TODO [jonathan.bard] : There should be multiple versions of this.
This currently performs AABB to AABB checks and is therefore not optimal (but faster than OOBB to OOBB could ever be, which is why we might need 2 versions) :
Returning a TMap<> is a bit overkill, since the component key can be retrieved trivially from the component
Parameters
| Name | Description |
|---|---|
| InAreaWorldTransform | : transform of the requested area (at the center) |
| InAreaExtents | : extents of requested area (i.e. around the center) |
| OutOverlappedComponents | : loaded components that overlap this area (key = xy index of the component, value = component) |
| OutComponentIndicesBoundingRect | : bounding rectangle of the overlapped components, in component index space, with the max being exclusive. For instance a rectangle with min=(0,0) and max=(2,1) includes components (0,0) and (1,0). |