Skip to content

Commit 0864516

Browse files
authored
Merge pull request processing#499 from spencermathews/feature/ortho-fix
Ortho example in p3d tutorial is broken
2 parents 688275f + 859c7e6 commit 0864516

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

content/static/tutorials/p3d/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -394,7 +394,7 @@ <h3>Perspective</h3>
394394
float cameraZ = (height/2.0) / tan(fov/2.0);
395395
perspective(fov, float(width)/float(height), cameraZ/2.0, cameraZ*2.0);
396396
} else {
397-
ortho(0, width, 0, height);
397+
ortho(-width/2, width/2, -height/2, height/2);
398398
}
399399
translate(width/2, height/2, 0);
400400
rotateX(-PI/6);

0 commit comments

Comments
 (0)