Google Code Exporter
Google Code Exporter
``` First of all, you should get the obj file loaded in the viewer. When done, the content of the obj file are wrapped in a Scene object, which can...
``` Thanks for reply,but viewer.getScene() returning null,please check the coding below,is anything wrong? var canvas = document.getElementById('cv'); var viewer = new JSC3D.Viewer(canvas); viewer.setParameter('SceneUrl', 'bank/female02.obj'); viewer.setParameter('InitRotationX', 0); viewer.setParameter('InitRotationY', 0); viewer.setParameter('InitRotationZ', 0);...
``` The loading is asynchronous. So you should override the viewer.onloadingcomplete(http://jsc3d.googlecode.com/svn/trunk/jsc3d/docs/symbol s/JSC3D.Viewer.html#onloadingcomplete) with a callback function and wrap your code in it like this: var viewer = ... ... viewer.init();...
``` Ok thanks for your reply,can u please tell me how to load multiple obj file? ``` Original comment by `[email protected]` on 24 Jul 2014 at 6:39
``` This discussion http://code.google.com/p/jsc3d/issues/detail?id=52 provides a good example for how to load multiple models into a single scene. Please be aware that mutiple models from different sources can be used...
``` Thanks JSC3D is GREAT in the 3D world and project member of JSC3D is the best. ``` Original comment by `[email protected]` on 24 Jul 2014 at 11:56
``` How to Change texture of a mesh on a button click? ``` Original comment by `[email protected]` on 25 Jul 2014 at 10:07
``` First, get the clicked mesh via mouse event handlers. Then invoke mesh.setTexture() method(http://jsc3d.googlecode.com/svn/trunk/jsc3d/docs/symbols/JSC3D.Mesh.html# setTexture) passing in a new texture object to replace the old one. Finally, call viewer.update() to...
``` How to change vertexbuffer of a mesh on a button click? ``` Original comment by `[email protected]` on 30 Jul 2014 at 10:46
``` Don't change vertexBuffer of an existing mesh. Create a new mesh with the given vertices and use it to replace the old one. ``` Original comment by `[email protected]` on...