Still alive, but need some help

Hi, I'm not dead, I'm still here. But I was wondering if sometbody could help me. I've been looking into the green background with pause and OpenGL. I noticed that when I take a screenshot, it comes out all black. So I think there is something broken in the screenshot code.

Am I wrong? If not, where is the screenshot code and I'll start looking at that.


I changed it not too long ago to match the version that I had also updated. Other than some basic code cleanup and sanity I made sure it worked well under Linux, which it didn't before. For Linux the read buffer is set to GL_BACK but that didn't seem to work very well under Windows so I left it as GL_FRONT with an #ifdef. Check in gropengl.cpp under gr_opengl_save_screen() for the code. Try changing it to GL_BACK for Windows and see if it helps the green screen issue but be sure and test it on another computer with different card and drivers too.

On my Windows box with a GeForce2 and the current drivers it only works right with GL_FRONT. On my Linux box with a Ti4200 and current drivers it only works with GL_BACK. I looked through MSDN some to try and explain the difference but couldn't find anything. If you figure it out I'd like to know too.

And it was GL_FRONT originally for Windows btw, I didn't change that. It's always been that way.

Well, it works in Direct 3d. Interesting results in OGL. Before Its paused the first time the tga is all black, the second is green. And all the screenshots taken after that look the same. By the by, I'm running a Radeon 9600 Pro with Cat 4.10

I do want to point out that the screenshot function is different from what's used with the pause key in a mission. gr_opengl_save_screen() is used whenever a popup comes on the window, ie. the pause key in mission, the exit yes/no prompt and the mission name popup in the simroom. gr_opengl_print_screen() is used only when you take a screenshot.

A specific read buffer isn't specified (which is kinda wrong) in gr_opengl_print_screen(), it should just use the default. Assuming that the visual is truely double-buffered then GL_BACK should be the default. If you specify GL_FRONT instead then the screenshots shouldn't come out black. Hitting pause sets it to GL_FRONT though so maybe that's why the screenshots come out green after you pause it. I recently changed the print_screen() function since it's too slow and will leave black bands in the TGA but I haven't put the code in CVS yet. If you want the changes PM or email me and I'll get them to you.

Who is online

Users browsing this forum: No registered users and 12 guests