Hi all,
In some 3D Tile datasets, there is a transform node. Looking at Cesium Ion’s Melbourne dataset (69380), there is a transform specified in the root tileset.json:
"transform":[-0.5699774740294932,-0.8216313954439031,-0.006894136626272664,0,-0.5068551282833045,0.34498402763987435,0.7899898098116428,0,-0.6467020628015874,0.4537707248096024,-0.6130812109940204,0,-4129944.4597646086,2897853.584712872,-3889026.1577356746,1]
For this dataset (69380), suppose we’re loading 2\010.b3dm. The b3dm does not have any transforms specified, so we’re focused on the 3DTile transform shown above. Is it true that any vertex of 010.b3dm can be transformed using the transform above to get that vertex’s ECEF location?
How do I create an FTransform (with the values from “transform” show above) in UE5 that can be used to transform locations?
Is this correct?
FTransform datasetTransform = FTransform(
FMatrix(
FPlane(-0.5699774740294932, -0.5068551282833045, -0.6467020628015874, 0),
FPlane(-0.8216313954439031, 0.34498402763987435, 0.4537707248096024, 0),
FPlane(-0.006894136626272664, 0.7899898098116428, -0.6130812109940204, 0),
FPlane(-4129944.4597646086, 2897853.584712872, -3889026.1577356746, 1)
));
Should the code below give the correct ECEF for a vertex?
vertexECEF = datasetTransform.TransformPosition(vertexLocation);
Thanks!