From 26d1679248aa2e26a9cca42fc94ad8348c37ea79 Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Wed, 4 Mar 2015 17:42:30 +0000 Subject: [PATCH] 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 --- examples/CMakeLists.txt | 1 - include/osgDB/ClassInterface | 1 - include/osgPresentation/Action | 107 ---------- include/osgPresentation/Audio | 47 ----- include/osgPresentation/Element | 69 ------- include/osgPresentation/Group | 118 ----------- include/osgPresentation/Image | 47 ----- include/osgPresentation/Layer | 44 ---- include/osgPresentation/Model | 47 ----- include/osgPresentation/Movie | 47 ----- include/osgPresentation/Presentation | 44 ---- include/osgPresentation/PresentationInterface | 62 ------ include/osgPresentation/Section | 44 ---- include/osgPresentation/Show | 44 ---- include/osgPresentation/Slide | 44 ---- include/osgPresentation/Text | 47 ----- include/osgPresentation/Volume | 47 ----- src/osgPresentation/Action.cpp | 195 ------------------ src/osgPresentation/Audio.cpp | 42 ---- src/osgPresentation/CMakeLists.txt | 37 +--- src/osgPresentation/Element.cpp | 18 -- src/osgPresentation/Group.cpp | 41 ---- src/osgPresentation/Image.cpp | 64 ------ src/osgPresentation/Layer.cpp | 24 --- src/osgPresentation/Model.cpp | 51 ----- src/osgPresentation/Movie.cpp | 69 ------- src/osgPresentation/Presentation.cpp | 23 --- src/osgPresentation/PresentationInterface.cpp | 57 ----- src/osgPresentation/Section.cpp | 23 --- src/osgPresentation/Show.cpp | 23 --- src/osgPresentation/Slide.cpp | 23 --- src/osgPresentation/Text.cpp | 52 ----- src/osgPresentation/Volume.cpp | 55 ----- src/osgWrappers/serializers/CMakeLists.txt | 1 - .../serializers/osgPresentation/Audio.cpp | 11 - .../osgPresentation/CMakeLists.txt | 7 - .../serializers/osgPresentation/Element.cpp | 11 - .../serializers/osgPresentation/Group.cpp | 11 - .../serializers/osgPresentation/Image.cpp | 11 - .../serializers/osgPresentation/Layer.cpp | 11 - .../serializers/osgPresentation/Model.cpp | 11 - .../serializers/osgPresentation/Movie.cpp | 11 - .../osgPresentation/Presentation.cpp | 11 - .../osgPresentation/PresentationInterface.cpp | 87 -------- .../serializers/osgPresentation/Section.cpp | 11 - .../serializers/osgPresentation/Show.cpp | 11 - .../serializers/osgPresentation/Slide.cpp | 11 - .../serializers/osgPresentation/Text.cpp | 11 - .../serializers/osgPresentation/Volume.cpp | 11 - 49 files changed, 1 insertion(+), 1894 deletions(-) delete mode 100644 include/osgPresentation/Action delete mode 100644 include/osgPresentation/Audio delete mode 100644 include/osgPresentation/Element delete mode 100644 include/osgPresentation/Group delete mode 100644 include/osgPresentation/Image delete mode 100644 include/osgPresentation/Layer delete mode 100644 include/osgPresentation/Model delete mode 100644 include/osgPresentation/Movie delete mode 100644 include/osgPresentation/Presentation delete mode 100644 include/osgPresentation/PresentationInterface delete mode 100644 include/osgPresentation/Section delete mode 100644 include/osgPresentation/Show delete mode 100644 include/osgPresentation/Slide delete mode 100644 include/osgPresentation/Text delete mode 100644 include/osgPresentation/Volume delete mode 100644 src/osgPresentation/Action.cpp delete mode 100644 src/osgPresentation/Audio.cpp delete mode 100644 src/osgPresentation/Element.cpp delete mode 100644 src/osgPresentation/Group.cpp delete mode 100644 src/osgPresentation/Image.cpp delete mode 100644 src/osgPresentation/Layer.cpp delete mode 100644 src/osgPresentation/Model.cpp delete mode 100644 src/osgPresentation/Movie.cpp delete mode 100644 src/osgPresentation/Presentation.cpp delete mode 100644 src/osgPresentation/PresentationInterface.cpp delete mode 100644 src/osgPresentation/Section.cpp delete mode 100644 src/osgPresentation/Show.cpp delete mode 100644 src/osgPresentation/Slide.cpp delete mode 100644 src/osgPresentation/Text.cpp delete mode 100644 src/osgPresentation/Volume.cpp delete mode 100644 src/osgWrappers/serializers/osgPresentation/Audio.cpp delete mode 100644 src/osgWrappers/serializers/osgPresentation/CMakeLists.txt delete mode 100644 src/osgWrappers/serializers/osgPresentation/Element.cpp delete mode 100644 src/osgWrappers/serializers/osgPresentation/Group.cpp delete mode 100644 src/osgWrappers/serializers/osgPresentation/Image.cpp delete mode 100644 src/osgWrappers/serializers/osgPresentation/Layer.cpp delete mode 100644 src/osgWrappers/serializers/osgPresentation/Model.cpp delete mode 100644 src/osgWrappers/serializers/osgPresentation/Movie.cpp delete mode 100644 src/osgWrappers/serializers/osgPresentation/Presentation.cpp delete mode 100644 src/osgWrappers/serializers/osgPresentation/PresentationInterface.cpp delete mode 100644 src/osgWrappers/serializers/osgPresentation/Section.cpp delete mode 100644 src/osgWrappers/serializers/osgPresentation/Show.cpp delete mode 100644 src/osgWrappers/serializers/osgPresentation/Slide.cpp delete mode 100644 src/osgWrappers/serializers/osgPresentation/Text.cpp delete mode 100644 src/osgWrappers/serializers/osgPresentation/Volume.cpp diff --git a/examples/CMakeLists.txt b/examples/CMakeLists.txt index d58e100e4..b4d2c608f 100644 --- a/examples/CMakeLists.txt +++ b/examples/CMakeLists.txt @@ -94,7 +94,6 @@ IF(DYNAMIC_OPENSCENEGRAPH) ADD_SUBDIRECTORY(osgprecipitation) ADD_SUBDIRECTORY(osgprerender) ADD_SUBDIRECTORY(osgprerendercubemap) - ADD_SUBDIRECTORY(osgpresentation) ADD_SUBDIRECTORY(osgreflect) ADD_SUBDIRECTORY(osgrobot) ADD_SUBDIRECTORY(osgSSBO) diff --git a/include/osgDB/ClassInterface b/include/osgDB/ClassInterface index fa78e4cbe..1fe6a1ae2 100644 --- a/include/osgDB/ClassInterface +++ b/include/osgDB/ClassInterface @@ -17,7 +17,6 @@ #include #include -#include #include namespace osgDB diff --git a/include/osgPresentation/Action b/include/osgPresentation/Action deleted file mode 100644 index 7ec6a7786..000000000 --- a/include/osgPresentation/Action +++ /dev/null @@ -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 -#include - -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 diff --git a/include/osgPresentation/Audio b/include/osgPresentation/Audio deleted file mode 100644 index d78a41b03..000000000 --- a/include/osgPresentation/Audio +++ /dev/null @@ -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 - -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 diff --git a/include/osgPresentation/Element b/include/osgPresentation/Element deleted file mode 100644 index 6d5d07cc4..000000000 --- a/include/osgPresentation/Element +++ /dev/null @@ -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 -#include -#include - -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 diff --git a/include/osgPresentation/Group b/include/osgPresentation/Group deleted file mode 100644 index 3d26be58f..000000000 --- a/include/osgPresentation/Group +++ /dev/null @@ -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 -#include -#include - -#include - -namespace osgPresentation { - -typedef std::pair< osg::ref_ptr, 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(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(&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 and gets the value. - * To use this template method you need to include the osg/ValueObject header.*/ - template - bool getProperty(const std::string& name, T& value) const - { - return getUserValue(name, value); - } - - /** Convinience method that creates the osg::TemplateValueObject 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 - 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 - bool getPropertyValue(const std::string& name, T& value, bool checkParents = true) - { - osg::Object* object = getPropertyObject(name, checkParents); - if (!object) return false; - - typedef osg::TemplateValueObject UserValueObject; - const UserValueObject* uvo = dynamic_cast(object); - if (uvo) - { - value = uvo->getValue(); - return true; - } - - osg::StringValueObject* svo = dynamic_cast(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 diff --git a/include/osgPresentation/Image b/include/osgPresentation/Image deleted file mode 100644 index e7a9f87e2..000000000 --- a/include/osgPresentation/Image +++ /dev/null @@ -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 - -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 diff --git a/include/osgPresentation/Layer b/include/osgPresentation/Layer deleted file mode 100644 index c1dfe8c86..000000000 --- a/include/osgPresentation/Layer +++ /dev/null @@ -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 - -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 diff --git a/include/osgPresentation/Model b/include/osgPresentation/Model deleted file mode 100644 index 9b641d419..000000000 --- a/include/osgPresentation/Model +++ /dev/null @@ -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 - -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 diff --git a/include/osgPresentation/Movie b/include/osgPresentation/Movie deleted file mode 100644 index 89f12bb2b..000000000 --- a/include/osgPresentation/Movie +++ /dev/null @@ -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 - -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 diff --git a/include/osgPresentation/Presentation b/include/osgPresentation/Presentation deleted file mode 100644 index 87bc1d9d1..000000000 --- a/include/osgPresentation/Presentation +++ /dev/null @@ -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 - -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 diff --git a/include/osgPresentation/PresentationInterface b/include/osgPresentation/PresentationInterface deleted file mode 100644 index a87713fd0..000000000 --- a/include/osgPresentation/PresentationInterface +++ /dev/null @@ -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 -#include - -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 diff --git a/include/osgPresentation/Section b/include/osgPresentation/Section deleted file mode 100644 index fb544671b..000000000 --- a/include/osgPresentation/Section +++ /dev/null @@ -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 - -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 diff --git a/include/osgPresentation/Show b/include/osgPresentation/Show deleted file mode 100644 index cab5c1c9f..000000000 --- a/include/osgPresentation/Show +++ /dev/null @@ -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 - -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 diff --git a/include/osgPresentation/Slide b/include/osgPresentation/Slide deleted file mode 100644 index 5281ec402..000000000 --- a/include/osgPresentation/Slide +++ /dev/null @@ -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 - -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 diff --git a/include/osgPresentation/Text b/include/osgPresentation/Text deleted file mode 100644 index 4d1d7384c..000000000 --- a/include/osgPresentation/Text +++ /dev/null @@ -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 - -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 diff --git a/include/osgPresentation/Volume b/include/osgPresentation/Volume deleted file mode 100644 index 7cf9348db..000000000 --- a/include/osgPresentation/Volume +++ /dev/null @@ -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 - -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 diff --git a/src/osgPresentation/Action.cpp b/src/osgPresentation/Action.cpp deleted file mode 100644 index 1c8febbe9..000000000 --- a/src/osgPresentation/Action.cpp +++ /dev/null @@ -1,195 +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. -*/ - -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include - -using namespace osgPresentation; - -////////////////////////////////////////////////////////////////////////////////// -// -// Action base class -// -void Action::apply(osgPresentation::Group& group) -{ - OSG_NOTICE<<"LoadAction::apply()"<(element)); -} - -void Action::apply(osgPresentation::Text& text) -{ - apply(static_cast(text)); -} - -void Action::apply(osgPresentation::Volume& volume) -{ - apply(static_cast(volume)); -} - -void Action::apply(osgPresentation::Model& model) -{ - apply(static_cast(model)); -} - -void Action::apply(osgPresentation::Image& image) -{ - apply(static_cast(image)); -} - -void Action::apply(osgPresentation::Movie& movie) -{ - apply(static_cast(movie)); -} - - -void Action::apply(osgPresentation::Section& section) -{ - apply(static_cast(section)); -} - -void Action::apply(osgPresentation::Layer& layer) -{ - apply(static_cast(layer)); -} - -void Action::apply(osgPresentation::Slide& slide) -{ - apply(static_cast(slide)); -} - -void Action::apply(osgPresentation::Presentation& presentation) -{ - apply(static_cast(presentation)); -} - - -///////////////////////////////////////////////////////////////////////// -// -// Specific Action implementations -// -void LoadAction::apply(osgPresentation::Element& element) -{ - OSG_NOTICE<<"LoadAction::apply()"< - void print(const T& value) { _output << value; } - - virtual void apply(bool value) { print(value); } - virtual void apply(char value) { print(value); } - virtual void apply(unsigned char value) { print(value); } - virtual void apply(short value) { print(value); } - virtual void apply(unsigned short value) { print(value); } - virtual void apply(int value) { print(value); } - virtual void apply(unsigned int value) { print(value); } - virtual void apply(float value) { print(value); } - virtual void apply(double value) { print(value); } - virtual void apply(const std::string& value) { print(value); } - virtual void apply(const osg::Vec2f& value) { print(value); } - virtual void apply(const osg::Vec3f& value) { print(value); } - virtual void apply(const osg::Vec4f& value) { print(value); } - virtual void apply(const osg::Vec2d& value) { print(value); } - virtual void apply(const osg::Vec3d& value) { print(value); } - virtual void apply(const osg::Vec4d& value) { print(value); } - virtual void apply(const osg::Quat& value) { print(value); } - virtual void apply(const osg::Plane& value) { print(value); } - virtual void apply(const osg::Matrixf& value) { print(value); } - virtual void apply(const osg::Matrixd& value) { print(value); } - - std::ostream& _output; -}; - -void PrintProperties::apply(osgPresentation::Group& group) -{ - _output<<"PrintProperties osgPresentation object : "<getNumUserObjects(); ++i) - { - osg::ValueObject* value_object = dynamic_cast(udc->getUserObject(i)); - if (value_object) - { - _output<<" "<className()<<" : "<getName()<<" : "; - value_object->get(pvv); - _output<className()<<" : "<getName()<<", description = "< -#include -#include - -using namespace osgPresentation; - - -bool Audio::load() -{ - OSG_NOTICE<<"Audio::load() Not implemented yet"< - -using namespace osgPresentation; - - diff --git a/src/osgPresentation/Group.cpp b/src/osgPresentation/Group.cpp deleted file mode 100644 index 54e045780..000000000 --- a/src/osgPresentation/Group.cpp +++ /dev/null @@ -1,41 +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. -*/ - -#include -#include - -using namespace osgPresentation; - -class PropertyVisitor : public osg::NodeVisitor -{ - public: - PropertyVisitor(const std::string& name) : _name(name), _object(0) {} - - void apply(osg::Node& node) - { - osg::UserDataContainer* udc = node.getUserDataContainer(); - _object = udc ? udc->getUserObject(_name) : 0; - if (!_object) traverse(node); - }; - - std::string _name; - osg::Object* _object; -}; - -osg::Object* Group::getPropertyObject(const std::string& name, bool checkParents) -{ - PropertyVisitor pv(name); - if (checkParents) pv.setTraversalMode(osg::NodeVisitor::TRAVERSE_PARENTS); - accept(pv); - return pv._object; -} diff --git a/src/osgPresentation/Image.cpp b/src/osgPresentation/Image.cpp deleted file mode 100644 index 03c1bbbc8..000000000 --- a/src/osgPresentation/Image.cpp +++ /dev/null @@ -1,64 +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. -*/ - -#include -#include -#include -#include -#include - -using namespace osgPresentation; - - -bool Image::load() -{ - OSG_NOTICE<<"Image::load() Not implemented yet"< -#include - -using namespace osgPresentation; - -bool Layer::getSupportedProperties(PropertyList& pl) -{ - pl.push_back(ObjectDescription(new osg::Vec4dValueObject("background_colour",osg::Vec4d(0.0,0.0,0.0,0.0)), std::string("Background colour."))); - pl.push_back(ObjectDescription(new osg::Vec4dValueObject("text_colour",osg::Vec4d(1.0,1.0,1.0,1.0)), std::string("Text colour."))); - return true; -} diff --git a/src/osgPresentation/Model.cpp b/src/osgPresentation/Model.cpp deleted file mode 100644 index 70c94a517..000000000 --- a/src/osgPresentation/Model.cpp +++ /dev/null @@ -1,51 +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. -*/ - -#include -#include -#include - -using namespace osgPresentation; - - -bool Model::load() -{ - OSG_NOTICE<<"Model::load() Not implemented yet"< -#include -#include -#include -#include - -using namespace osgPresentation; - - -bool Movie::load() -{ - OSG_NOTICE<<"Movie::load() Not implemented yet"< - -using namespace osgPresentation; - -bool Presentation::getSupportedProperties(PropertyList& pl) -{ - pl.push_back(ObjectDescription(new osg::Vec4dValueObject("background_colour",osg::Vec4d(0.0,0.0,0.0,0.0)), std::string("Background colour."))); - pl.push_back(ObjectDescription(new osg::Vec4dValueObject("text_colour",osg::Vec4d(1.0,1.0,1.0,1.0)), std::string("Text colour."))); - return true; -} diff --git a/src/osgPresentation/PresentationInterface.cpp b/src/osgPresentation/PresentationInterface.cpp deleted file mode 100644 index 71a52ad28..000000000 --- a/src/osgPresentation/PresentationInterface.cpp +++ /dev/null @@ -1,57 +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. -*/ - -#include - -using namespace osgPresentation; - -osgViewer::ViewerBase* PresentationInterface::getViewer() -{ - SlideEventHandler* seh = SlideEventHandler::instance(); - return (seh!=0) ? seh->getViewer() : 0; -} - -osg::Node* PresentationInterface::getPresentation() -{ - SlideEventHandler* seh = SlideEventHandler::instance(); - return (seh!=0) ? seh->getPresentationSwitch() : 0; -} - -osgPresentation::SlideEventHandler* PresentationInterface::getSlideEventHandler() -{ - return SlideEventHandler::instance(); -} - -void PresentationInterface::jump(const osgPresentation::JumpData* jumpdata) -{ - SlideEventHandler* seh = SlideEventHandler::instance(); - if ((seh!=0) && (jumpdata!=0)) jumpdata->jump(seh); -} - -void PresentationInterface::sendEventToViewer(osgGA::Event* event) -{ - SlideEventHandler* seh = SlideEventHandler::instance(); - if ((seh!=0) && (event!=0)) seh->dispatchEvent(event); -} - -void PresentationInterface::sendEventToViewer(const osgPresentation::KeyPosition* kp) -{ - SlideEventHandler* seh = SlideEventHandler::instance(); - if ((seh!=0) && (kp!=0)) seh->dispatchEvent(*kp); -} - -void PresentationInterface::sendEventToDevices(osgGA::Event* event) -{ - SlideEventHandler* seh = SlideEventHandler::instance(); - if ((seh!=0) && (event!=0)) seh->forwardEventToDevices(event); -} diff --git a/src/osgPresentation/Section.cpp b/src/osgPresentation/Section.cpp deleted file mode 100644 index 04a71763c..000000000 --- a/src/osgPresentation/Section.cpp +++ /dev/null @@ -1,23 +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. -*/ - -#include - -using namespace osgPresentation; - -bool Section::getSupportedProperties(PropertyList& pl) -{ - pl.push_back(ObjectDescription(new osg::Vec4dValueObject("background_colour",osg::Vec4d(0.0,0.0,0.0,0.0)), std::string("Background colour."))); - pl.push_back(ObjectDescription(new osg::Vec4dValueObject("text_colour",osg::Vec4d(1.0,1.0,1.0,1.0)), std::string("Text colour."))); - return true; -} diff --git a/src/osgPresentation/Show.cpp b/src/osgPresentation/Show.cpp deleted file mode 100644 index ff322688b..000000000 --- a/src/osgPresentation/Show.cpp +++ /dev/null @@ -1,23 +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. -*/ - -#include - -using namespace osgPresentation; - -bool Show::getSupportedProperties(PropertyList& pl) -{ - pl.push_back(ObjectDescription(new osg::Vec4dValueObject("background_colour",osg::Vec4d(0.0,0.0,0.0,0.0)), std::string("Background colour."))); - pl.push_back(ObjectDescription(new osg::Vec4dValueObject("text_colour",osg::Vec4d(1.0,1.0,1.0,1.0)), std::string("Text colour."))); - return true; -} diff --git a/src/osgPresentation/Slide.cpp b/src/osgPresentation/Slide.cpp deleted file mode 100644 index 6d8c7f601..000000000 --- a/src/osgPresentation/Slide.cpp +++ /dev/null @@ -1,23 +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. -*/ - -#include - -using namespace osgPresentation; - -bool Slide::getSupportedProperties(PropertyList& pl) -{ - pl.push_back(ObjectDescription(new osg::Vec4dValueObject("background_colour",osg::Vec4d(0.0,0.0,0.0,0.0)), std::string("Background colour."))); - pl.push_back(ObjectDescription(new osg::Vec4dValueObject("text_colour",osg::Vec4d(1.0,1.0,1.0,1.0)), std::string("Text colour."))); - return true; -} diff --git a/src/osgPresentation/Text.cpp b/src/osgPresentation/Text.cpp deleted file mode 100644 index d2806f211..000000000 --- a/src/osgPresentation/Text.cpp +++ /dev/null @@ -1,52 +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. -*/ - -#include -#include -#include - -using namespace osgPresentation; - - -bool Text::load() -{ - OSG_NOTICE<<"Text::load() Not implemented yet"< -#include -#include -#include - -using namespace osgPresentation; - - -bool Volume::load() -{ - OSG_NOTICE<<"Volume::load() Not implemented yet"< -#include -#include -#include - -REGISTER_OBJECT_WRAPPER( osgPresentation_Audio, - new osgPresentation::Audio, - osgPresentation::Audio, - "osg::Object osg::Node osg::Group osg::Transform osg::MatrixTransform osgPresentation::Group osgPresentation::Element osgPresentation::Audio" ) -{ -} diff --git a/src/osgWrappers/serializers/osgPresentation/CMakeLists.txt b/src/osgWrappers/serializers/osgPresentation/CMakeLists.txt deleted file mode 100644 index 9f3ea6043..000000000 --- a/src/osgWrappers/serializers/osgPresentation/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -FILE(GLOB TARGET_SRC *.cpp) -FILE(GLOB TARGET_H *.h) - -SET(TARGET_ADDED_LIBRARIES osgPresentation ) - -#### end var setup ### -SETUP_PLUGIN(osgpresentation) diff --git a/src/osgWrappers/serializers/osgPresentation/Element.cpp b/src/osgWrappers/serializers/osgPresentation/Element.cpp deleted file mode 100644 index 9680029c5..000000000 --- a/src/osgWrappers/serializers/osgPresentation/Element.cpp +++ /dev/null @@ -1,11 +0,0 @@ -#include -#include -#include -#include - -REGISTER_OBJECT_WRAPPER( osgPresentation_Element, - new osgPresentation::Element, - osgPresentation::Element, - "osg::Object osg::Node osg::Group osg::Transform osg::MatrixTransform osgPresentation::Group osgPresentation::Element" ) -{ -} diff --git a/src/osgWrappers/serializers/osgPresentation/Group.cpp b/src/osgWrappers/serializers/osgPresentation/Group.cpp deleted file mode 100644 index 97056f05d..000000000 --- a/src/osgWrappers/serializers/osgPresentation/Group.cpp +++ /dev/null @@ -1,11 +0,0 @@ -#include -#include -#include -#include - -REGISTER_OBJECT_WRAPPER( osgPresentation_Group, - new osgPresentation::Group, - osgPresentation::Group, - "osg::Object osg::Node osg::Group osg::Transform osg::MatrixTransform osgPresentation::Group" ) -{ -} diff --git a/src/osgWrappers/serializers/osgPresentation/Image.cpp b/src/osgWrappers/serializers/osgPresentation/Image.cpp deleted file mode 100644 index d45bf3ccc..000000000 --- a/src/osgWrappers/serializers/osgPresentation/Image.cpp +++ /dev/null @@ -1,11 +0,0 @@ -#include -#include -#include -#include - -REGISTER_OBJECT_WRAPPER( osgPresentation_Image, - new osgPresentation::Image, - osgPresentation::Image, - "osg::Object osg::Node osg::Group osg::Transform osg::MatrixTransform osgPresentation::Group osgPresentation::Element osgPresentation::Image" ) -{ -} diff --git a/src/osgWrappers/serializers/osgPresentation/Layer.cpp b/src/osgWrappers/serializers/osgPresentation/Layer.cpp deleted file mode 100644 index 3f308b60a..000000000 --- a/src/osgWrappers/serializers/osgPresentation/Layer.cpp +++ /dev/null @@ -1,11 +0,0 @@ -#include -#include -#include -#include - -REGISTER_OBJECT_WRAPPER( osgPresentation_Layer, - new osgPresentation::Layer, - osgPresentation::Layer, - "osg::Object osg::Node osg::Group osg::Transform osg::MatrixTransform osgPresentation::Group osgPresentation::Layer" ) -{ -} diff --git a/src/osgWrappers/serializers/osgPresentation/Model.cpp b/src/osgWrappers/serializers/osgPresentation/Model.cpp deleted file mode 100644 index a328855bd..000000000 --- a/src/osgWrappers/serializers/osgPresentation/Model.cpp +++ /dev/null @@ -1,11 +0,0 @@ -#include -#include -#include -#include - -REGISTER_OBJECT_WRAPPER( osgPresentation_Model, - new osgPresentation::Model, - osgPresentation::Model, - "osg::Object osg::Node osg::Group osg::Transform osg::MatrixTransform osgPresentation::Group osgPresentation::Element osgPresentation::Model" ) -{ -} diff --git a/src/osgWrappers/serializers/osgPresentation/Movie.cpp b/src/osgWrappers/serializers/osgPresentation/Movie.cpp deleted file mode 100644 index bfec9a431..000000000 --- a/src/osgWrappers/serializers/osgPresentation/Movie.cpp +++ /dev/null @@ -1,11 +0,0 @@ -#include -#include -#include -#include - -REGISTER_OBJECT_WRAPPER( osgPresentation_Movie, - new osgPresentation::Movie, - osgPresentation::Movie, - "osg::Object osg::Node osg::Group osg::Transform osg::MatrixTransform osgPresentation::Group osgPresentation::Element osgPresentation::Movie" ) -{ -} diff --git a/src/osgWrappers/serializers/osgPresentation/Presentation.cpp b/src/osgWrappers/serializers/osgPresentation/Presentation.cpp deleted file mode 100644 index 52cfaa5cf..000000000 --- a/src/osgWrappers/serializers/osgPresentation/Presentation.cpp +++ /dev/null @@ -1,11 +0,0 @@ -#include -#include -#include -#include - -REGISTER_OBJECT_WRAPPER( osgPresentation_Presentation, - new osgPresentation::Presentation, - osgPresentation::Presentation, - "osg::Object osg::Node osg::Group osg::Transform osg::MatrixTransform osgPresentation::Group osgPresentation::Presentation" ) -{ -} diff --git a/src/osgWrappers/serializers/osgPresentation/PresentationInterface.cpp b/src/osgWrappers/serializers/osgPresentation/PresentationInterface.cpp deleted file mode 100644 index 835316d15..000000000 --- a/src/osgWrappers/serializers/osgPresentation/PresentationInterface.cpp +++ /dev/null @@ -1,87 +0,0 @@ -#include -#include -#include -#include -#include - -struct PresentationInterfaceGetSlideEventHandler : public osgDB::MethodObject -{ - virtual bool run(void* objectPtr, osg::Parameters& inputParameters, osg::Parameters& outputParameters) const - { - osgPresentation::PresentationInterface* pi = reinterpret_cast(objectPtr); - outputParameters.push_back(pi->getSlideEventHandler()); - return true; - } -}; - -struct PresentationInterfaceGetViewer : public osgDB::MethodObject -{ - virtual bool run(void* objectPtr, osg::Parameters& inputParameters, osg::Parameters& outputParameters) const - { - osgPresentation::PresentationInterface* pi = reinterpret_cast(objectPtr); - outputParameters.push_back(pi->getViewer()); - return true; - } -}; - -struct PresentationInterfaceGetPresentation : public osgDB::MethodObject -{ - virtual bool run(void* objectPtr, osg::Parameters& inputParameters, osg::Parameters& outputParameters) const - { - osgPresentation::PresentationInterface* pi = reinterpret_cast(objectPtr); - outputParameters.push_back(pi->getPresentation()); - return true; - } -}; - -struct PresentationInterfaceSendEventToViewer : public osgDB::MethodObject -{ - virtual bool run(void* objectPtr, osg::Parameters& inputParameters, osg::Parameters& outputParameters) const - { - osgPresentation::PresentationInterface* pi = reinterpret_cast(objectPtr); - if (inputParameters.empty()) return false; - - for(osg::Parameters::iterator itr = inputParameters.begin(); - itr != inputParameters.end(); - ++itr) - { - osgGA::Event* event = dynamic_cast(itr->get()); - osgPresentation::KeyPosition* kp = dynamic_cast(itr->get()); - if (kp) pi->sendEventToViewer(kp); - else if (event) pi->sendEventToViewer(event); - } - - return true; - } -}; - -struct PresentationInterfaceSendEventToDevices : public osgDB::MethodObject -{ - virtual bool run(void* objectPtr, osg::Parameters& inputParameters, osg::Parameters& outputParameters) const - { - osgPresentation::PresentationInterface* pi = reinterpret_cast(objectPtr); - if (inputParameters.empty()) return false; - - for(osg::Parameters::iterator itr = inputParameters.begin(); - itr != inputParameters.end(); - ++itr) - { - osgGA::Event* event = dynamic_cast(itr->get()); - if (event) pi->sendEventToDevices(event); - } - - return true; - } -}; - -REGISTER_OBJECT_WRAPPER( osgPresentation_PresentationInterface, - new osgPresentation::PresentationInterface, - osgPresentation::PresentationInterface, - "osg::Object osgPresentation::PresentationInterface" ) -{ - ADD_METHOD_OBJECT( "getSlideEventHandler", PresentationInterfaceGetSlideEventHandler ); - ADD_METHOD_OBJECT( "getViewer", PresentationInterfaceGetViewer ); - ADD_METHOD_OBJECT( "getPresentation", PresentationInterfaceGetPresentation ); - ADD_METHOD_OBJECT( "sendEventToViewer", PresentationInterfaceSendEventToViewer ); - ADD_METHOD_OBJECT( "sendEventToDevices", PresentationInterfaceSendEventToDevices ); -} diff --git a/src/osgWrappers/serializers/osgPresentation/Section.cpp b/src/osgWrappers/serializers/osgPresentation/Section.cpp deleted file mode 100644 index 6597c71d6..000000000 --- a/src/osgWrappers/serializers/osgPresentation/Section.cpp +++ /dev/null @@ -1,11 +0,0 @@ -#include -#include -#include -#include - -REGISTER_OBJECT_WRAPPER( osgPresentation_Section, - new osgPresentation::Section, - osgPresentation::Section, - "osg::Object osg::Node osg::Group osg::Transform osg::MatrixTransform osgPresentation::Group osgPresentation::Section" ) -{ -} diff --git a/src/osgWrappers/serializers/osgPresentation/Show.cpp b/src/osgWrappers/serializers/osgPresentation/Show.cpp deleted file mode 100644 index f110a34e5..000000000 --- a/src/osgWrappers/serializers/osgPresentation/Show.cpp +++ /dev/null @@ -1,11 +0,0 @@ -#include -#include -#include -#include - -REGISTER_OBJECT_WRAPPER( osgPresentation_Show, - new osgPresentation::Show, - osgPresentation::Show, - "osg::Object osg::Node osg::Group osg::Transform osg::MatrixTransform osgPresentation::Group osgPresentation::Show" ) -{ -} diff --git a/src/osgWrappers/serializers/osgPresentation/Slide.cpp b/src/osgWrappers/serializers/osgPresentation/Slide.cpp deleted file mode 100644 index 7aa206c80..000000000 --- a/src/osgWrappers/serializers/osgPresentation/Slide.cpp +++ /dev/null @@ -1,11 +0,0 @@ -#include -#include -#include -#include - -REGISTER_OBJECT_WRAPPER( osgPresentation_Slide, - new osgPresentation::Slide, - osgPresentation::Slide, - "osg::Object osg::Node osg::Group osg::Transform osg::MatrixTransform osgPresentation::Group osgPresentation::Slide" ) -{ -} diff --git a/src/osgWrappers/serializers/osgPresentation/Text.cpp b/src/osgWrappers/serializers/osgPresentation/Text.cpp deleted file mode 100644 index dc3057b6b..000000000 --- a/src/osgWrappers/serializers/osgPresentation/Text.cpp +++ /dev/null @@ -1,11 +0,0 @@ -#include -#include -#include -#include - -REGISTER_OBJECT_WRAPPER( osgPresentation_Text, - new osgPresentation::Text, - osgPresentation::Text, - "osg::Object osg::Node osg::Group osg::Transform osg::MatrixTransform osgPresentation::Group osgPresentation::Element osgPresentation::Text" ) -{ -} diff --git a/src/osgWrappers/serializers/osgPresentation/Volume.cpp b/src/osgWrappers/serializers/osgPresentation/Volume.cpp deleted file mode 100644 index 15343b7e8..000000000 --- a/src/osgWrappers/serializers/osgPresentation/Volume.cpp +++ /dev/null @@ -1,11 +0,0 @@ -#include -#include -#include -#include - -REGISTER_OBJECT_WRAPPER( osgPresentation_Volume, - new osgPresentation::Volume, - osgPresentation::Volume, - "osg::Object osg::Node osg::Group osg::Transform osg::MatrixTransform osgPresentation::Group osgPresentation::Element osgPresentation::Volume" ) -{ -}