private void createCameraMotion() { CameraNode camNode = cinematic.bindCamera("topView", cam); camNode.setLocalTranslation(new Vector3f(0, 50, 0)); camNode.lookAt(teapot.getLocalTranslation(), Vector3f.UNIT_Y); CameraNode camNode2 = cinematic.bindCamera("aroundCam", cam); path = new MotionPath(); path.setCycle(true); path.addWayPoint(new Vector3f(20, 3, 0)); path.addWayPoint(new Vector3f(0, 3, 20)); path.addWayPoint(new Vector3f(-20, 3, 0)); path.addWayPoint(new Vector3f(0, 3, -20)); path.setCurveTension(0.83f); cameraMotionEvent = new MotionEvent(camNode2, path); cameraMotionEvent.setLoopMode(LoopMode.Loop); cameraMotionEvent.setLookAt(model.getWorldTranslation(), Vector3f.UNIT_Y); cameraMotionEvent.setDirectionType(MotionEvent.Direction.LookAt); }
cinematic.enqueueCinematicEvent( new AnimationEvent(jaime, "Idle", LoopMode.DontLoop)); CameraNode camNode = cinematic.bindCamera("cam", cam); camNode.setLocalTranslation(new Vector3f(1.1f, 1.2f, 2.9f)); camNode.lookAt(new Vector3f(0, 0.5f, 0), Vector3f.UNIT_Y);