summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBad Diode <bd@badd10de.dev>2021-04-15 13:47:08 +0200
committerBad Diode <bd@badd10de.dev>2021-04-15 13:47:08 +0200
commit15bbf02a92688dfe38b892d327fb54cf051a0808 (patch)
tree6d50202df44f57ec091898ccab06701999e119ef
parentdd5bf6cfc680451f7fc69f3251d103739ae6446b (diff)
downloadgba-experiments-15bbf02a92688dfe38b892d327fb54cf051a0808.tar.gz
gba-experiments-15bbf02a92688dfe38b892d327fb54cf051a0808.zip
Update some comments
-rw-r--r--src/main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main.c b/src/main.c
index 06fe7d9..c179dc4 100644
--- a/src/main.c
+++ b/src/main.c
@@ -100,7 +100,7 @@ draw_line(int x0, int y0, int x1, int y1, Color clr) {
100 int x = x0; 100 int x = x0;
101 int y = y0; 101 int y = y0;
102 102
103 // Normalize the drawing direction to always draw from (x0, y0)->(x1, y1) 103 // Adjust the step direction and calculate deltas.
104 int x_step = 1; 104 int x_step = 1;
105 int y_step = 1; 105 int y_step = 1;
106 int dx = x1 - x0; 106 int dx = x1 - x0;
@@ -114,7 +114,7 @@ draw_line(int x0, int y0, int x1, int y1, Color clr) {
114 dy = y0 - y1; 114 dy = y0 - y1;
115 } 115 }
116 116
117 // Precalculate line deltas. 117 // Precalculate 2 * deltas for x and y.
118 int ddx = dx + dx; 118 int ddx = dx + dx;
119 int ddy = dy + dy; 119 int ddy = dy + dy;
120 120