qertis Posted July 16, 2017 Share Posted July 16, 2017 I have a babylon.js scene on which I have added some meshes. I want to make the preview image where all meshes would be in camera frustum and fitting exactly the user's screen. How can I do it? Please, fix my playground: https://www.babylonjs-playground.com/#12WBC#95 Quote Link to comment Share on other sites More sharing options...
Temechon Posted July 17, 2017 Share Posted July 17, 2017 Like this ? Check line 66 : https://www.babylonjs-playground.com/#12WBC#100 Quote Link to comment Share on other sites More sharing options...
qertis Posted July 17, 2017 Author Share Posted July 17, 2017 1 hour ago, Temechon said: Like this ? Check line 66 : https://www.babylonjs-playground.com/#12WBC#100 No, I need like this https://www.babylonjs-playground.com/#12WBC#101 But if you uncomment line 45 box2.position = new BABYLON.Vector3(1,-5,-12) Camera is wrong again Quote Link to comment Share on other sites More sharing options...
Temechon Posted July 17, 2017 Share Posted July 17, 2017 https://www.babylonjs-playground.com/#12WBC#102 Line 76 : I replaced '.y' by '.z' Quote Link to comment Share on other sites More sharing options...
qertis Posted July 17, 2017 Author Share Posted July 17, 2017 15 minutes ago, Temechon said: https://www.babylonjs-playground.com/#12WBC#102 Line 76 : I replaced '.y' by '.z' Thanks! Do you think it is ok? https://www.babylonjs-playground.com/#12WBC#104 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.