Skip to content

Commit 9b46c2a

Browse files
committed
Updated ortho() example and reference, per processing/processing#1278
1 parent 4b1e172 commit 9b46c2a

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

‎content/api_en/ortho.xml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
<code><![CDATA[
1414
size(100, 100, P3D);
1515
noFill();
16-
ortho(0, width, 0, height); // same as ortho()
16+
ortho(-width/2, width/2, -height/2, height/2); // same as ortho()
1717
translate(width/2, height/2, 0);
1818
rotateX(-PI/6);
1919
rotateY(PI/3);

‎content/examples/Basics/Camera/Orthographic/Orthographic.pde‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ void draw() {
2626
if (showPerspective == true) {
2727
perspective(PI/3.0, float(width)/float(height), 10, far);
2828
} else {
29-
ortho(0, width, 0, height, 10, far);
29+
ortho(-width/2, width/2, -height/2, height/2, 10, far);
3030
}
3131
translate(width/2, height/2, 0);
3232
rotateX(-PI/6);

0 commit comments

Comments
 (0)