git.ucc.asn.au
/
atyndall
/
cits2231.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
1f60a33
)
(no commit message)
author
Ash Tyndall
<
[email protected]
>
Tue, 18 Oct 2011 11:31:43 +0000
(19:31 +0800)
committer
Ash Tyndall
<
[email protected]
>
Tue, 18 Oct 2011 11:31:43 +0000
(19:31 +0800)
scene.c
patch
|
blob
|
history
diff --git
a/scene.c
b/scene.c
index
3a1cae6
..
64fcdb5
100644
(file)
--- a/
scene.c
+++ b/
scene.c
@@
-599,16
+599,18
@@
int drawFloorRecurse = 10;
\r
void drawSquare(int recurseLevel, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2) {
\r
\r
\r
void drawSquare(int recurseLevel, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2) {
\r
\r
+ printf("Recurse level %d", recurseLevel);
\r
+
\r
if ( drawFloorRecurse != recurseLevel ) {
\r
if ( drawFloorRecurse != recurseLevel ) {
\r
- GLfloat xm = (x2 - x1) / 2;
\r
+ GLfloat xm = (x2 - x1) / 2
.0
;
\r
if ( x1 > x2 ) {
\r
if ( x1 > x2 ) {
\r
- xm = (x1 - x2) / 2;
\r
+ xm = (x1 - x2) / 2
.0
;
\r
}
\r
\r
drawSquare(recurseLevel + 1, x1, y1, xm, y2);
\r
drawSquare(recurseLevel + 1, xm, y1, x2, y2);
\r
} else {
\r
}
\r
\r
drawSquare(recurseLevel + 1, x1, y1, xm, y2);
\r
drawSquare(recurseLevel + 1, xm, y1, x2, y2);
\r
} else {
\r
- printf("Drawing (%f, %f) -> (%f, %f)", x1, y2, x2, y2);
\r
+ printf("Drawing (%f, %f) -> (%f, %f)
\n
", x1, y2, x2, y2);
\r
glBegin(GL_QUADS);
\r
glVertex3f(x1, 0.0, y1);
\r
glVertex3f(x1, 0.0, y2);
\r
glBegin(GL_QUADS);
\r
glVertex3f(x1, 0.0, y1);
\r
glVertex3f(x1, 0.0, y2);
\r
UCC
git Repository :: git.ucc.asn.au