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 2 of 2

Thread: double window management

  1. #1
    Junior Member Newbie
    Join Date
    Sep 2005
    Posts
    6

    double window management

    hi
    I perform terrain rendering in 2 windows.
    first one has pespective, second one has orthographic projection. When I change terrain dynamically, I cannot see it in orthographic window any more. But it works for perspective one.
    2 wndows are seperated not subwindow.
    does anyona knows something about this problem?

  2. #2
    Guest

    Re: double window management

    You need to completely define each viewport's transformations. The viewport transformation itself is part of the total transformation, along with the camera's position and orientation, and projection. That the viewport happens to be embedded in another physical window is largely irrelevant.

    For your perspective view, use gluPerspective or glFrustum along with your camera transformations. For your orthographic view, use glOrtho along with your camera transformations. Really, the camera part is the same for all the different views. What changes is the way you project the scene, and the size and shape of the viewport (aspect ratio).

Posting Permissions

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