Updated wrappers

This commit is contained in:
Robert Osfield
2007-06-03 10:00:09 +00:00
parent b5791629ea
commit 30e4eb833f
3 changed files with 71 additions and 2 deletions

View File

@@ -51,7 +51,7 @@ class OSGVIEWER_EXPORT Viewer : public osgViewer::View
virtual void setSceneData(osg::Node* node);
/** Convinience method for setting up the viewer so it can be used embedded in an external managed window.
/** Convenience method for setting up the viewer so it can be used embedded in an external managed window.
* Returns the GraphicsWindowEmbedded that can be used by applications to pass in events to the viewer. */
virtual GraphicsWindowEmbedded* setUpViewerAsEmbeddedInWindow(int x, int y, int width, int height);

View File

@@ -184,3 +184,66 @@ BEGIN_OBJECT_REFLECTOR(osgViewer::GraphicsWindow)
__void__setWindowDecoration__bool);
END_REFLECTOR
BEGIN_OBJECT_REFLECTOR(osgViewer::GraphicsWindowEmbedded)
I_BaseType(osgViewer::GraphicsWindow);
I_ConstructorWithDefaults1(IN, osg::GraphicsContext::Traits *, traits, 0,
Properties::NON_EXPLICIT,
____GraphicsWindowEmbedded__osg_GraphicsContext_Traits_P1,
"",
"");
I_Constructor4(IN, int, x, IN, int, y, IN, int, width, IN, int, height,
____GraphicsWindowEmbedded__int__int__int__int,
"",
"");
I_Method0(void, init,
Properties::NON_VIRTUAL,
__void__init,
"",
"");
I_Method0(bool, valid,
Properties::VIRTUAL,
__bool__valid,
"Return whether a valid and usable GraphicsContext has been created. ",
"");
I_Method0(bool, realizeImplementation,
Properties::VIRTUAL,
__bool__realizeImplementation,
"Realise the GraphicsContext implementation, Pure virtual - must be implemented by concrate implementations of GraphicsContext. ",
"");
I_Method0(bool, isRealizedImplementation,
Properties::VIRTUAL,
__bool__isRealizedImplementation,
"Return true if the graphics context has been realised, and is ready to use, implementation. ",
"Pure virtual - must be implemented by concrate implementations of GraphicsContext. ");
I_Method0(void, closeImplementation,
Properties::VIRTUAL,
__void__closeImplementation,
"Close the graphics context implementation. ",
"Pure virtual - must be implemented by concrate implementations of GraphicsContext. ");
I_Method0(bool, makeCurrentImplementation,
Properties::VIRTUAL,
__bool__makeCurrentImplementation,
"Make this graphics context current implementation. ",
"Pure virtual - must be implemented by concrate implementations of GraphicsContext. ");
I_Method0(bool, releaseContextImplementation,
Properties::VIRTUAL,
__bool__releaseContextImplementation,
"Release the graphics context. ",
"");
I_Method0(void, swapBuffersImplementation,
Properties::VIRTUAL,
__void__swapBuffersImplementation,
"Swap the front and back buffers implementation. ",
"Pure virtual - must be implemented by Concrate implementations of GraphicsContext. ");
I_Method0(void, grabFocus,
Properties::VIRTUAL,
__void__grabFocus,
"Get focus. ",
"");
I_Method0(void, grabFocusIfPointerInWindow,
Properties::VIRTUAL,
__void__grabFocusIfPointerInWindow,
"Get focus on if the pointer is in this window. ",
"");
END_REFLECTOR

View File

@@ -16,6 +16,7 @@
#include <osg/GraphicsThread>
#include <osg/Node>
#include <osg/Timer>
#include <osgViewer/GraphicsWindow>
#include <osgViewer/Viewer>
// Must undefine IN and OUT macros defined in Windows headers
@@ -102,8 +103,13 @@ BEGIN_OBJECT_REFLECTOR(osgViewer::Viewer)
I_Method1(void, setSceneData, IN, osg::Node *, node,
Properties::VIRTUAL,
__void__setSceneData__osg_Node_P1,
"",
"Set the sene graph data that viewer with view. ",
"");
I_Method4(osgViewer::GraphicsWindowEmbedded *, setUpViewerAsEmbeddedInWindow, IN, int, x, IN, int, y, IN, int, width, IN, int, height,
Properties::VIRTUAL,
__GraphicsWindowEmbedded_P1__setUpViewerAsEmbeddedInWindow__int__int__int__int,
"Convinience method for setting up the viewer so it can be used embedded in an external managed window. ",
"Returns the GraphicsWindowEmbedded that can be used by applications to pass in events to the viewer. ");
I_Method1(void, setThreadingModel, IN, osgViewer::Viewer::ThreadingModel, threadingModel,
Properties::NON_VIRTUAL,
__void__setThreadingModel__ThreadingModel,