Results 1 to 4 of 4

Thread: glTranslate

  1. #1

    glTranslate

    Hi to everyone:

    i've a question: if a draw a ugSolidCubef in a specific place with glTranslate(x,y,z) why if i move the "camera" the cube seems to move in uncoordinate mode?

    thanx,

    Giuseppe

  2. #2
    Senior Member
    Join Date
    May 2006
    Posts
    353
    I don't understand the question. What is "uncoordinate mode"?

    Post the relevant parts of your code, a description of what you get, and a description of what you expect to get. And don't forget to mention the implementation you're using.
    Georg Kolling, Imagination Technologies
    Please ask questions specific to PowerVR hardware or SDKs on the PowerVR Insider Forum
    DevTech@imgtec.com | http://www.powervrinsider.com

  3. #3
    Code :
    void display(UGWindow uwin)
     
    {
        glVertexPointer(3, GL_FLOAT, 0, plane);
        glEnableClientState(GL_VERTEX_ARRAY);
        glDrawArrays(GL_TRIANGLE_FAN, 0, 4);
     
       glPushMatrix();
       glColor4f(64/255.0f, 206/255.0f, 100/255.0f, 1.0f); // Verde
       glTranslatef(320087, 0.0f, -1464312.0f);
       ugSolidBox(30,50, 30);
       glPopMatrix();
    }

    When i move my "camera" the box drawn seem to move in a different way respectly the pavement...ok?
    Why this? When i recall the "display" to move the P.O.V., the box move in a different way respectly the pavement..
    Please help me,

    Regards,
    Gius

  4. #4
    Senior Member
    Join Date
    May 2006
    Posts
    353
    How do you move the camera? What pavement?
    Georg Kolling, Imagination Technologies
    Please ask questions specific to PowerVR hardware or SDKs on the PowerVR Insider Forum
    DevTech@imgtec.com | http://www.powervrinsider.com

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •