Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 6 of 6

Thread: opengl origin....

  1. #1
    Junior Member Newbie
    Join Date
    Apr 2013
    Posts
    23

    opengl origin....

    i am very new to opengl ...please let me know where is the origin of opengl window....
    and by default is it orthographic projection??

  2. #2
    Senior Member OpenGL Pro
    Join Date
    Jan 2012
    Location
    Australia
    Posts
    1,101
    The matrices both default to the identify matrix which makes the projection orthogonal. It is unusual to leave these un-modified except for a simple test.
    Since you posted this in the shader section I should add that for a shader there are no defaults you muse supply your own matrices.

  3. #3
    Junior Member Newbie
    Join Date
    Apr 2013
    Posts
    23
    Quote Originally Posted by tonyo_au View Post
    The matrices both default to the identify matrix which makes the projection orthogonal. It is unusual to leave these un-modified except for a simple test.
    Since you posted this in the shader section I should add that for a shader there are no defaults you muse supply your own matrices.
    sorry but i could not undestand much...i wanted to ask whether the origin is bottom left corner or otherwise...

    Thanx

  4. #4
    Senior Member OpenGL Pro
    Join Date
    Jan 2012
    Location
    Australia
    Posts
    1,101
    The origin is the centre of the viewport but you have to set the viewport - usually to the whole window. The viewport will be 2 world units wide and high for -1 - +1

  5. #5
    Junior Member Newbie
    Join Date
    Apr 2013
    Posts
    23
    Quote Originally Posted by tonyo_au View Post
    The origin is the centre of the viewport but you have to set the viewport - usually to the whole window. The viewport will be 2 world units wide and high for -1 - +1
    thanx a lot....but how can i set the full window as my viewport.....and if i can set a portion of it ...is there a way to mark it,,i mean sum solid boundary....i know my questions are very basic,,,,,but pls help..your help is highly obliged....

  6. #6
    Senior Member OpenGL Pro Aleksandar's Avatar
    Join Date
    Jul 2009
    Posts
    1,067
    I guess you should read this first.

Posting Permissions

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