(Development environment is Linux Mint with beta driver 349.12; GPU is a GTX 760).
Having some trouble using the new NV_command_list extension. I’ve got a draw function that looks a bit like this:
glBindFramebuffer(GL_READ_FRAMEBUFFER, 0);
glBindFramebuffer(GL_DRAW_FRAMEBUFFER, fbo);
// clear:
glClearColor(1, 0, 0, 0);
glClearDepth(1.0);
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
// draw:
glDrawCommandsStatesAddressNV(…);
// blit:
glBindFramebuffer(GL_READ_FRAMEBUFFER, fbo);
glBindFramebuffer(GL_DRAW_FRAMEBUFFER, 0);
glBlitFramebuffer(0, 0, width, height,
0, 0, width, height, GL_COLOR_BUFFER_BIT, GL_NEAREST);
Having trouble getting it to do much. I can’t get the commands for the geometry that I want to draw anything but a blank frame, but even if I fill a command buffer with a single NOP command, then I see the screen clear to red for the first frame, and all subsequent frames are black (same thing happens with the ‘real’ commands I want to try, or commands that just set the uniform buffer addresses but without any draw commands). I’d expected that with a single NOP command, the glDraw() command would ‘do nothing’ and I’d always see the frame cleared to red, but that seems to only happen for the first frame only.
I’ve tried removing the glDrawCommands and things work as they should - every frame is cleared to red, so the clear and blit seems to be working.
Anyone know what might be going on? Does a command buffer always need an actual draw command or a terminate or something somewhere in it? I am only trying to use the glDrawCommandsStatesAddressNV() and not the compiled command lists (which really wouldn’t be appropriate for this application). I have added debugging callbacks with glDebugMessageCallback but that doesn’t tell my I’m doing anything wrong (it does tell me things about the buffers I’ve created for storing geometry, I and I can do incorrect things deliberately, like not setting a framebuffer when capturing the state, and the debug extension reports errors). The gl_commandlist_* samples posted on github do work for me. I’m using SDL as the windowing environment.
– Alex