From 6fda4a927acc4b254d24b05a6251abd13feb5f67 Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Mon, 15 Jan 2007 16:12:34 +0000 Subject: [PATCH] Updated wrappers --- src/osgWrappers/osgViewer/Scene.cpp | 10 ++++++- src/osgWrappers/osgViewer/View.cpp | 5 ++++ src/osgWrappers/osgViewer/Viewer.cpp | 45 +++++++++++++++++++++++++++- 3 files changed, 58 insertions(+), 2 deletions(-) diff --git a/src/osgWrappers/osgViewer/Scene.cpp b/src/osgWrappers/osgViewer/Scene.cpp index 471601e23..fa2ab976d 100644 --- a/src/osgWrappers/osgViewer/Scene.cpp +++ b/src/osgWrappers/osgViewer/Scene.cpp @@ -40,10 +40,18 @@ BEGIN_OBJECT_REFLECTOR(osgViewer::Scene) __C5_osg_Node_P1__getSceneData, "", ""); + I_Method1(void, setFrameStamp, IN, osg::FrameStamp *, frameStamp, + __void__setFrameStamp__osg_FrameStamp_P1, + "", + ""); I_Method0(osg::FrameStamp *, getFrameStamp, __osg_FrameStamp_P1__getFrameStamp, "", ""); + I_Method0(const osg::FrameStamp *, getFrameStamp, + __C5_osg_FrameStamp_P1__getFrameStamp, + "", + ""); I_Method1(void, setDatabasePager, IN, osgDB::DatabasePager *, dp, __void__setDatabasePager__osgDB_DatabasePager_P1, "", @@ -73,7 +81,7 @@ BEGIN_OBJECT_REFLECTOR(osgViewer::Scene) __void__setDatabasePager__osgDB_DatabasePager_P1); I_SimpleProperty(osg::FrameStamp *, FrameStamp, __osg_FrameStamp_P1__getFrameStamp, - 0); + __void__setFrameStamp__osg_FrameStamp_P1); I_SimpleProperty(osg::Node *, SceneData, __osg_Node_P1__getSceneData, __void__setSceneData__osg_Node_P1); diff --git a/src/osgWrappers/osgViewer/View.cpp b/src/osgWrappers/osgViewer/View.cpp index 824a25603..7ec0ba5a1 100644 --- a/src/osgWrappers/osgViewer/View.cpp +++ b/src/osgWrappers/osgViewer/View.cpp @@ -10,6 +10,7 @@ #include #include +#include #include #include #include @@ -102,6 +103,10 @@ BEGIN_OBJECT_REFLECTOR(osgViewer::View) __void__setUpViewOnSingleScreen__unsigned_int, "Convinience method for a single Camara associated with a single full screen GraphicsWindow. ", ""); + I_Method4(const osg::Camera *, getCameraContainingPosition, IN, float, x, IN, float, y, IN, float &, local_x, IN, float &, local_y, + __C5_osg_Camera_P1__getCameraContainingPosition__float__float__float_R1__float_R1, + "Get the camera which contains the pointer position x,y specified master cameras window/eye coords. ", + "Also passes back the local window coords for the graphics context associated with the camera passed back. "); I_MethodWithDefaults4(bool, computeIntersections, IN, float, x, , IN, float, y, , IN, osgUtil::LineSegmentIntersector::Intersections &, intersections, , IN, osg::Node::NodeMask, traversalMask, 0xffffffff, __bool__computeIntersections__float__float__osgUtil_LineSegmentIntersector_Intersections_R1__osg_Node_NodeMask, "Compute intersections between a ray through the specified master cameras window/eye coords and a specified node. ", diff --git a/src/osgWrappers/osgViewer/Viewer.cpp b/src/osgWrappers/osgViewer/Viewer.cpp index b2e349a84..d0ceedcf6 100644 --- a/src/osgWrappers/osgViewer/Viewer.cpp +++ b/src/osgWrappers/osgViewer/Viewer.cpp @@ -12,6 +12,8 @@ #include #include +#include +#include #include // Must undefine IN and OUT macros defined in Windows headers @@ -58,6 +60,22 @@ BEGIN_OBJECT_REFLECTOR(osgViewer::Viewer) __bool__done, "", ""); + I_Method1(void, setStartTick, IN, osg::Timer_t, tick, + __void__setStartTick__osg_Timer_t, + "", + ""); + I_Method0(osg::Timer_t, getStartTick, + __osg_Timer_t__getStartTick, + "", + ""); + I_MethodWithDefaults1(void, setReferenceTime, IN, double, time, 0.0, + __void__setReferenceTime__double, + "", + ""); + I_Method1(void, setFrameStamp, IN, osg::FrameStamp *, frameStamp, + __void__setFrameStamp__osg_FrameStamp_P1, + "", + ""); I_Method0(osg::FrameStamp *, getFrameStamp, __osg_FrameStamp_P1__getFrameStamp, "", @@ -66,6 +84,10 @@ BEGIN_OBJECT_REFLECTOR(osgViewer::Viewer) __C5_osg_FrameStamp_P1__getFrameStamp, "", ""); + I_Method1(void, setSceneData, IN, osg::Node *, node, + __void__setSceneData__osg_Node_P1, + "", + ""); I_Method1(void, setThreadingModel, IN, osgViewer::Viewer::ThreadingModel, threadingModel, __void__setThreadingModel__ThreadingModel, "Set the threading model the rendering traversals will use. ", @@ -150,6 +172,18 @@ BEGIN_OBJECT_REFLECTOR(osgViewer::Viewer) __void__getWindows__Windows_R1__bool, "", ""); + I_Method0(void, stopThreading, + __void__stopThreading, + "", + ""); + I_Method0(void, startThreading, + __void__startThreading, + "", + ""); + I_Method0(void, setUpRenderingSupport, + __void__setUpRenderingSupport, + "", + ""); I_SimpleProperty(osg::Camera *, CameraWithFocus, __osg_Camera_P1__getCameraWithFocus, __void__setCameraWithFocus__osg_Camera_P1); @@ -161,13 +195,22 @@ BEGIN_OBJECT_REFLECTOR(osgViewer::Viewer) __void__setEndBarrierPosition__BarrierPosition); I_SimpleProperty(osg::FrameStamp *, FrameStamp, __osg_FrameStamp_P1__getFrameStamp, - 0); + __void__setFrameStamp__osg_FrameStamp_P1); I_SimpleProperty(int, KeyEventSetsDone, __int__getKeyEventSetsDone, __void__setKeyEventSetsDone__int); I_SimpleProperty(bool, QuitEventSetsDone, __bool__getQuitEventSetsDone, __void__setQuitEventSetsDone__bool); + I_SimpleProperty(double, ReferenceTime, + 0, + __void__setReferenceTime__double); + I_SimpleProperty(osg::Node *, SceneData, + 0, + __void__setSceneData__osg_Node_P1); + I_SimpleProperty(osg::Timer_t, StartTick, + __osg_Timer_t__getStartTick, + __void__setStartTick__osg_Timer_t); I_SimpleProperty(osgViewer::Viewer::ThreadingModel, ThreadingModel, __ThreadingModel__getThreadingModel, __void__setThreadingModel__ThreadingModel);