added origin to mapper parameters

This commit is contained in:
2026-07-24 19:06:14 -07:00
parent eddbb85256
commit 5298e75fdb
10 changed files with 23 additions and 25 deletions
+2 -2
View File
@@ -28,7 +28,7 @@ namespace UwU {
Coord2 uv;
for (int16_t x = ix0; x < ix1; x++) {
uv = mapper.map(x, y);
uv = mapper.map(ix0, iy0, x, y);
buffer.drawPixel((uint16_t)x, (uint16_t)y, shader.shade(uv.x, uv.y));
if (d > 0) {
y += yi;
@@ -56,7 +56,7 @@ namespace UwU {
Coord2 uv;
for (int16_t y = iy0; y < iy1; y++) {
uv = mapper.map(x, y);
uv = mapper.map(ix0, iy0, x, y);
buffer.drawPixel((uint16_t)x, (uint16_t)y, shader.shade(uv.x, uv.y));
if (d > 0) {
x += xi;