00001 #ifndef QBDOTGRAPHOUTPUT 00002 #define QBDOTGRAPHOUTPUT 00003 00004 #include "QbIncludes.h" 00005 00006 class QbDotGraphOutput { 00007 public: 00008 SoTypeList typeList; 00009 bool writeType; 00010 bool writeFields; 00011 bool writeFieldConnections; 00012 bool alwaysWriteNodeAdress; 00013 00014 QbDotGraphOutput() : writeType(true), writeFields(true), writeFieldConnections(true), alwaysWriteNodeAdress(false) {} 00015 void writeFile(const char * filename, SoNode * graph ); 00016 00017 private: 00018 bool shouldPrint(SoBase * node); 00019 void replaceApostrophes(SbString & string); 00020 void writeNodeFieldConnections(SoFieldContainer * slave, SoOutput & output); 00021 void writeNodeFields(SoFieldContainer * container, SoOutput & output); 00022 void writeNode(SoFieldContainer * node, SoOutput & output); 00023 void writeChildren(SoNode * graph, SoOutput & output, SoNode *parent = NULL); 00024 }; 00025 00026 #endif