Moved SimpleViewer and GraphicsWindow into their own osgViewer library, updated simpleviewer examples to reflect this change
This commit is contained in:
@@ -14,7 +14,6 @@ CXXFILES = \
|
||||
GUIEventHandler.cpp\
|
||||
KeySwitchMatrixManipulator.cpp\
|
||||
StateSetManipulator.cpp\
|
||||
SimpleViewer.cpp\
|
||||
TerrainManipulator.cpp\
|
||||
NodeTrackerManipulator.cpp\
|
||||
TrackballManipulator.cpp\
|
||||
@@ -22,7 +21,7 @@ CXXFILES = \
|
||||
|
||||
DEF += -DOSGGA_LIBRARY
|
||||
|
||||
LIBS += -losgDB -losgUtil -losg $(GL_LIBS) $(OTHER_LIBS)
|
||||
LIBS += -losgUtil -losg $(GL_LIBS) $(OTHER_LIBS)
|
||||
|
||||
TARGET_BASENAME = osgGA
|
||||
LIB = $(LIB_PREFIX)$(TARGET_BASENAME).$(LIB_EXT)
|
||||
|
||||
16
src/osgViewer/GNUmakefile
Normal file
16
src/osgViewer/GNUmakefile
Normal file
@@ -0,0 +1,16 @@
|
||||
TOPDIR = ../..
|
||||
include $(TOPDIR)/Make/makedefs
|
||||
|
||||
|
||||
CXXFILES = \
|
||||
SimpleViewer.cpp\
|
||||
Version.cpp\
|
||||
|
||||
DEF += -DOSGVIEWER_LIBRARY
|
||||
|
||||
LIBS += -losgGA -losgDB -losgUtil -losg $(GL_LIBS) $(OTHER_LIBS)
|
||||
|
||||
TARGET_BASENAME = osgViewer
|
||||
LIB = $(LIB_PREFIX)$(TARGET_BASENAME).$(LIB_EXT)
|
||||
|
||||
include $(TOPDIR)/Make/makerules
|
||||
@@ -11,10 +11,9 @@
|
||||
* OpenSceneGraph Public License for more details.
|
||||
*/
|
||||
|
||||
#include <osgGA/SimpleViewer>
|
||||
#include <osgGA/TrackballManipulator>
|
||||
#include <osgViewer/SimpleViewer>
|
||||
|
||||
using namespace osgGA;
|
||||
using namespace osgViewer;
|
||||
|
||||
SimpleViewer::SimpleViewer():
|
||||
_firstFrame(true)
|
||||
@@ -80,7 +79,7 @@ const osg::CameraNode* SimpleViewer::getCamera() const
|
||||
return _sceneView->getCamera();
|
||||
}
|
||||
|
||||
void SimpleViewer::setCameraManipulator(MatrixManipulator* manipulator)
|
||||
void SimpleViewer::setCameraManipulator(osgGA::MatrixManipulator* manipulator)
|
||||
{
|
||||
if (_cameraManipulator == manipulator) return;
|
||||
|
||||
@@ -94,7 +93,7 @@ void SimpleViewer::setCameraManipulator(MatrixManipulator* manipulator)
|
||||
}
|
||||
}
|
||||
|
||||
void SimpleViewer::addEventHandler(GUIEventHandler* eventHandler)
|
||||
void SimpleViewer::addEventHandler(osgGA::GUIEventHandler* eventHandler)
|
||||
{
|
||||
_eventHandlers.push_back(eventHandler);
|
||||
}
|
||||
12
src/osgViewer/Version.cpp
Normal file
12
src/osgViewer/Version.cpp
Normal file
@@ -0,0 +1,12 @@
|
||||
#include <osgGA/Version>
|
||||
|
||||
const char* osgGAGetVersion()
|
||||
{
|
||||
return "1.2";
|
||||
}
|
||||
|
||||
|
||||
const char* osgGAGetLibraryName()
|
||||
{
|
||||
return "OpenSceneGraph Gui Adapter Library";
|
||||
}
|
||||
Reference in New Issue
Block a user