scalingDeterminant not changing the mesh until position change

Hi Everyone,
I am loading a mesh with SceneLoader.ImportMesh, and changing the scalingDeterminant in call back function. But scaling not effecting until i change the position of mesh ( using gizmo ex. ). At first mesh is rendering original scale. Later, when try to move it, then scalingDeterminant starting to effect and mesh correctly rendering.

SceneLoader.ImportMesh([“Cube”], “./”, “test.babylon”, this._scene, (meshes, particleSystems, skeletons) => {

            // do something with the meshes and skeletons

            // particleSystems are always null for glTF assets

            meshes[0].scalingDeterminant = 0.01;

        });

I couldn’t find out why yet, anyone knows how to refresh it immmiately or why?

Changing the scalingDeterminant value does not trigger a recomputation of the world matrix.

What you can do is calling mesh.computeWorldMatrix(true) just after changing the determinant.

…and welcome aboard!

1 Like

Thanks Evgeni,
Babylonjs is realy impressive. I am realy happy to learning it. I used DirectX on desktop applications so far. I am not only new on Babylon , also new to rendering in browser host too :), but i think ideas are the same.

2 Likes