8 #ifndef META_OCEAN_SCENEDESCRIPTION_SDX_X3D_XML_PARSER_H
9 #define META_OCEAN_SCENEDESCRIPTION_SDX_X3D_XML_PARSER_H
26 namespace SceneDescription
39 class OCEAN_SCENEDESCRIPTION_SDX_X3D_EXPORT
XMLParser
66 explicit XMLParser(
const std::string& filename,
float* progress =
nullptr,
bool* cancel =
nullptr);
355 tinyxml2::XMLError xmlOpenResult_ = tinyxml2::XML_SUCCESS;
This class implements a simple scanner.
Definition: Scanner.h:31
This class implements a axis-angle rotation using floating point values.
Definition: Rotation.h:79
This class implements all 1D fields (fields holding an array of single values).
Definition: Field1D.h:110
This class is the base class for all scene description fields.
Definition: Field.h:36
This class is the base class for all scene description libraries.
Definition: scenedescription/Library.h:37
This class implements a scene object holding an entire x3d scene.
Definition: X3DScene.h:39
This class implements a helper scanner for the XML X3D file format.
Definition: XMLParser.h:47
XMLScanner(const std::string &data)
Creates a new XML scanner.
This class implements a XML parser for X3D.
Definition: XMLParser.h:40
bool parseValueField(SingleInt &field, const std::string &value)
Parses a SFInt32 field.
bool parseValueField(Field &field, const std::string &value)
Parses a field.
bool parseValueField(MultiFloat &field, const std::string &value)
Parses a MFFloat field.
bool parseValueField(SingleColor &field, const std::string &value)
Parses a SFColor field.
bool parseValueField(MultiMatrix3 &field, const std::string &value)
Parses a MFMatrix3f field.
bool parseValueField(SingleMatrix4 &field, const std::string &value)
Parses a SFMatrix4 field.
void addDynamicField(NodeRef &parent, const tinyxml2::XMLElement *xmlNode)
Adds a dynamic field.
bool parseValueField(SingleString &field, const std::string &value)
Parses a SFString field.
bool parseValueField(MultiVector4 &field, const std::string &value)
Parses a MFVec4f field.
bool parseValueField(MultiInt &field, const std::string &value)
Parses a MFInt32 field.
void parseNodeField(NodeRef &parent, const tinyxml2::XMLElement *xmlNode)
Parses a new node.
tinyxml2::XMLDocument xmlDocument_
XML parser.
Definition: XMLParser.h:352
std::string sceneFilename_
Scene filename.
Definition: XMLParser.h:361
bool parseValueField(MultiColor &field, const std::string &value)
Parses a MFColor field.
bool parseBool(IO::Scanner &scanner)
Parses a bool value.
Timestamp sceneTimestamp_
Scene timestamp.
Definition: XMLParser.h:364
bool parseValueField(SingleVector4 &field, const std::string &value)
Parses a SFVec4f field.
bool parseValueField(MultiBool &field, const std::string &value)
Parses a MFBool field.
NodeRef parseNode(const tinyxml2::XMLElement *xmlNode)
Parses a new node.
bool parseValueField(SingleVector3 &field, const std::string &value)
Parses a SFVec3f field.
bool parseValueField(MultiVector2 &field, const std::string &value)
Parses a MFVec2f field.
bool parseValueField(SingleVector2 &field, const std::string &value)
Parses a SFVec2f field.
XMLParser(const std::string &filename, float *progress=nullptr, bool *cancel=nullptr)
Creates a new XML parser.
bool parseValueField(SingleMatrix3 &field, const std::string &value)
Parses a SFMatrix3 field.
bool parseValueField(MultiVector3 &field, const std::string &value)
Parses a MFVec3f field.
bool parseValueField(SingleBool &field, const std::string &value)
Parses a SFBool field.
Rotation parseRotation(IO::Scanner &scanner)
Parses a rotation value.
static std::string fieldNameLookup(const NodeRef &parent, const std::string &nodeType)
The lookup function for node field.
Scalar parseFloat(IO::Scanner &scanner)
Parses a float value.
bool parseValueField(SingleRotation &field, const std::string &value)
Parses a SFRotation field.
bool parseValueField(MultiRotation &field, const std::string &value)
Parses a MFRotation field.
SDXSceneRef parse(const Library &library, const Rendering::EngineRef &engine, const Timestamp timestamp=Timestamp())
Parses the given file and returns a node reference to the entire scene.
std::string parseString(IO::Scanner &scanner)
Parses a string value.
int parseInt(IO::Scanner &scanner)
Parses an integer value.
bool parseValueField(SingleFloat &field, const std::string &value)
Parses a SFFloat field.
bool parseValueField(SingleTime &field, const std::string &value)
Parses a SFTime field.
void parseRoute(const tinyxml2::XMLElement *xmlNode)
Parses a route statement.
bool parseValueField(MultiTime &field, const std::string &value)
Parses a MFTime field.
bool parseValueField(MultiMatrix4 &field, const std::string &value)
Parses a MFMatrix4f field.
bool parseValueField(MultiString &field, const std::string &value)
Parses a MFString field.
This class implements a timestamp.
Definition: Timestamp.h:36
float Scalar
Definition of a scalar type.
Definition: Math.h:128
The namespace covering the entire Ocean framework.
Definition: Accessor.h:15