diff --git a/src/osgWrappers/osg/StateAttribute.cpp b/src/osgWrappers/osg/StateAttribute.cpp index 5404f3d74..7e2f0a803 100644 --- a/src/osgWrappers/osg/StateAttribute.cpp +++ b/src/osgWrappers/osg/StateAttribute.cpp @@ -16,6 +16,7 @@ #include #include #include +#include // Must undefine IN and OUT macros defined in Windows headers #ifdef IN @@ -131,6 +132,16 @@ BEGIN_ABSTRACT_OBJECT_REFLECTOR(osg::StateAttribute) __C5_char_P1__className, "Return the name of the attribute's class type. ", ""); + I_Method0(osg::Texture *, asTexture, + Properties::VIRTUAL, + __Texture_P1__asTexture, + "Fast alternative to dynamic_cast<> for determining if state attribute is a Texture. ", + ""); + I_Method0(const osg::Texture *, asTexture, + Properties::VIRTUAL, + __C5_Texture_P1__asTexture, + "Fast alternative to dynamic_cast<> for determining if state attribute is a Texture. ", + ""); I_Method0(osg::StateAttribute::Type, getType, Properties::PURE_VIRTUAL, __Type__getType, diff --git a/src/osgWrappers/osg/Texture.cpp b/src/osgWrappers/osg/Texture.cpp index c2d0fb0b3..1f15bcd1c 100644 --- a/src/osgWrappers/osg/Texture.cpp +++ b/src/osgWrappers/osg/Texture.cpp @@ -136,6 +136,16 @@ BEGIN_ABSTRACT_OBJECT_REFLECTOR(osg::Texture) __C5_char_P1__className, "Return the name of the attribute's class type. ", ""); + I_Method0(osg::Texture *, asTexture, + Properties::VIRTUAL, + __Texture_P1__asTexture, + "Fast alternative to dynamic_cast<> for determining if state attribute is a Texture. ", + ""); + I_Method0(const osg::Texture *, asTexture, + Properties::VIRTUAL, + __C5_Texture_P1__asTexture, + "Fast alternative to dynamic_cast<> for determining if state attribute is a Texture. ", + ""); I_Method0(osg::StateAttribute::Type, getType, Properties::VIRTUAL, __Type__getType,