Function to Async Generate a Top Down silhouette of a Cesium3DTileset geometry #1739
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Summary:
This PR adds a new Async function to Cesium3DTileset that will generate a top down silhouette of the tileset geometry. The callback returns the tileset actor and a TArray FVector defining the polygon points of the sampled tileset geometry. The function calls the already existing SampleHeightMostDetailed to sample the calculated grid points for simplicity.
Context:
This is extremely useful for runtime applications where a new tileset can dynamcially be added. Using this function we can calculate a rough outline of the tileset and use this for spawning a CesiumCartographicPolygon to clip the tileset into surrounding tilesets. Additionally the generated polygon can be used to create other geometry that can be wrapped around the tileset. Another use case would be to use the polygon shape to define a player or NPC moveto/path around a tileset to automate a cinematic fly around.
Screenshots:

Issue number or link
Cesium forum post: https://community.cesium.com/t/adding-a-function-to-automatically-generate-a-polygon-shape-of-a-3d-tileset-geometry/43453
Author checklist
CHANGES.md
with a short summary of my change (for user-facing changes).Remaining Tasks
No remaining tasks that I am aware of
Testing plan
Function was tested in blueprint call and C++ call. The tasks can take several seconds for very large tilesets that cover hundreds of kilometers but the callback can be bound to a UI element that will reflect completion.