Is a non-rectangular viewport possible? Eg. looking thru a static image
of car windshield or house window.
thanx
JD
thanx
JD
-Tom j
> thanx
> JD
Another option would be to use overlay planes. Unfortunately, all
implementations do not support them. You also might not be able to get them
in the desired pixel depth.
-Paul Martz
Hewlett Packard Graphics Products Lab
To reply, remove "DONTSPAM" from email address.
You can either use the stencil buffer, or you can use the depth
buffer. Normally an application will clear the buffers at the
start of a frame using glClear. For this purpose, you want to
clear the buffers in two passes.
First, you want to clear the entire window to denote it as 'outside';
either setting the stencil buffer to 0 or the depth buffer to 'near'.
This might be done at the beginning of time, rather than for
each frame.
Second, you want to clear the 'inside' and mark it as such. You
want to render geometric primitives with background color/texture
that cover 'inside', either setting the stencil values to 1 or
setting the depth value to 'far' (use GL_ALWAYS as the depth test).
Finally, you are ready to render the rest of the frame, setting
the stencil test to == 1 or using depth testing 'normally'. You may
want to use glDepthRange to make sure that the frame can't interfere
with the depth values used to mark 'outside'.
--
Andy V, OpenGL Alpha Geek (never a Digital spokesperson)
(To send mail to me, remove ".NoSpamEver".)
3. Software for non-rectangular geometry
4. how to make new friends online - easy, it works great !
5. Contour plotting on a non-rectangular grid
6. VGA smooth scrolling in 12h?
7. non-rectangular images with no background
9. Save an image on non-rectangular canvas?
10. how to make non-rectangular gifs?