From 76063a94bd504b9f03af012a480f3a43edd4b05c Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Fri, 31 Aug 2007 20:21:45 +0000 Subject: [PATCH] Updated wrappers --- src/osgWrappers/osg/Referenced.cpp | 9 +++++++++ src/osgWrappers/osgText/Font.cpp | 10 ++++++++++ 2 files changed, 19 insertions(+) diff --git a/src/osgWrappers/osg/Referenced.cpp b/src/osgWrappers/osg/Referenced.cpp index bfd339126..9ed646cb1 100644 --- a/src/osgWrappers/osg/Referenced.cpp +++ b/src/osgWrappers/osg/Referenced.cpp @@ -10,6 +10,7 @@ #include #include +#include #include #include #include @@ -47,6 +48,11 @@ BEGIN_OBJECT_REFLECTOR(osg::Referenced) __bool__getThreadSafeRefUnref, "Get whether a mutex is used to ensure ref() and unref() are thread safe. ", ""); + I_Method0(OpenThreads::Mutex *, getRefMutex, + Properties::NON_VIRTUAL, + __OpenThreads_Mutex_P1__getRefMutex, + "Get the mutex used to ensure thread safety of ref()/unref(). ", + ""); I_Method0(void, ref, Properties::NON_VIRTUAL, __void__ref, @@ -99,6 +105,9 @@ BEGIN_OBJECT_REFLECTOR(osg::Referenced) __void__deleteUsingDeleteHandler, "", ""); + I_SimpleProperty(OpenThreads::Mutex *, RefMutex, + __OpenThreads_Mutex_P1__getRefMutex, + 0); I_SimpleProperty(bool, ThreadSafeRefUnref, __bool__getThreadSafeRefUnref, __void__setThreadSafeRefUnref__bool); diff --git a/src/osgWrappers/osgText/Font.cpp b/src/osgWrappers/osgText/Font.cpp index 827278369..126102ab5 100644 --- a/src/osgWrappers/osgText/Font.cpp +++ b/src/osgWrappers/osgText/Font.cpp @@ -28,6 +28,8 @@ #undef OUT #endif +TYPE_NAME_ALIAS(OpenThreads::Mutex, osgText::Font::FontMutex) + BEGIN_OBJECT_REFLECTOR(osgText::Font) I_DeclaringFile("osgText/Font"); I_BaseType(osg::Object); @@ -211,6 +213,11 @@ BEGIN_OBJECT_REFLECTOR(osgText::Font) __void__releaseGLObjects__osg_State_P1, "If State is non-zero, this function releases OpenGL objects for the specified graphics context. ", "Otherwise, releases OpenGL objexts for all graphics contexts. "); + I_Method0(osgText::Font::FontMutex &, getSerializeFontCallsMutex, + Properties::NON_VIRTUAL, + __FontMutex_R1__getSerializeFontCallsMutex, + "Get the mutex that enables the serialization of calls to this font. ", + ""); I_ProtectedMethod4(void, addGlyph, IN, unsigned int, width, IN, unsigned int, height, IN, unsigned int, charcode, IN, osgText::Font::Glyph *, glyph, Properties::NON_VIRTUAL, Properties::NON_CONST, @@ -241,6 +248,9 @@ BEGIN_OBJECT_REFLECTOR(osgText::Font) I_SimpleProperty(osg::Texture::FilterMode, MinFilterHint, __osg_Texture_FilterMode__getMinFilterHint, __void__setMinFilterHint__osg_Texture_FilterMode); + I_SimpleProperty(osgText::Font::FontMutex &, SerializeFontCallsMutex, + __FontMutex_R1__getSerializeFontCallsMutex, + 0); I_SimpleProperty(osg::StateSet *, StateSet, __osg_StateSet_P1__getStateSet, __void__setStateSet__osg_StateSet_P1);