Replacing the perspective matrix.

Bruce R. Holloway bruceh at brushwud.asd.sgi.com
Wed Jun 27 05:53:24 AEST 1990


In article <62846 at sgi.sgi.com>, tarolli at riva.esd.sgi.com (Gary Tarolli) writes:
> In article <696 at celia.UUCP>, keith at celia.UUCP (Keith Goldfarb) writes:
> > 
> > What I want to do is to replace the current projection matrix
> > (while in viewing mode) with one of my choosing with a call
> > like loadmatrix().  Does such a call exist?
> 
> The way to do this is to get into MPROJECTION mode, using
> 
> 	mmode(MPROJECTION);
> 
> and then use loadmatrix, and return to the previous mmode.  In MVIEWING
> mode, loadmatrix will load the model-view matrix, so that is why you must
> get into MPROJECTION mode.  This should work, but there may be a bug on
> the GT/GTX machines (I think this was reported and fixed in the just
> released 3.3 version).

Gary is correct, except that the bug was replicated in the original
Personal Iris graphics.  I think this is the 4D/20 model only.

Even though the PI & GT were fixed in 3.3 so that Gary's advice will work,
there are still some limitations on the projection matrix you load.
Basically, there can be no rotation in the projection matrix & any
plane of projection must intersect only the z-axis.  The matrices
created by the GL calls which set the projection matrix all qualify.

If you find it really necessary to load a more general projection matrix,
you may report a bug.  (I can't guarantee to fix it!)  The GT graphics
has been out for over two years & only one customer ever complained.
He was satisfied with the 3.3 version.  To the best of my knowledge,
the new VGX graphics will handle a fully general projection matrix.

Feel free to email me if you have further questions.  There is a five-
page technical report that is about 90% complete, but it was sort of
written for internal consumption.

Regards, bruceh



More information about the Comp.sys.sgi mailing list