liu.yan Posted December 12, 2016 Share Posted December 12, 2016 We had developed an editor plugin, in which we performed I/O operations on special nodes to satisfy our demands(we need to get full control of loading and saving for certain nodes). We don’t wish these nodes to be saved in .world file through command like world_save. But once these nodes serves as child of a NodeLayer or within a reference node, it will save to .world file even if we had not add them to the editor explicitly. Is that normal behavior of the editor? And How can we do to gain full I/O access of certain nodes in editor? Link to comment
silent Posted December 12, 2016 Share Posted December 12, 2016 liu.yan, For your use case I think you can use addEditor(node, is_runtime) method with second argument set to 1. In that case nodes should not be saved into the world file since they have runtime flag set to 1. You can check addToEditor / removeFromEditor methods in <SDK>/data/core/scripts/samples.h for examples. 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
liu.yan Posted December 14, 2016 Author Share Posted December 14, 2016 That’s not working, nodes that added to the editor with the option “is_runtime = 1” still saved into the .world file. While resources which these nodes depend on are not saving, so next time when program runs, it will collapse. Link to comment
silent Posted December 14, 2016 Share Posted December 14, 2016 liu.yan. I'm afraid the only way to not save the nodes into the .world file - is to not add them into the Editor's ownership. 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
liu.yan Posted December 15, 2016 Author Share Posted December 15, 2016 Yes, that’s fundamentally right. But why node added to NodeLayer will be saved, while putting it on the top hierarchy of the node tree would not. Are there any difference? The video file “miao.avi” that demonstrate the operation was attached below, you can watch it. miao.avi Link to comment
silent Posted December 15, 2016 Share Posted December 15, 2016 liu.yan, Thank you for the video :) Could you please provide a small test scene? Right now it's hard to identify this issue (source of the C++ plugin as well as editor plugin will be required). 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
liu.yan Posted December 15, 2016 Author Share Posted December 15, 2016 Here is the plugin(the cpp file), it is not the exact plugin we are developing, but it will demonstrate the problem. The video shows how to recur the problem. Sorry for music in the video, forgot to turn it off while recording. plugin.cpp miao2.avi Link to comment
liu.yan Posted December 15, 2016 Author Share Posted December 15, 2016 Our purpose is to gain fully control of the node’s I/O in the editor. This is essential for us, since we had an internal graphics protocol which are widely used in our products. And now, we are integrating this protocol with Unigine, so the low level data can be transferred seamlessly across our products. Link to comment
silent Posted December 15, 2016 Share Posted December 15, 2016 Hi liu.yan, Please, check the attached modified plugin. You can try to use it the same way. We will try to fix NodeLayer behavior in the next SDK updates. plugin.cpp 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
liu.yan Posted December 16, 2016 Author Share Posted December 16, 2016 OK,thank you. And same problem happened in NodeReference and cloning nodes in editor. Link to comment
silent Posted December 16, 2016 Share Posted December 16, 2016 liu.yan, I'm afraid there is nothing we can done currently with NodeReference, sorry. 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
Recommended Posts