Unable to see glb with region boundingVolume

Hi,

I’m using Cesium for Unreal 2.1.0, on Unreal 5.1.1.

I’m new to 3d tiles, but I’m trying to manually export the tileset.json from Unreal, so I might have missed out something or done something wrong.
I’m unable to see the glb anywhere, even when I focus on the tileset object.
The file is loaded locally.

Here’s my minimal tileset.json.

{
	"asset": {
		"version": "1.1"
	},
	"geometricError": 500,
	"root": {
		"boundingVolume": {
			"region": [
				1.8081069243912818,
				0.020746525549286168,
				1.816012887210802,
				0.025847637266120425,
				27.901223550129708,
				368.1950672325539
			]
		},
		"geometricError": 500,
		"refine": "REPLACE",
		"content": {
			"uri": "monkey.glb"
		}
	}
}

The region should be bounding the whole Singapore island.
The monkey.glb is actually the default monkey model exported from blender, and it does show when tested with the 1.0\TilesetWithDiscreteLOD sample.
I have also validated the json file with the 3d-tile-validator, which didn’t report any error.

Any help is appreciated.

Providing a bounding volume doesn’t automatically put your content inside the bounding volume. You’re declaring that your tile content is in one place (Singapore island), but the actual content is somewhere else (probably at the center of the Earth). You’ll need a transform either in the glTF or in the tile to put the model where you want it.

Hi Kevin,

Thanks for your reply! That make sense.

I saw the transform from 1.0\TilesetWithDiscreteLOD sample, but I have no idea how to generate that just from the geographic coordinate. Would you be able to point me to somewhere on how to do that?

Cesium for Unreal can compute an appropriate transformation matrix for you by calling EastNorthUpToEarthCenteredEarthFixed on UCesiumWgs84Ellipsoid. You could also use cesium-native if you need a lighter-weight C++ library to do it, or CesiumJS if you’re working in JavaScript. There are probably other libraries that can do it, but those are the ones we provide.

Thanks Kevin!

It worked! I can finally see the monkey near where I want it to be.

Though I notice that pivot of the model seems off.

Left is from the 3D tile, right is from the unreal’s model viewer.

I wonder if it just the floating point error, since what I did was just manually copying the matrix printed on to the console log to the tileset.json.

Regardless, I’m happy with the result and your help! Thank you very much!

[Edit]
Indeed, it was just a precision issue. Once I test with the proper double precision, the pivot is at the correct location.