| |
- BasePlatform(object)
-
- GLXPlatform
class GLXPlatform(BasePlatform) |
|
Posix (Linux, FreeBSD, etceteras) implementation for PyOpenGL |
|
- Method resolution order:
- GLXPlatform
- BasePlatform
- object
Methods defined here:
- getGLUTFontPointer(self, constant)
- Platform specific function to retrieve a GLUT font pointer
GLUTAPI void *glutBitmap9By15;
#define GLUT_BITMAP_9_BY_15 (&glutBitmap9By15)
Key here is that we want the addressof the pointer in the DLL,
not the pointer in the DLL. That is, our pointer is to the
pointer defined in the DLL, we don't want the *value* stored in
that pointer.
Static methods defined here:
- CurrentContextIsValid = glXGetCurrentContext(...)
- DEFAULT_FUNCTION_TYPE = CFUNCTYPE(restype, *argtypes)
- CFUNCTYPE(restype, *argtypes) -> function prototype.
restype: the result type
argtypes: a sequence specifying the argument types
The function prototype can be called in different ways to create a
callable object:
prototype(integer address) -> foreign function
prototype(callable) -> create and return a C callable function from callable
prototype(integer index, method name[, paramflags]) -> foreign function calling a COM method
prototype((ordinal number, dll object)[, paramflags]) -> foreign function exported by ordinal
prototype((function name, dll object)[, paramflags]) -> foreign function exported by name
- GetCurrentContext = glXGetCurrentContext(...)
- getExtensionProcedure = glXGetProcAddressARB(...)
- safeGetError = glGetError(...)
Data and other attributes defined here:
- GL = <CDLL 'libGL.so.1', handle 8268148 at 823ee2c>
- GLE = <CDLL 'libgle.so.3', handle 826b078 at 823ec6c>
- GLU = <CDLL 'libGLU.so.1', handle 826a4b8 at 823edcc>
- GLUT = <CDLL 'libglut.so.3', handle 826ae08 at 823eb8c>
- GLX = <CDLL 'libGL.so.1', handle 8268148 at 823ee2c>
- OpenGL = <CDLL 'libGL.so.1', handle 8268148 at 823ee2c>
- glXGetProcAddressARB = <_FuncPtr object at 0x8352dfc>
Methods inherited from BasePlatform:
- copyBaseFunction(self, original)
- Create a new base function based on an already-created function
This is normally used to provide type-specific convenience versions of
a definition created by the automated generator.
- createBaseFunction(self, functionName, dll, resultType=<class 'ctypes.c_long'>, argTypes=(), doc=None, argNames=())
- Create a base function for given name
Normally you can just use the dll.name hook to get the object,
but we want to be able to create different bindings for the
same function, so we do the work manually here to produce a
base function from a DLL.
- createExtensionFunction(self, functionName, dll, resultType=<class 'ctypes.c_long'>, argTypes=(), doc=None, argNames=())
- Create an extension function for the given name
Uses the platform's getExtensionProcedure function to retrieve
a c_void_p to the function, then wraps in a platform FunctionType
instance with all the funky code we've come to love.
- errorChecking(self, func)
- Add error checking to the function if appropriate
- functionTypeFor(self, dll)
- Given a DLL, determine appropriate function type...
- install(self, namespace)
- Install this platform instance into the platform module
- nullFunction(self, functionName, dll, resultType=<class 'ctypes.c_long'>, argTypes=(), doc=None, argNames=(), extension=True)
- Construct a "null" function pointer
- wrapLogging(self, func)
- Wrap function with logging operations if appropriate
Data descriptors inherited from BasePlatform:
- __dict__
- dictionary for instance variables (if defined)
- __weakref__
- list of weak references to the object (if defined)
Data and other attributes inherited from BasePlatform:
- EXPORTED_NAMES = ['GetCurrentContext', 'CurrentContextIsValid', 'safeGetError', 'createBaseFunction', 'createExtensionFunction', 'copyBaseFunction', 'GL', 'GLU', 'GLUT', 'GLE', 'OpenGL', 'getGLUTFontPointer', 'GLUT_GUARD_CALLBACKS']
- EXTENSIONS_USE_BASE_FUNCTIONS = False
- GLUT_GUARD_CALLBACKS = False
| |