From I3dm to EXT_mesh_gpu_instancing?

There is one thought that is still bothering me a bit: I’m not entirely sure whether trying to write these orientations into the GLB itself is the best thing to do here.

When looking at the GLB in isolation (e.g. with https://sandbox.babylonjs.com/ , which supports instancing), then you see that this GLB is oriented as-if it was attached to the globe, at the desired position. So you could not use the same GLB on a different place on earth, without doing a further transform. This transform would have to take into account the ENU of its current position (inverted), and the ENU of the target position. (Even more room for confusion here…)

It might be better or more verstatile to use a GLB where all trees are upright (aligned with the up/y-axis), and then use the tile transform to put it at the right position on earth. This tile transform could then probably just be the ENU, as it is. (That’s a gut feeling, but I think it should be…)

To illustrate that (and apologies for the use of Paint here) :

How easily this could be accomplished may also depend on the source data. For example, if the GLB is covering a large area, then the positions and rotations of the EXT_mesh_gpu_instancing object would basically reflect the curvature of earth. But it could still be placed at any point of the globe.

Maybe I’ll try that out with the original GLB at some point. For now, I just wanted to mention that this might be easier and more versatile in the long run…

1 Like