1al_perspective_transform(3)                        al_perspective_transform(3)
2
3
4

NAME

6       al_perspective_transform - Allegro 5 API
7

SYNOPSIS

9              #include <allegro5/allegro.h>
10
11              void al_perspective_transform(ALLEGRO_TRANSFORM *trans,
12                 float left, float top, float n,
13                 float right, float bottom, float f)
14

DESCRIPTION

16       Like  al_orthographic_transform(3)  but  honors perspective.  If every‐
17       thing is at a z-position of -near it will look the same as with an  or‐
18       thographic transformation.
19
20       To use a specific horizontal field of view you can use the relation:
21
22              tan(hfov / 2) = (right - left) / 2 / near
23

SINCE

25       5.1.3
26

SEE ALSO

28       al_use_projection_transform(3), al_orthographic_transform(3)
29
30
31
32Allegro reference manual                           al_perspective_transform(3)
Impressum