I’ve followed nvidia’s document (http://developer.nvidia.com/docs/IO/1312/ATT/PixelBuffers.pdf) for creating a P-buffer, and get as far as ‘wglCreatePbufferARB(…)’. The “WGL_ARB_pixel_format” and “WGL_ARB_pbuffer” extensions are supported, I can get all the procedure addresses, and the ‘wglChoosePixelFormatARB’ indicates that it has 14 supporting pixel formats.
Calling ‘hBuffer = wglCreatePbufferARB(hdc, pformat, 64, 64, NULL);’ gives me a ‘Undandled exception in test.exe (NVOGLNT.DLL): … Access Violation.’
Does anyone have any suggestions as to what might be going wrong?
I’m using GLUT and attempting to create the p-buffer immediately before the ‘glutMainLoop’ and after initialising GLUT and creating a window (so I have a valid wglGetCurrentDC()).
The attributes I’m requesting in the ‘wglChoosePixelFormatARB’ function’s int attributes array are -