Hi all,
I have a question regarding a strange behaviour of the result of the following:
// ----------------------------------------------
speed=45;
frameCount=200;
focusX=myMesh.position.x;
focusZ=myMesh.position.z;
cameraMove = function(cam, criteria, speed, frameCount, newPos) {
ease = new BABYLON.CubicEase();
ease.setEasingMode(BABYLON.EasingFunction.EASINGMODE_EASEINOUT);
go = BABYLON.Animation.CreateAndStartAnimation(‘deplacement’, cam, criteria, speed, frameCount, cam.position, newPos, 0, ease);
go.disposeOnEnd = true;
}
// ===========================
// = Déplacement de la caméra =
// ===========================
cameraMove(camera, ‘position’, speed, frameCount, new BABYLON.Vector3(focusX, 20, focusZ-25));
cameraMove(camera, ‘rotation’, speed, frameCount, new BABYLON.Vector3(focusX+25, 20, focusZ));
// ----------------------------------------------
The scene rotates and moves I don’t know how many times then stops at a position that has nothing to do with the position initially requested.
It’s quite difficult to put my program in the playground as I have more the 7300 meshes defined (locations in a warehouse) and my program uses Ajax functions to run Php programs.
Thanks for your help.
Olivier