Is their anyway to simulate non rectangular viewports using GL ?
To give an idea of what I want to do:
------------------------------------
Say I have a cube:
top
-----------------------
/| /|
/ | / |
/ | / |
/ | / |
/ | front / |
/ | / |
----------------------- | right
| | | |
| | | |
| | | |
| ---------------|-------
left | / | /
| / | /
| / | /
| / bottom | /
| / | /
|/ |/
-----------------------
Now, I want to designate a viewpoint somewhere inside the cube and
then use the "window()" function to calculate five windows corresponding
to the front, left, right, top and bottom of the cube and then arrange
them on the screen in the following manner:
------------------------------------------
|\ /|
| \ / |
| \ top / |
| \ / |
| \ / |
| \----------------------------/ |
| | | |
| | | |
| | | |
| | | |
| | | |
|left | front |right|
| | | |
| | | |
| | | |
| | | |
| | | |
| /----------------------------\ |
| / \ |
| / \ |
| / bottom \ |
| / \ |
|/ \|
------------------------------------------
I know this CAN be done by texture mapping onto a cube using one of our VGX's,
BUT I want the program to run on a Personal Iris also, so I want to stay away
from texture mapping.
Since by using the "viewport()" function you can only designate a rectangular
area on the screen as a viewport, is there any way to simulate this effect
by shearing?
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Graduate Research Assistant |
| EECS Dept. |
| University of Illinois at Chicago |
| |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+