EasyManuals Logo
Home>HP>Desktop>b2600

HP b2600 Reference Guide

HP b2600
486 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #321 background imageLoading...
Page #321 background image
P
gluPerspective
Chapter 14
321
gluPerspective
gluPerspective: set up a perspective projection matrix.
C Specification
void gluPerspective(
GLdouble fovy,
GLdouble aspect,
GLdouble zNear,
GLdouble zFar)
Parameters
fovy Specifies the field of view angle, in degrees, in the Y direction.
aspect Specifies the aspect ratio that determines the field of view in the X
direction. The aspect ratio is the ratio of X (width) to Y (height).
zNear Specifies the distance from the viewer to the near clipping plane
(always positive).
zFar Specifies the distance from the viewer to the far clipping plane (always
positive).
Description
gluPerspective specifies a viewing frustum into the world coordinate system. In general,
the aspect ratio in gluPerspective should match the aspect ratio of the associated
viewport. For example, aspect = 2.0 means the viewer’s angle of view is twice as wide in
X as it is in Y. If the viewport is twice as wide as it is tall, it displays the image without
distortion.
The matrix generated by gluPerspective is multiplied by the current matrix, just as if
glMultMatrix were called with thegenerated matrix. To load theperspective matrix onto
the current matrix stack instead, precede the call to gluPerspective with a call to
glLoadIdentity.
Given f defined as cotangent(fovy / 2), the generated matrix is
A 000
0f 00
00B C
00-10
where:
A = f / aspect
B = (zFar + zNear) / (zNear - zFar)
C = (2 × zFar × zNear) / (zNear × zFar)

Table of Contents

Other manuals for HP b2600

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the HP b2600 and is the answer not in the manual?

HP b2600 Specifications

General IconGeneral
BrandHP
Modelb2600
CategoryDesktop
LanguageEnglish

Related product manuals