V-ART
xmlaction.h
Go to the documentation of this file.
1 
5 #ifndef VART_XMLACTION_H
6 #define VART_XMLACTION_H
7 
8 #include "vart/action.h"
9 #include "vart/xmlbase.h"
10 
11 namespace VART {
12  class Scene;
13  class SceneNode;
14 
19  // check if bug is still true after creation of XmlBase.
20 
21  class XmlAction : public Action, public XmlBase {
22  friend std::ostream& operator<<(std::ostream& output, const XmlAction& action);
23  public:
24  // PUBLIC METHODS
25  XmlAction();
26  ~XmlAction();
30  bool LoadFromFile(const std::string& fileName, const Scene& scene);
31 
35  bool LoadFromFile(const std::string& fileName, const SceneNode& sNode);
36 
37  protected:
38  // PROTECTED NESTED CLASSES
39  class Source
40  {
41  public:
42  //~ Source();
43  Source(const Scene& scene);
44  Source(const SceneNode& sNode);
45  Joint* GetJointByName(const std::string& name) const;
46  protected:
47  const Scene* scenePtr;
49  };
50  // PROTECTED METHODS
51  void LoadAnimation(const Source& jointSource);
52  void ParseDofMovement(JointMover* jointMPtr, XERCES_CPP_NAMESPACE::DOMNode* dofMovItemPtr);
53  private:
54  }; // end class declaration
55 } // end namespace
56 
57 #endif
Base class for objects that compose a scene graph.
Definition: scenenode.h:25
Representation of joints.
Definition: joint.h:34
const Scene * scenePtr
Definition: xmlaction.h:47
A coordinated movement of joints in an articulated body.
Definition: action.h:29
Header file for V-ART class "XmlBase".
Basic methods for reading XML files.
Definition: xmlbase.h:18
Source(const Scene &scene)
Definition: xmlaction.cpp:388
Joint * GetJointByName(const std::string &name) const
Definition: xmlaction.cpp:400
Header file for V-ART class "Action".
A set of objects, lights and cameras.
Definition: scene.h:35
friend std::ostream & operator<<(std::ostream &output, const XmlAction &action)
void LoadAnimation(const Source &jointSource)
Definition: xmlaction.cpp:66
Controllers for joint movement.
Definition: jointmover.h:22
Parser and loader for xml files that describe an Action.
Definition: xmlaction.h:21
const SceneNode * sceneNodePtr
Definition: xmlaction.h:48
bool LoadFromFile(const std::string &fileName, const Scene &scene)
Loads action from a XML file.
void ParseDofMovement(JointMover *jointMPtr, XERCES_CPP_NAMESPACE::DOMNode *dofMovItemPtr)
Definition: xmlaction.cpp:207