aux0

Just had a question about aux0 buffer on my mac. When I look at the ati driver with one of Apple’s utility programs it says I have 2 auxiliary buffers. Yet, in glut, there seems to be no way to get a window with these auxiliary buffers. In glut, if I do a glGet it reports no aux buffers available.

My intention is to use aux0 and glCopyPixels rather than glDrawPixels. Well, glDrawPixels to get the stuff on the card first. So, use AUX0 as a cache such that the program avoids having to copy from processor memory.

glDrawPixels is problematic. There is the accumulation buffer but that would seem like a odd use for it . Apple’s profiler tool shows 30% of opengl time is spent in the glDrawPixels. So, big frame rate hit. Combining images into one image seems to help but that is not the real solution.

Any hints/clues on how to get aux0 going? radeon 9800…new hardware.

Thanks in advance…

Is there some reason you can’t draw a textured quad rather than attempting to abuse the aux buffer and CopyPixels? That at least would put you on the paths that everyone uses…

Anywho, looks like you have to request aux buffers to get any, and that GLUT doesn’t provide a mechanism to request them, so you’d have to convert to Cocoa or Carbon, or go the texturing route.

Probably have to go the texture quad route. Just thought a copy would be easier. Surprising its a problem.

Well, I draw a quad now to the screen with the texture and its much faster. Solved the performance issues. Maxing out the monitor.

Works great except for one issue. Sometimes there is a very slight line on the edge of the polygon. Seems to disappear depending on the dimensions of the polygon. Particularly, if the size is not proportional to the image. Turned clamping on just will not go away…any clues on that one? Its an ati 9800 card. Changing monitor resolutions brings out the problem since I draw widths and heights that are a % of the screen view port. So, looks great on 1024x768 but then in game mode on 800x600 the edge show up again. Also, I turned off lighting when I drew the polygon.

Also, is there a way to preserve depth buffer information? For example, if I wanted to overlay atmosphere on a horizon? If I draw the ploygon with a blending funtion it removes the depth information. Yet, if I do this then mouse clicks will not function. Seems like a better alternative to using fog. I suppose I could use a shader but thats not supported on all cards.

Thanks again… :slight_smile:

I’ve also seen a thin line on the right of stuff on Radeon 9500+ hardware in particular. I assume it can be fixed by altering texture coordinates or polygon coordinates slightly, but I’ve not tried it myself. The Red Book has some tips on getting a pixel-perfect projection.

In response to your other question, I’m not quite sure what you mean, but will glDepthMask(GL_FALSE) do what you need?

I’ll have to try glDepthMask.

The initial post was related to overlays like score etc. But I thought I could use the polygon overlay stuff for other issues. I was initially using glDrawPixels.

The related issue with this is I have a scene that gets clipped by far plane on the horizon. So, I wanted to use fog to obscure it. But fog is really expensive. I overlay a polygon with alpha colors to simulate the fog. It works really well. The only problem is the depth values get overwritten. So, if the user clicks that far on the horizon the unproject returns the incorrect value because the depth buffer is incorrect because of the overlay image of fog.

On a related note, drawing my scene I have a similar problem with the polygon edge issue I mentioned in an earlier post. So, my solution was to change the clear color to something compatible. But if I choose a fog of a different color then things get messy because it does not match the wanted clear color.

Thanks again… :slight_smile:

This topic was automatically closed 183 days after the last reply. New replies are no longer allowed.