1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101
|
/*
# BUILD api_versions [0x109]
*/
%module texture_filter4
%{
/**
*
* GL.SGIS.texture_filter4 Module for PyOpenGL
*
* Date: May 2001
*
* Authors: Tarn Weisner Burton <twburton@users.sourceforge.net>
*
***/
%}
#define __version__ "$Revision: 1.18 $"
#define __date__ "$Date: 2001/10/05 17:39:12 $"
#define __api_version__ API_VERSION
#define __author__ "Tarn Weisner Burton <twburton@users.sourceforge.net>"
#define __doc__ "http:\057\057oss.sgi.com\057projects\057ogl-sample\057registry\057SGIS\057texture_filter4.txt"
%include util.inc
/* turn the exception handler on */
GL_EXCEPTION_HANDLER()
%{
#if !EXT_DEFINES_PROTO || !defined(GL_SGIS_texture_filter4)
DECLARE_VOID_EXT(glTexFilterFuncSGIS, (GLenum target, GLenum filter, GLsizei n, const GLfloat* points), (target, filter, n, points))
DECLARE_VOID_EXT(glGetTexFilterFuncSGIS, (GLenum target, GLenum filter, GLfloat* points), (target, filter, points))
#endif
static char *proc_names[] =
{
#if !EXT_DEFINES_PROTO || !defined(GL_SGIS_texture_filter4)
"glTexFilterFuncSGIS",
"glGetTexFilterFuncSGIS",
#endif
NULL
};
#define glInitTextureFilter4SGIS() InitExtension("GL_SGIS_texture_filter4", proc_names)
%}
int glInitTextureFilter4SGIS();
DOC(glInitTextureFilter4SGIS, "glInitTextureFilter4SGIS() -> bool")
%name(glInitTexFilter4SGIS) int glInitTextureFilter4SGIS();
DOC(glInitTexFilter4SGIS, "glInitTexFilter4SGIS() -> bool")
void glTexFilterFuncSGIS(GLenum target, GLenum filter, GLsizei n_3, const GLfloat* points);
DOC(glTexFilterFuncSGIS, "glTexFilterFuncSGIS(target, filter, points) -> None")
%{
#ifndef GL_TEXTURE_FILTER4_SIZE_SGIS
#define GL_TEXTURE_FILTER4_SIZE_SGIS 0x8147
#endif
PyObject* _glGetTexFilterFuncSGIS(GLenum target, GLenum filter)
{
GLsizei n = 0;
GLfloat *points;
PyObject *result;
glGetTexParameteriv(target, GL_TEXTURE_FILTER4_SIZE_SGIS, &n);
points = PyMem_New(GLfloat, n);
glGetTexFilterFuncSGIS(target, filter, points);
result = _PyTuple_FromFloatArray(n, points);
PyMem_Del(points);
return result;
}
%}
%name(glGetTexFilterFuncSGIS) PyObject* _glGetTexFilterFuncSGIS(GLenum target, GLenum filter);
DOC(glGetTexFilterFuncSGIS, "glGetTexFilterFuncSGIS(target) -> points")
%{
PyObject *__info()
{
if (glInitTextureFilter4SGIS())
{
PyObject *info = PyList_New(0);
return info;
}
Py_INCREF(Py_None);
return Py_None;
}
%}
PyObject *__info();
#define GL_FILTER4_SGIS 0x8146
#define GL_TEXTURE_FILTER4_SIZE_SGIS 0x8147
|