steve.brodie Posted October 21, 2013 Share Posted October 21, 2013 We often have problems with bones not updating unless they are in the view frustrum. eg we attach cameras to bones for animated cameras. Could a tick box be put in the smesh playback panel in the editor, that forces the bones to update, whether they are in view or not. Thanks Link to comment
ulf.schroeter Posted October 21, 2013 Share Posted October 21, 2013 Steve, in case you are using WorldTransformBone for camera-to-bone attachment simply use WorldTransformBone::setRadius(<some large radius value>) to force bone update outside view frustum Link to comment
steve.brodie Posted October 22, 2013 Author Share Posted October 22, 2013 Thanks Ulf, but setting the WorldTransformBone radius really high doesnt work either. i set it to 20000 and then inf, but bone wont move unless im closer to it or in view. Link to comment
ulf.schroeter Posted October 22, 2013 Share Posted October 22, 2013 Well then this sounds more like a engine bug or conceptional flaw. Can you provide a small test scene ? Link to comment
steve.brodie Posted October 22, 2013 Author Share Posted October 22, 2013 Ill upload a bone then just strap a WorldTransformBone to it and a camera. Then when you are at the origin try to press play in the editor mesh tab bone dialog. Link to comment
ulf.schroeter Posted October 22, 2013 Share Posted October 22, 2013 So top-level element is some ObjectMeshSkinned with bones ? Just guessing, but if so one problem might be that smaller boundig box of ObjectMeshSkinned will be used for frustum check instead of lower-level WorldTransformBone + radius value. Unfortunately there does not seem to be a method for on Node/Object/ObjectMesh... for explicit bounding box definition. Small test scene should allow faster UNIGINE crew testing Link to comment
steve.brodie Posted October 22, 2013 Author Share Posted October 22, 2013 Here it is, sorry i thought i attached this with the last post. voodoo_bone.zip Link to comment
silent Posted October 22, 2013 Share Posted October 22, 2013 Hi Steve, Could you please provide simple step-by-step instruction how to reproduce such issue? What SDK version are you currently using? If I add your smesh to the world and attach WorldTransformBone with Camera to it I can get animation working even if Editor Camera is far away (55000 units) from smesh object. Please, check a test scene (unzip files into <SDK>/data directory and open test.world in the Editor) and modify it if something done wrong. You can also change the editor camera position and check animation playback. Thanks! test.zip How to submit a good bug report --- FTP server for test scenes and user uploads: ftp://files.unigine.com user: upload password: 6xYkd6vLYWjpW6SN Link to comment
steve.brodie Posted October 23, 2013 Author Share Posted October 23, 2013 Ok thanks that makes sense of the problem. The problem is that if the Worlds object render distance is not high enough then the bone will not play. So to reproduce it in the test you sent, set world view distance to 3000 and then focus on fort 1. Then play, even with a very high radius on the WorldTransformBone the mesh doesnt play. Since I think on big scenes we keep the draw distance quite low, around 3000m, often bones that need to stay in sync, that are outside that distance, freeze up. Link to comment
silent Posted October 23, 2013 Share Posted October 23, 2013 Hi Steve, In that case you can use following functions to force update required nodes: engine.world.addUpdateNode(); engine.world.addUpdateNodes(); How to submit a good bug report --- FTP server for test scenes and user uploads: ftp://files.unigine.com user: upload password: 6xYkd6vLYWjpW6SN Link to comment
steve.brodie Posted November 17, 2013 Author Share Posted November 17, 2013 Hi Silent, Im still constantly having problems with bones not updating when they are not in view. We have tried that update function, but seems like its not working. Also, i have turned my object distance to 50000, but still bones are not updating when not in frame. A checkbox on the bone playback would be ideal. Link to comment
silent Posted November 18, 2013 Share Posted November 18, 2013 Hi Steve, Can you please make a sample with not working addUpdateNode/addUpdateNodes functions? Thanks! How to submit a good bug report --- FTP server for test scenes and user uploads: ftp://files.unigine.com user: upload password: 6xYkd6vLYWjpW6SN Link to comment
snow_zhangy Posted March 31, 2014 Share Posted March 31, 2014 hi Silent. I have the same issue with objectmeshdynamic. when the skin mesh not in viewport the animation will stop. i tryied the addupdatenode , its not working. i guess its only for the logic not for rendering. please check the engineer for this issue. its critical for us. Link to comment
sebastianbah Posted April 2, 2014 Share Posted April 2, 2014 Hello snow_zhangy, I'm afraid, for any advices a test scene is needed, because we can't reproduce such behavior.It would be very helpful if you can send us a test scene with addUpdateNode function and the object causing the issue. Thanks! Link to comment
unclebob Posted April 2, 2014 Share Posted April 2, 2014 Hi Yang! First of all, you need to call engine.world.addUpdateNode every frame in order to get your node updated even outside viewport. Also, if you're using WorldTransformBone with your skinned mesh it's better to force update that node too. Link to comment
Recommended Posts