Removed the experiemental osgPresentation classes. These are only partially functional and not appropriate for the stable OSG-3.4 release
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14758 16af8721-9629-0410-8352-f15c8da7e697
This commit is contained in:
@@ -17,7 +17,6 @@
|
||||
|
||||
#include <osgDB/ObjectWrapper>
|
||||
#include <osgDB/Registry>
|
||||
#include <osgPresentation/Group>
|
||||
#include <osg/ValueObject>
|
||||
|
||||
namespace osgDB
|
||||
|
||||
@@ -1,107 +0,0 @@
|
||||
/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2013 Robert Osfield
|
||||
*
|
||||
* This library is open source and may be redistributed and/or modified under
|
||||
* the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
|
||||
* (at your option) any later version. The full license is in LICENSE file
|
||||
* included with this distribution, and on the openscenegraph.org website.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* OpenSceneGraph Public License for more details.
|
||||
*/
|
||||
|
||||
#ifndef OSGPRESENTATION_ACTION
|
||||
#define OSGPRESENTATION_ACTION 1
|
||||
|
||||
#include <osgPresentation/Export>
|
||||
#include <osg/NodeVisitor>
|
||||
|
||||
namespace osgPresentation
|
||||
{
|
||||
|
||||
// forward declare osgPresention nodes
|
||||
class Group;
|
||||
|
||||
class Element;
|
||||
class Text;
|
||||
class Volume;
|
||||
class Model;
|
||||
class Image;
|
||||
class Movie;
|
||||
|
||||
class Section;
|
||||
class Layer;
|
||||
class Slide;
|
||||
class Presentation;
|
||||
|
||||
/** Action base class that is a NodeVistor that addes osgPresentation node support.*/
|
||||
class OSGPRESENTATION_EXPORT Action : public osg::NodeVisitor
|
||||
{
|
||||
public:
|
||||
Action(osg::NodeVisitor::TraversalMode traversalMode=osg::NodeVisitor::TRAVERSE_ACTIVE_CHILDREN):
|
||||
osg::NodeVisitor(traversalMode) {}
|
||||
|
||||
virtual void apply(osgPresentation::Group& group);
|
||||
|
||||
virtual void apply(osgPresentation::Element& element);
|
||||
virtual void apply(osgPresentation::Text& text);
|
||||
virtual void apply(osgPresentation::Volume& volume);
|
||||
virtual void apply(osgPresentation::Model& model);
|
||||
virtual void apply(osgPresentation::Image& image);
|
||||
virtual void apply(osgPresentation::Movie& movie);
|
||||
|
||||
virtual void apply(osgPresentation::Section& section);
|
||||
virtual void apply(osgPresentation::Layer& layer);
|
||||
virtual void apply(osgPresentation::Slide& slide);
|
||||
virtual void apply(osgPresentation::Presentation& presentation);
|
||||
};
|
||||
|
||||
|
||||
struct OSGPRESENTATION_EXPORT LoadAction : public Action
|
||||
{
|
||||
void apply(osgPresentation::Element& element);
|
||||
};
|
||||
|
||||
struct OSGPRESENTATION_EXPORT UnloadAction : public Action
|
||||
{
|
||||
void apply(osgPresentation::Element& element);
|
||||
};
|
||||
|
||||
struct OSGPRESENTATION_EXPORT ResetAction : public Action
|
||||
{
|
||||
void apply(osgPresentation::Element& element);
|
||||
};
|
||||
|
||||
struct OSGPRESENTATION_EXPORT PauseAction : public Action
|
||||
{
|
||||
void apply(osgPresentation::Element& element);
|
||||
};
|
||||
|
||||
struct OSGPRESENTATION_EXPORT PlayAction : public Action
|
||||
{
|
||||
void apply(osgPresentation::Element& element);
|
||||
};
|
||||
|
||||
struct OSGPRESENTATION_EXPORT PrintProperties : public osgPresentation::Action
|
||||
{
|
||||
PrintProperties(std::ostream& output) : osgPresentation::Action(osg::NodeVisitor::TRAVERSE_ALL_CHILDREN), _output(output) {}
|
||||
|
||||
void apply(osgPresentation::Group& group);
|
||||
|
||||
std::ostream& _output;
|
||||
};
|
||||
|
||||
struct OSGPRESENTATION_EXPORT PrintSupportedProperties : public osgPresentation::Action
|
||||
{
|
||||
PrintSupportedProperties(std::ostream& output) : osgPresentation::Action(osg::NodeVisitor::TRAVERSE_ALL_CHILDREN), _output(output) {}
|
||||
|
||||
void apply(osgPresentation::Group& group);
|
||||
|
||||
std::ostream& _output;
|
||||
};
|
||||
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,47 +0,0 @@
|
||||
/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield
|
||||
*
|
||||
* This library is open source and may be redistributed and/or modified under
|
||||
* the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
|
||||
* (at your option) any later version. The full license is in LICENSE file
|
||||
* included with this distribution, and on the openscenegraph.org website.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* OpenSceneGraph Public License for more details.
|
||||
*/
|
||||
|
||||
#ifndef OSGPRESENTATION_AUDIO
|
||||
#define OSGPRESENTATION_AUDIO 1
|
||||
|
||||
#include <osgPresentation/Element>
|
||||
|
||||
namespace osgPresentation {
|
||||
|
||||
/** osgPresentation::Audio
|
||||
*/
|
||||
class OSGPRESENTATION_EXPORT Audio : public osgPresentation::Element
|
||||
{
|
||||
public :
|
||||
|
||||
Audio() {}
|
||||
|
||||
/** Copy constructor using CopyOp to manage deep vs shallow copy. */
|
||||
Audio(const Audio& audio,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY) : osgPresentation::Element(audio,copyop) {}
|
||||
|
||||
META_Presentation(Audio);
|
||||
|
||||
/** load the audio subgraph.*/
|
||||
virtual bool load();
|
||||
|
||||
/** Get all types of Properties supported by Presentation Object type, return true if the Properties are supported, false otherwise.*/
|
||||
virtual bool getSupportedProperties(PropertyList&);
|
||||
|
||||
protected :
|
||||
|
||||
virtual ~Audio() {}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,69 +0,0 @@
|
||||
/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2013 Robert Osfield
|
||||
*
|
||||
* This library is open source and may be redistributed and/or modified under
|
||||
* the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
|
||||
* (at your option) any later version. The full license is in LICENSE file
|
||||
* included with this distribution, and on the openscenegraph.org website.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* OpenSceneGraph Public License for more details.
|
||||
*/
|
||||
|
||||
#ifndef OSGPRESENTATION_ELEMENT
|
||||
#define OSGPRESENTATION_ELEMENT 1
|
||||
|
||||
#include <osgPresentation/Group>
|
||||
#include <osgUtil/UpdateVisitor>
|
||||
#include <osgGA/EventVisitor>
|
||||
|
||||
namespace osgPresentation {
|
||||
|
||||
/** osgPresentation::Element
|
||||
*/
|
||||
class OSGPRESENTATION_EXPORT Element : public osgPresentation::Group
|
||||
{
|
||||
public :
|
||||
|
||||
Element() {}
|
||||
|
||||
/** Copy constructor using CopyOp to manage deep vs shallow copy. */
|
||||
Element(const Element& element,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY) : osgPresentation::Group(element,copyop) {}
|
||||
|
||||
META_Presentation(Element);
|
||||
|
||||
/** Load the subgraph implementation of the element.*/
|
||||
virtual bool load() { return false; }
|
||||
|
||||
/** Remove the the subgraph implementation, freeing up space.*/
|
||||
virtual bool unload() { removeChildren(0, getNumChildren()); return true; }
|
||||
|
||||
/** Return true if the subgraph implementation has been loaded.*/
|
||||
virtual bool loaded() const { return getNumChildren()!=0; }
|
||||
|
||||
|
||||
/** Enter the element for the first time, starting any animations, movies, audio etc..*/
|
||||
virtual void enter() {}
|
||||
|
||||
/** Leave the element, stopping any animations, movies, audio etc..*/
|
||||
virtual void leave() {}
|
||||
|
||||
|
||||
/** Pause any animatios, videos, audio etc.*/
|
||||
virtual void pause() {}
|
||||
|
||||
/** Play any animatios, videos, audio etc.*/
|
||||
virtual void play() {}
|
||||
|
||||
/** Reset any animations, vidoes, audio etc. back to the begininng.*/
|
||||
virtual void reset() {}
|
||||
|
||||
protected :
|
||||
|
||||
virtual ~Element() {}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,118 +0,0 @@
|
||||
/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2013 Robert Osfield
|
||||
*
|
||||
* This library is open source and may be redistributed and/or modified under
|
||||
* the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
|
||||
* (at your option) any later version. The full license is in LICENSE file
|
||||
* included with this distribution, and on the openscenegraph.org website.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* OpenSceneGraph Public License for more details.
|
||||
*/
|
||||
|
||||
#ifndef OSGPRESENTATION_GROUP
|
||||
#define OSGPRESENTATION_GROUP 1
|
||||
|
||||
#include <osg/MatrixTransform>
|
||||
#include <osg/ValueObject>
|
||||
#include <osgPresentation/Action>
|
||||
|
||||
#include <sstream>
|
||||
|
||||
namespace osgPresentation {
|
||||
|
||||
typedef std::pair< osg::ref_ptr<osg::Object>, std::string> ObjectDescription;
|
||||
typedef std::list< ObjectDescription > PropertyList;
|
||||
|
||||
/** META_Presentation macro define the standard clone, isSameKindAs, className
|
||||
* and accept methods. Use when subclassing from Node to make it
|
||||
* more convenient to define the required pure virtual methods.*/
|
||||
#define META_Presentation(name) \
|
||||
virtual osg::Object* cloneType() const { return new name (); } \
|
||||
virtual osg::Object* clone(const osg::CopyOp& copyop) const { return new name (*this,copyop); } \
|
||||
virtual bool isSameKindAs(const osg::Object* obj) const { return dynamic_cast<const name *>(obj)!=NULL; } \
|
||||
virtual const char* className() const { return #name; } \
|
||||
virtual const char* libraryName() const { return "osgPresentation"; } \
|
||||
virtual void accept(osg::NodeVisitor& nv) \
|
||||
{ \
|
||||
if (nv.validNodeMask(*this)) \
|
||||
{ \
|
||||
nv.pushOntoNodePath(this); \
|
||||
osgPresentation::Action* action = dynamic_cast<osgPresentation::Action*>(&nv); \
|
||||
if (action) action->apply(*this); \
|
||||
else nv.apply(*this); \
|
||||
nv.popFromNodePath(); \
|
||||
} \
|
||||
}
|
||||
|
||||
/** osgPresentation::Group
|
||||
*/
|
||||
class OSGPRESENTATION_EXPORT Group : public osg::MatrixTransform
|
||||
{
|
||||
public :
|
||||
|
||||
Group() {}
|
||||
|
||||
/** Copy constructor using CopyOp to manage deep vs shallow copy. */
|
||||
Group(const Group& group,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY) : osg::MatrixTransform(group,copyop) {}
|
||||
|
||||
META_Presentation(Group);
|
||||
|
||||
/** Convinience method that casts the named UserObject to osg::TemplateValueObject<T> and gets the value.
|
||||
* To use this template method you need to include the osg/ValueObject header.*/
|
||||
template<typename T>
|
||||
bool getProperty(const std::string& name, T& value) const
|
||||
{
|
||||
return getUserValue(name, value);
|
||||
}
|
||||
|
||||
/** Convinience method that creates the osg::TemplateValueObject<T> to store the
|
||||
* specified value and adds it as a named UserObject.
|
||||
* To use this template method you need to include the osg/ValueObject header. */
|
||||
template<typename T>
|
||||
void setProperty(const std::string& name, const T& value)
|
||||
{
|
||||
setUserValue(name, value);
|
||||
}
|
||||
|
||||
/** Check for named Property, if it doesn't exist on this object check parents recursively for instances.*/
|
||||
osg::Object* getPropertyObject(const std::string& name, bool checkParents = true);
|
||||
|
||||
/** Check for name Property, and convert to desired template value where possible. */
|
||||
template<typename T>
|
||||
bool getPropertyValue(const std::string& name, T& value, bool checkParents = true)
|
||||
{
|
||||
osg::Object* object = getPropertyObject(name, checkParents);
|
||||
if (!object) return false;
|
||||
|
||||
typedef osg::TemplateValueObject<T> UserValueObject;
|
||||
const UserValueObject* uvo = dynamic_cast<const UserValueObject*>(object);
|
||||
if (uvo)
|
||||
{
|
||||
value = uvo->getValue();
|
||||
return true;
|
||||
}
|
||||
|
||||
osg::StringValueObject* svo = dynamic_cast<osg::StringValueObject*>(object);
|
||||
if (svo)
|
||||
{
|
||||
std::istringstream str(svo->getValue());
|
||||
str >> value;
|
||||
return !str.fail();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
/** Get all types of Properties supported by Presentation Object type, return true if the Properties are supported, false otherwise.*/
|
||||
virtual bool getSupportedProperties(PropertyList&) { return false; }
|
||||
|
||||
|
||||
protected :
|
||||
|
||||
virtual ~Group() {}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,47 +0,0 @@
|
||||
/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield
|
||||
*
|
||||
* This library is open source and may be redistributed and/or modified under
|
||||
* the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
|
||||
* (at your option) any later version. The full license is in LICENSE file
|
||||
* included with this distribution, and on the openscenegraph.org website.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* OpenSceneGraph Public License for more details.
|
||||
*/
|
||||
|
||||
#ifndef OSGPRESENTATION_IMAGE
|
||||
#define OSGPRESENTATION_IMAGE 1
|
||||
|
||||
#include <osgPresentation/Element>
|
||||
|
||||
namespace osgPresentation {
|
||||
|
||||
/** osgPresentation::Image
|
||||
*/
|
||||
class OSGPRESENTATION_EXPORT Image : public osgPresentation::Element
|
||||
{
|
||||
public :
|
||||
|
||||
Image() {}
|
||||
|
||||
/** Copy constructor using CopyOp to manage deep vs shallow copy. */
|
||||
Image(const Image& image,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY) : osgPresentation::Element(image,copyop) {}
|
||||
|
||||
META_Presentation(Image);
|
||||
|
||||
/** load the image subgraph.*/
|
||||
virtual bool load();
|
||||
|
||||
/** Get all types of Properties supported by Presentation Object type, return true if the Properties are supported, false otherwise.*/
|
||||
virtual bool getSupportedProperties(PropertyList&);
|
||||
|
||||
protected :
|
||||
|
||||
virtual ~Image() {}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,44 +0,0 @@
|
||||
/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield
|
||||
*
|
||||
* This library is open source and may be redistributed and/or modified under
|
||||
* the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
|
||||
* (at your option) any later version. The full license is in LICENSE file
|
||||
* included with this distribution, and on the openscenegraph.org website.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* OpenSceneGraph Public License for more details.
|
||||
*/
|
||||
|
||||
#ifndef OSGPRESENTATION_LAYER
|
||||
#define OSGPRESENTATION_LAYER 1
|
||||
|
||||
#include <osgPresentation/Group>
|
||||
|
||||
namespace osgPresentation {
|
||||
|
||||
/** osgPresentation::Layer
|
||||
*/
|
||||
class OSGPRESENTATION_EXPORT Layer : public osgPresentation::Group
|
||||
{
|
||||
public :
|
||||
|
||||
Layer() {}
|
||||
|
||||
/** Copy constructor using CopyOp to manage deep vs shallow copy. */
|
||||
Layer(const Layer& layer,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY) : osgPresentation::Group(layer,copyop) {}
|
||||
|
||||
META_Presentation(Layer);
|
||||
|
||||
/** Get all types of Properties supported by Presentation Object type, return true if the Properties are supported, false otherwise.*/
|
||||
virtual bool getSupportedProperties(PropertyList&);
|
||||
|
||||
protected :
|
||||
|
||||
virtual ~Layer() {}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,47 +0,0 @@
|
||||
/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield
|
||||
*
|
||||
* This library is open source and may be redistributed and/or modified under
|
||||
* the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
|
||||
* (at your option) any later version. The full license is in LICENSE file
|
||||
* included with this distribution, and on the openscenegraph.org website.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* OpenSceneGraph Public License for more details.
|
||||
*/
|
||||
|
||||
#ifndef OSGPRESENTATION_MODEL
|
||||
#define OSGPRESENTATION_MODEL 1
|
||||
|
||||
#include <osgPresentation/Element>
|
||||
|
||||
namespace osgPresentation {
|
||||
|
||||
/** osgPresentation::Model
|
||||
*/
|
||||
class OSGPRESENTATION_EXPORT Model : public osgPresentation::Element
|
||||
{
|
||||
public :
|
||||
|
||||
Model() {}
|
||||
|
||||
/** Copy constructor using CopyOp to manage deep vs shallow copy. */
|
||||
Model(const Model& model,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY) : osgPresentation::Element(model,copyop) {}
|
||||
|
||||
META_Presentation(Model);
|
||||
|
||||
/** load the model subgraph.*/
|
||||
virtual bool load();
|
||||
|
||||
/** Get all types of Properties supported by Presentation Object type, return true if the Properties are supported, false otherwise.*/
|
||||
virtual bool getSupportedProperties(PropertyList&);
|
||||
|
||||
protected :
|
||||
|
||||
virtual ~Model() {}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,47 +0,0 @@
|
||||
/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield
|
||||
*
|
||||
* This library is open source and may be redistributed and/or modified under
|
||||
* the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
|
||||
* (at your option) any later version. The full license is in LICENSE file
|
||||
* included with this distribution, and on the openscenegraph.org website.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* OpenSceneGraph Public License for more details.
|
||||
*/
|
||||
|
||||
#ifndef OSGPRESENTATION_MOVIE
|
||||
#define OSGPRESENTATION_MOVIE 1
|
||||
|
||||
#include <osgPresentation/Element>
|
||||
|
||||
namespace osgPresentation {
|
||||
|
||||
/** osgPresentation::Movie
|
||||
*/
|
||||
class OSGPRESENTATION_EXPORT Movie : public osgPresentation::Element
|
||||
{
|
||||
public :
|
||||
|
||||
Movie() {}
|
||||
|
||||
/** Copy constructor using CopyOp to manage deep vs shallow copy. */
|
||||
Movie(const Movie& movie,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY) : osgPresentation::Element(movie,copyop) {}
|
||||
|
||||
META_Presentation(Movie);
|
||||
|
||||
/** load the movie subgraph.*/
|
||||
virtual bool load();
|
||||
|
||||
/** Get all types of Properties supported by Presentation Object type, return true if the Properties are supported, false otherwise.*/
|
||||
virtual bool getSupportedProperties(PropertyList&);
|
||||
|
||||
protected :
|
||||
|
||||
virtual ~Movie() {}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,44 +0,0 @@
|
||||
/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield
|
||||
*
|
||||
* This library is open source and may be redistributed and/or modified under
|
||||
* the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
|
||||
* (at your option) any later version. The full license is in LICENSE file
|
||||
* included with this distribution, and on the openscenegraph.org website.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* OpenSceneGraph Public License for more details.
|
||||
*/
|
||||
|
||||
#ifndef OSGPRESENTATION_PRESENTATION
|
||||
#define OSGPRESENTATION_PRESENTATION 1
|
||||
|
||||
#include <osgPresentation/Group>
|
||||
|
||||
namespace osgPresentation {
|
||||
|
||||
/** osgPresentation::Presentation
|
||||
*/
|
||||
class OSGPRESENTATION_EXPORT Presentation : public osgPresentation::Group
|
||||
{
|
||||
public :
|
||||
|
||||
Presentation() {}
|
||||
|
||||
/** Copy constructor using CopyOp to manage deep vs shallow copy. */
|
||||
Presentation(const Presentation& presentation,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY) : osgPresentation::Group(presentation,copyop) {}
|
||||
|
||||
META_Presentation(Presentation);
|
||||
|
||||
/** Get all types of Properties supported by Presentation Object type, return true if the Properties are supported, false otherwise.*/
|
||||
virtual bool getSupportedProperties(PropertyList&);
|
||||
|
||||
protected :
|
||||
|
||||
virtual ~Presentation() {}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,62 +0,0 @@
|
||||
/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield
|
||||
*
|
||||
* This library is open source and may be redistributed and/or modified under
|
||||
* the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
|
||||
* (at your option) any later version. The full license is in LICENSE file
|
||||
* included with this distribution, and on the openscenegraph.org website.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* OpenSceneGraph Public License for more details.
|
||||
*/
|
||||
|
||||
#ifndef OSGPRESENTATION_PRESENTATIONINTERFACE
|
||||
#define OSGPRESENTATION_PRESENTATIONINTERFACE 1
|
||||
|
||||
#include <osgViewer/ViewerBase>
|
||||
#include <osgPresentation/deprecated/SlideEventHandler>
|
||||
|
||||
namespace osgPresentation {
|
||||
|
||||
/** PresentationInterface is a helper class for scripting languages to use to access the key services of the presentation.*/
|
||||
class OSGPRESENTATION_EXPORT PresentationInterface : public osg::Object
|
||||
{
|
||||
public :
|
||||
|
||||
PresentationInterface() {}
|
||||
|
||||
/** Copy constructor using CopyOp to manage deep vs shallow copy. */
|
||||
PresentationInterface(const PresentationInterface& pi,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY) : osg::Object(pi,copyop) {}
|
||||
|
||||
META_Object(osgPresentation, PresentationInterface);
|
||||
|
||||
/** get the viewer associated with the current active presentation.*/
|
||||
osgViewer::ViewerBase* getViewer();
|
||||
|
||||
/** get current active root presentation Node.*/
|
||||
osg::Node* getPresentation();
|
||||
|
||||
/** get SlideEventHandler that is managing the current active presentation.*/
|
||||
osgPresentation::SlideEventHandler* getSlideEventHandler();
|
||||
|
||||
/** pass on a jump command to the presentation to change layer/slide.*/
|
||||
void jump(const osgPresentation::JumpData* jumpdata);
|
||||
|
||||
/** send KeyPosition event to viewer so that that it can be handled by the viewer and associated event handlers. */
|
||||
void sendEventToViewer(const osgPresentation::KeyPosition* kp);
|
||||
|
||||
/** send event to viewer so that that it can be handled by the viewer and associated event handlers. */
|
||||
void sendEventToViewer(osgGA::Event* event);
|
||||
|
||||
/** send event to devices attached to the viewer. */
|
||||
void sendEventToDevices(osgGA::Event* event);
|
||||
|
||||
protected :
|
||||
|
||||
virtual ~PresentationInterface() {}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,44 +0,0 @@
|
||||
/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield
|
||||
*
|
||||
* This library is open source and may be redistributed and/or modified under
|
||||
* the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
|
||||
* (at your option) any later version. The full license is in LICENSE file
|
||||
* included with this distribution, and on the openscenegraph.org website.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* OpenSceneGraph Public License for more details.
|
||||
*/
|
||||
|
||||
#ifndef OSGPRESENTATION_SECTION
|
||||
#define OSGPRESENTATION_SECTION 1
|
||||
|
||||
#include <osgPresentation/Group>
|
||||
|
||||
namespace osgPresentation {
|
||||
|
||||
/** osgPresentation::Group
|
||||
*/
|
||||
class OSGPRESENTATION_EXPORT Section : public osgPresentation::Group
|
||||
{
|
||||
public :
|
||||
|
||||
Section() {}
|
||||
|
||||
/** Copy constructor using CopyOp to manage deep vs shallow copy. */
|
||||
Section(const Section& section,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY) : osgPresentation::Group(section,copyop) {}
|
||||
|
||||
META_Presentation(Section);
|
||||
|
||||
/** Get all types of Properties supported by Presentation Object type, return true if the Properties are supported, false otherwise.*/
|
||||
virtual bool getSupportedProperties(PropertyList&);
|
||||
|
||||
protected :
|
||||
|
||||
virtual ~Section() {}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,44 +0,0 @@
|
||||
/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield
|
||||
*
|
||||
* This library is open source and may be redistributed and/or modified under
|
||||
* the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
|
||||
* (at your option) any later version. The full license is in LICENSE file
|
||||
* included with this distribution, and on the openscenegraph.org website.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* OpenSceneGraph Public License for more details.
|
||||
*/
|
||||
|
||||
#ifndef OSGPRESENTATION_SHOW
|
||||
#define OSGPRESENTATION_SHOW 1
|
||||
|
||||
#include <osgPresentation/Group>
|
||||
|
||||
namespace osgPresentation {
|
||||
|
||||
/** osgPresentation::Show
|
||||
*/
|
||||
class OSGPRESENTATION_EXPORT Show : public osgPresentation::Group
|
||||
{
|
||||
public :
|
||||
|
||||
Show() {}
|
||||
|
||||
/** Copy constructor using CopyOp to manage deep vs shallow copy. */
|
||||
Show(const Show& presentation,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY) : osgPresentation::Group(presentation,copyop) {}
|
||||
|
||||
META_Presentation(Show);
|
||||
|
||||
/** Get all types of Properties supported by Presentation Object type, return true if the Properties are supported, false otherwise.*/
|
||||
virtual bool getSupportedProperties(PropertyList&);
|
||||
|
||||
protected :
|
||||
|
||||
virtual ~Show() {}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,44 +0,0 @@
|
||||
/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield
|
||||
*
|
||||
* This library is open source and may be redistributed and/or modified under
|
||||
* the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
|
||||
* (at your option) any later version. The full license is in LICENSE file
|
||||
* included with this distribution, and on the openscenegraph.org website.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* OpenSceneGraph Public License for more details.
|
||||
*/
|
||||
|
||||
#ifndef OSGPRESENTATION_SLIDE
|
||||
#define OSGPRESENTATION_SLIDE 1
|
||||
|
||||
#include <osgPresentation/Group>
|
||||
|
||||
namespace osgPresentation {
|
||||
|
||||
/** osgPresentation::Slide
|
||||
*/
|
||||
class OSGPRESENTATION_EXPORT Slide : public osgPresentation::Group
|
||||
{
|
||||
public :
|
||||
|
||||
Slide() {}
|
||||
|
||||
/** Copy constructor using CopyOp to manage deep vs shallow copy. */
|
||||
Slide(const Slide& slide,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY) : osgPresentation::Group(slide,copyop) {}
|
||||
|
||||
META_Presentation(Slide);
|
||||
|
||||
/** Get all types of Properties supported by Presentation Object type, return true if the Properties are supported, false otherwise.*/
|
||||
virtual bool getSupportedProperties(PropertyList&);
|
||||
|
||||
protected :
|
||||
|
||||
virtual ~Slide() {}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,47 +0,0 @@
|
||||
/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2013 Robert Osfield
|
||||
*
|
||||
* This library is open source and may be redistributed and/or modified under
|
||||
* the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
|
||||
* (at your option) any later version. The full license is in LICENSE file
|
||||
* included with this distribution, and on the openscenegraph.org website.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* OpenSceneGraph Public License for more details.
|
||||
*/
|
||||
|
||||
#ifndef OSGPRESENTATION_TEXT
|
||||
#define OSGPRESENTATION_TEXT 1
|
||||
|
||||
#include <osgPresentation/Element>
|
||||
|
||||
namespace osgPresentation {
|
||||
|
||||
/** osgPresentation::Text
|
||||
*/
|
||||
class OSGPRESENTATION_EXPORT Text : public osgPresentation::Element
|
||||
{
|
||||
public :
|
||||
|
||||
Text() {}
|
||||
|
||||
/** Copy constructor using CopyOp to manage deep vs shallow copy. */
|
||||
Text(const Text& text,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY) : osgPresentation::Element(text,copyop) {}
|
||||
|
||||
META_Presentation(Text);
|
||||
|
||||
/** load the text subgraph.*/
|
||||
virtual bool load();
|
||||
|
||||
/** Get all types of Properties supported by Presentation Object type, return true if the Properties are supported, false otherwise.*/
|
||||
virtual bool getSupportedProperties(PropertyList&);
|
||||
|
||||
protected :
|
||||
|
||||
virtual ~Text() {}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,47 +0,0 @@
|
||||
/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield
|
||||
*
|
||||
* This library is open source and may be redistributed and/or modified under
|
||||
* the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
|
||||
* (at your option) any later version. The full license is in LICENSE file
|
||||
* included with this distribution, and on the openscenegraph.org website.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* OpenSceneGraph Public License for more details.
|
||||
*/
|
||||
|
||||
#ifndef OSGPRESENTATION_VOLUME
|
||||
#define OSGPRESENTATION_VOLUME 1
|
||||
|
||||
#include <osgPresentation/Element>
|
||||
|
||||
namespace osgPresentation {
|
||||
|
||||
/** osgPresentation::Volume
|
||||
*/
|
||||
class OSGPRESENTATION_EXPORT Volume : public osgPresentation::Element
|
||||
{
|
||||
public :
|
||||
|
||||
Volume() {}
|
||||
|
||||
/** Copy constructor using CopyOp to manage deep vs shallow copy. */
|
||||
Volume(const Volume& volume,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY) : osgPresentation::Element(volume,copyop) {}
|
||||
|
||||
META_Presentation(Volume);
|
||||
|
||||
/** load the volume subgraph.*/
|
||||
virtual bool load();
|
||||
|
||||
/** Get all types of Properties supported by Presentation Object type, return true if the Properties are supported, false otherwise.*/
|
||||
virtual bool getSupportedProperties(PropertyList&);
|
||||
|
||||
protected :
|
||||
|
||||
virtual ~Volume() {}
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user