Results 1 to 10 of 27

Thread: Ortho Setup

Threaded View

  1. #1
    Join Date
    Aug 2005
    Location
    Sweden
    Posts
    877

    Ortho Setup

    Hey,

    I need to get (OpenGL) ortho working... This is what I do to set it up..., well, this is practically the only thing I do but to draw:
    Code:
    glViewport(0, 0, width, height);
    glMatrixMode(GL_PROJECTION);
    glOrtho(0, width, 0, height, -1, 1);
    -It seems to work at first, but something... just doesn't look right...
    -Everyrthing's stretched that's what!! Eeek!!

    It apears as if OpenGL thinks the window is a square (same width as height), but since the width is larger than the height everything apears stretched...
    And when I draw a square in just front of the "camera" it takes up the whole window's though it should end before the window's x-borders...

    Everything apears to work as it should exept that it is stretched.
    Does anyone know why this might happen?

    Thanks!
    Last edited by EvilCookie; 08-08-2006 at 10:22 AM.

Posting Permissions

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