Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Graphics > OpenGL 3D API > Re: glTranslate...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 2 of 3 Topic 4805 of 5041
Post > Topic >>

Re: glTranslatef and coordinate system

by Medvedev <3D.v.World@[EMAIL PROTECTED] > Jun 20, 2008 at 12:36 PM

On Jun 20, 10:58 am, Medvedev <3D.v.Wo...@[EMAIL PROTECTED]
> wrote:
>               +y
>               |
>               |
>               | __ __ __ +x
>              /
>            /
>          /
>        +z
>
> please , i want to know if the coordinate system we are working on
> opengl in organized in the above way
> because when i do:
> glTranslatef( 0.0,0.0,-5.0);
> the object move in the +z instead of getting backward , why?!!!!!!!!
> here is the full code
>
> glMatrixMode(GL_MODELVIEW);
> glLoadIdentity();
>
> glTranslatef(0.0,0.0,-5.0);
> glColor3f(0.0,1.0,0.0);   //green
> glutSolidCube(1.0f);      //cube 1
>
> glLoadIdentity();
> glColor3f(1.0,0.0,0.0);   //Red
> glutSolidCube(2.0f);     //cube 2
> ---
> u will find that the first drawn cube will get forward to camera
> instead of moving backward along the -z axis

i got it!!!!!!!!!!!!!
thanks for nothing :)
 




 3 Posts in Topic:
glTranslatef and coordinate system
Medvedev <3D.v.World@[  2008-06-20 11:58:07 
Re: glTranslatef and coordinate system
Medvedev <3D.v.World@[  2008-06-20 12:36:17 
Re: glTranslatef and coordinate system
Wolfgang Draxinger <wd  2008-06-20 21:48:46 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Mon Dec 1 23:58:54 CST 2008.