This is Interesting: Free Magazines for Graphics designers and webmasters  


Home > Archive > VRML > February 2006 > VRML - viewpoint orientattion and gluLookAt





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author VRML - viewpoint orientattion and gluLookAt
wito

2006-01-22, 11:02 pm

Hi!

I am writing simple VRML loader in OpenGl, and I want to show model exacly
from position defined in Vievpoint node;
I looked for similar topis in net and I found that It is a common problem -
how to proper handle vievpoint orientation:

I was reading diffrent post I am relly confused about this: i was playing
with the code and found out that:

gl.glMatrixMode (GL.GL_PROJECTION_MATRIX);
gl.glLoadIdentity();

glu.gluLookAt( vp.position.x, vp.position.y, vp.position.z,
0,0,0,
vp.orientation.x, vp.orientation.y, vp.orientation.z);
gl.glMatrixMode (GL.GL_MODELVIEW);

the results are quite similar - but this is not that - i am not using
angle!!


is this possible to not to use quaternions and have it proper displayed??

maby somebody implemented this and share this peaco of code???


any hints welcomed!!

--
wito






intelijent@rock.com

2006-02-07, 11:41 pm

http://groups.google.com/group/Avat...a?lnk=srg&hl=en

wito wrote:
> Hi!
>
> I am writing simple VRML loader in OpenGl, and I want to show model exacly
> from position defined in Vievpoint node;
> I looked for similar topis in net and I found that It is a common problem -
> how to proper handle vievpoint orientation:
>
> I was reading diffrent post I am relly confused about this: i was playing
> with the code and found out that:
>
> gl.glMatrixMode (GL.GL_PROJECTION_MATRIX);
> gl.glLoadIdentity();
>
> glu.gluLookAt( vp.position.x, vp.position.y, vp.position.z,
> 0,0,0,
> vp.orientation.x, vp.orientation.y, vp.orientation.z);
> gl.glMatrixMode (GL.GL_MODELVIEW);
>
> the results are quite similar - but this is not that - i am not using
> angle!!
>
>
> is this possible to not to use quaternions and have it proper displayed??
>
> maby somebody implemented this and share this peaco of code???
>
>
> any hints welcomed!!
>
> --
> wito


Sponsored Links


Copyright 2003 - 2008 forum4designers.com  Software forum  Computer Hardware reviews