Dad72 Posted February 23, 2016 Share Posted February 23, 2016 When I use target.getFrontPosition (), there seems to be a problem depending on the height of the camera. When the camera is high, the value 'Y' of getFrontPosition () is low rather than being at the same height as the camera. View on the playground. You can see the sphere below 0 and the camera above zero. in X and Z, it works perfectly well. http://www.babylonjs-playground.com/#1FQZ8T#0 <fr> Au cas ou mon explication en anglais ne serait pas bonne. Lorsque j'utilise target.getFrontPosition(), il semble y avoir un probleme suivant la hauteur de la camera. Plus la camera est haute, plus la valeur en Y de getFrontPosition() est basse au lieux de ce retrouver à la même hauteur que la camera. Voir sur le playground. on peut voir la sphère en dessous de 0 et la camera au dessus de zéro. en X et Z, cela fonctionne parfaitement bien. </fr> Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted February 23, 2016 Share Posted February 23, 2016 getFrontPosition uses the target position like this: https://github.com/BabylonJS/Babylon.js/blob/master/src/Cameras/babylon.targetCamera.ts#L36 So the result is correct for me Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.