Projection Routines.


All the projection routines define a new transformation matrix, and consequently the world units. Parallel projections are defined by ortho or ortho2. Perspective projections can be defined by perspective and window.

fobjvws

ortho(left, right, bottom, top, near, far)

Define x (left, right), y (bottom, top), and z (near, far) clipping planes. The near and far clipping planes are actually specified as distances along the line of sight. These distances can also be negative. The actual location of the clipping planes is z = -near_d and z = -far_d.

    Fortran:
         subroutine ortho(left, right, bottom, top, near_d, far_d)
         real left, right, bottom, top, near_d, far_d

    C:
         ortho(left, right, bottom, top, near_d, far_d)
              float     left, right, bottom, top, near_d, far_d;

    Pascal:
     procedure Ortho(left, right, bottom, top, near_d, far_d: real)

ortho2(left, right, bottom, top)

Define x (left, right), and y (bottom, top) clipping planes.

    Fortran:
         subroutine ortho2(left, right, bottom, top)
         real left, right, bottom, top

    C:
         ortho2(left, right, bottom, top)
              float     left, right, bottom, top;

    Pascal:
         procedure Ortho2(left, right, bottom, top: real)

perspective(fov, aspect, near, far)

Specify a perspective viewing pyramid in world coordinates by giving a field of view, aspect ratio and the distance from the eye of the near and far clipping plane.

    Fortran:
         subroutine perspective(fov, aspect, near, far)
         real fov, aspect, near, far

    C:
         perspective(fov, aspect, near, far)
              float     fov, aspect, near, far;

    Pascal:
         procedure Perspective(fov, aspect, near, far: real)

window(left, right, bot, top, near, far)

Specify a perspective viewing pyramid in world coordinates by give the rectangle closest to the eye (ie. at the near clipping plane) and the distances to the near and far clipping planes.

    Fortran:
         subroutine window(left, right, bot, top, near, far)
         real left, right, bot, top, near, far

    C:
         window(left, right, bot, top, near, far)
              float     left, right, bot, top, near, far;


    Pascal:
         procedure Window(left, right, bot, top, near, far: real)