9 #ifndef GEPETTO_VIEWER_LEAFNODECOLLADA_HH
10 #define GEPETTO_VIEWER_LEAFNODECOLLADA_HH
12 #include <osgDB/ReadFile>
27 std::string collada_file_path_;
28 std::string texture_file_path_;
31 LeafNodeColladaWeakPtr weak_ptr_;
34 ::osg::GroupRefPtr group_ptr_;
35 ::osg::NodeRefPtr collada_ptr_;
42 LeafNodeCollada(
const std::string& name,
const std::string& collada_file_path);
44 LeafNodeCollada(
const std::string& name, const ::osg::NodeRefPtr& node,
const std::string& collada_file_path);
49 void initWeakPtr (LeafNodeColladaWeakPtr other_weak_ptr);
57 static LeafNodeColladaPtr_t
create(
const std::string& name, ::osg::NodeRefPtr mesh,
const std::string& collada_file_path);
58 static LeafNodeColladaPtr_t
create(
const std::string& name,
const std::string& collada_file_path);
59 static LeafNodeColladaPtr_t
create(
const std::string& name,
const std::string& collada_file_path,
const osgVector4& color);
63 static LeafNodeColladaPtr_t
createCopy(LeafNodeColladaPtr_t other);
67 virtual LeafNodeColladaPtr_t
clone(
void)
const;
75 virtual LeafNodeColladaPtr_t
copy()
const {
return clone(); }
79 LeafNodeColladaPtr_t
self(void)
const;
Definition: properties.h:17
Definition: leaf-node-collada.h:24
const std::string & meshFilePath() const
virtual void setAlpha(const float &alpha)
::osg::NodeRefPtr getColladaPtr(void)
const std::string & textureFilePath() const
static LeafNodeColladaPtr_t create(const std::string &name, ::osg::NodeRefPtr mesh, const std::string &collada_file_path)
virtual LeafNodeColladaPtr_t copy() const
Proceed to a copy of the currend object as clone.
Definition: leaf-node-collada.h:75
SCENE_VIEWER_ACCEPT_VISITOR
Definition: leaf-node-collada.h:100
void applyScale()
Apply the current scale permanently to the node.
virtual ~LeafNodeCollada()
void removeLightSources()
Remove any osg::LightSource of this mesh.
static LeafNodeColladaPtr_t create(const std::string &name, const std::string &collada_file_path)
virtual osg::ref_ptr< osg::Node > getOsgNode() const
osgVector4 getColor() const
void setColor(const osgVector4 &color)
static LeafNodeColladaPtr_t createCopy(LeafNodeColladaPtr_t other)
static LeafNodeColladaPtr_t create(const std::string &name, const std::string &collada_file_path, const osgVector4 &color)
void setTexture(const std::string &image_path)
virtual LeafNodeColladaPtr_t clone(void) const
Abstract base class of 3D objects in a scene.
Definition: node.h:29
::osg::Vec4f osgVector4
Definition: config-osg.h:110
#define DEF_CLASS_SMART_PTR(className)
Definition: macros.h:50
Definition: action-search-bar.hh:27