PDA

View Full Version : Compute shader usage without opening a window



bug343
05-24-2013, 06:09 PM
Is it possible to use the compute shader without creating a window when using GLUT and GLEW? My understanding is you have to create a window using GLUT and only then can you initialize GLEW.

tonyo_au
05-24-2013, 09:29 PM
You need a device context for OpenGL to work since it is for rendering - so no. If you want a "compute shader" without a window use OpenCL that is what it is for.

Alfonse Reinheart
05-25-2013, 06:00 AM
Note that once you have created an OpenGL context, it is possible to create a windowless context from it with WGL/GLX_pbuffer. Then you can delete the original context and just use your windowless pbuffer context.