summaryrefslogtreecommitdiffstats
Unidiff
-rw-r--r--src/controller/actions/set_ortho.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/controller/actions/set_ortho.c b/src/controller/actions/set_ortho.c
new file mode 100644
index 0000000..83b42f4
--- a/dev/null
+++ b/src/controller/actions/set_ortho.c
@@ -0,0 +1,21 @@
1#include "set_ortho.h"
2#include "../../view/exp004state0.h"
3#include <GL/glut.h>
4
5#define S exp004state0
6
7void
8set_ortho (void)
9{
10 if (S.zoom.active)
11 {
12 gluOrtho2D (S.zoom.coords[0],
13 S.zoom.coords[1], S.zoom.coords[2], S.zoom.coords[3]);
14 }
15 else
16 {
17 gluOrtho2D (S.ortho.min_x, S.ortho.max_x, S.ortho.min_y, S.ortho.max_y);
18 }
19
20 return;
21}

Valid XHTML 1.0 Strict

Copyright © 2009 Don Pellegrino All Rights Reserved.