Re: Problems with OpenGL conversion of distortion correction program

New Message Reply Date view Thread view Subject view Author view

Sharon Clay (src++at++rose)
Tue, 9 Apr 1996 18:00:42 -0700


+>---- On Apr 9, 4:33pm, Tom McReynolds wrote:
> Subject: Re: Problems with OpenGL conversion of distortion correction prog

->>
->> glViewport( 0, 0, 1024, 1024);
->> /* texbind(TX_TEXTURE_0, 1024);
->> fbsubtexload(0, 0, TX_TEXTURE_0, 1024, 0.0, 1.0, 0.0, 1.0, flags); */
->> /* glCopyTexImage2DEXT (...); */ /* Don't know arguments yet */
->>
->> gluOrtho2D(0.0, 16.0, 0.0, 16.0);
->> glLoadIdentity();
->
->You probably want to reverse the order of these two. The second is undoing the
->first...

I think what Tom is hinting at here is that gluOrtho2D and glOrtho
both operate multiplicitivly on the current matrix.
So, you proably want:
         
        glMatrixMode(GL_PROJECTION);
        glLoadIdentity()
        gluOrtho2D()
        glMatrixMode(GL_MODELVIEW);
        glLoadIdentity();

src.

-- 
-----{-----{---++at++   -----{----{---++at++   -----{----{---++at++   -----{----{---++at++
Sharon Rose Clay (Fischler) - Silicon Graphics, Advanced Systems Dev.
src++at++sgi.com  (415) 933 - 1002  FAX: (415) 965 - 2658  MS 8U-590
-----{-----{---++at++   -----{----{---++at++   -----{----{---++at++   -----{----{---++at++

New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2.0b2 on Mon Aug 10 1998 - 17:52:41 PDT

This message has been cleansed for anti-spam protection. Replace '++at++' in any mail addresses with the '@' symbol.