Skip to content

Commit

Permalink
image data included with scene graph on file save
Browse files Browse the repository at this point in the history
  • Loading branch information
vicrucann committed Mar 30, 2017
1 parent a118965 commit e2124a6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/libSGEntities/RootScene.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
#include <osgDB/WriteFile>
#include <osgDB/ReaderWriter>
#include <osgDB/Registry>
#include <osgDB/Options>

#include "Settings.h"
#include "Utilities.h"
Expand Down Expand Up @@ -134,7 +135,8 @@ bool RootScene::writeScenetoFile()
canvas->detachFrame();
}

if (!osgDB::writeNodeFile(*(m_userScene.get()), m_userScene->getFilePath())) result = false;
if (!osgDB::writeNodeFile(*(m_userScene.get()), m_userScene->getFilePath(), new osgDB::Options("WriteImageHint=IncludeData")))
result = false;

/* for each canvas, attach its tools back */
for (int i=0; i<m_userScene->getNumCanvases(); ++i){
Expand Down

0 comments on commit e2124a6

Please sign in to comment.