Create and return a pycuda.driver.Context that has GL interoperability enabled.
Warning
This will fail with a rather unhelpful error message if you don’t already have a GL context created and active.
Usage of OpenGL object from CUDA.
Read and write access to mapped OpenGL object from CUDA code.
Read only access to mapped OpenGL object from CUDA code.
Write only access to mapped OpenGL object from CUDA code. Reading is prohibited.
Object managing mapping of OpenGL buffers to CUDA. Cannot be used to map images.
Return a RegisteredMapping.
Object managing mapping of OpenGL textures and render buffers to CUDA.
target must be be one of:
- GL_TEXTURE_2D
- GL_TEXTURE_RECTANGLE
- GL_TEXTURE_CUBE_MAP
- GL_TEXTURE_3D
- GL_TEXTURE_2D_ARRAY
- GL_RENDERBUFFER
(see PyOpenGL docs)
Return a RegisteredMapping.
If no stream is specified, the unmap will use the same stream as the original mapping.
Return a tuple (dev_pointer, size).
Return an array for mapped image object for given array index and MIP level.
Warning
Importing pycuda.gl.autoinit will fail with a rather unhelpful error message if you don’t already have a GL context created and active.
Enable GL interoperability for the already-created (so far non-GL) and currently active pycuda.driver.Context.
According to the forum post referenced in the note below, this will succeed on Windows XP and Linux, but it will not work on Windows Vista. There you have to create the GL-enabled context using make_context().
Warning
This function is deprecated since CUDA 3.0 and PyCUDA 2011.1.
Warning
This will fail with a rather unhelpful error message if you don’t already have a GL context created and active.
Note
See this post on the Nvidia forums for a discussion of problems and solutions with the GL interop interface.