Updated wrappers and supported shadow texture formats

This commit is contained in:
Robert Osfield 2010-01-13 18:50:17 +00:00
parent 8541761fe7
commit 327406df69
2 changed files with 21 additions and 5 deletions

View File

@ -491,8 +491,14 @@ const char* Texture_getSourceTypeStr(int value)
bool Texture_matchShadowCompareFuncStr(const char* str, Texture::ShadowCompareFunc& value)
{
if ( strcmp(str,"GL_LEQUAL")==0) value = Texture::LEQUAL;
if ( strcmp(str,"GL_NEVER")==0) value = Texture::NEVER;
else if (strcmp(str,"GL_LESS")==0) value = Texture::LESS;
else if (strcmp(str,"GL_EQUAL")==0) value = Texture::EQUAL;
else if (strcmp(str,"GL_LEQUAL")==0) value = Texture::LEQUAL;
else if (strcmp(str,"GL_GREATER")==0) value = Texture::GREATER;
else if (strcmp(str,"GL_NOTEQUAL")==0) value = Texture::NOTEQUAL;
else if (strcmp(str,"GL_GEQUAL")==0) value = Texture::GEQUAL;
else if (strcmp(str,"GL_ALWAYS")==0) value = Texture::ALWAYS;
else return false;
return true;
@ -502,8 +508,14 @@ const char* Texture_getShadowCompareFuncStr(Texture::ShadowCompareFunc value)
{
switch(value)
{
case(Texture::NEVER): return "GL_NEVER";
case(Texture::LESS): return "GL_LESS";
case(Texture::EQUAL): return "GL_EQUAL";
case(Texture::LEQUAL): return "GL_LEQUAL";
case(Texture::GREATER): return "GL_GREATER";
case(Texture::NOTEQUAL): return "GL_NOTEQUAL";
case(Texture::GEQUAL): return "GL_GEQUAL";
case(Texture::ALWAYS): return "GL_ALWAYS";
}
return NULL;
}

View File

@ -254,6 +254,10 @@ BEGIN_ABSTRACT_OBJECT_REFLECTOR(osg::BufferObject)
__unsigned_int__computeRequiredBufferSize,
"",
"");
I_StaticMethod2(void, deleteBufferObject, IN, unsigned int, contextID, IN, GLuint, globj,
__void__deleteBufferObject__unsigned_int__GLuint_S,
"deprecated, provided for backwards compatibility. ",
"");
I_ArrayProperty(osg::BufferData *, BufferData,
__BufferData_P1__getBufferData__unsigned_int,
__void__setBufferData__unsigned_int__BufferData_P1,
@ -369,8 +373,8 @@ END_REFLECTOR
BEGIN_OBJECT_REFLECTOR(osg::GLBufferObject)
I_DeclaringFile("osg/BufferObject");
I_BaseType(osg::Referenced);
I_ConstructorWithDefaults2(IN, unsigned int, contextID, , IN, osg::BufferObject *, bufferObject, 0,
____GLBufferObject__unsigned_int__BufferObject_P1,
I_ConstructorWithDefaults3(IN, unsigned int, contextID, , IN, osg::BufferObject *, bufferObject, , IN, unsigned int, glObjectID, 0,
____GLBufferObject__unsigned_int__BufferObject_P1__unsigned_int,
"",
"");
I_Method1(void, setProfile, IN, const osg::BufferObjectProfile &, profile,