summaryrefslogtreecommitdiff
path: root/render.h
diff options
context:
space:
mode:
authorquou <quou@disroot.org>2024-07-27 11:15:21 +1000
committerquou <quou@disroot.org>2024-07-27 11:17:11 +1000
commit951f6115c16c3ab482c19705344295c90af1625b (patch)
treec7b140f8ba9db86955f2352d23fa9808138fad3e /render.h
parentd2c76fd62fa735f3d4fc3ceb55a75d6f0b2dc758 (diff)
clipping and viewport improvements.
Diffstat (limited to 'render.h')
-rw-r--r--render.h10
1 files changed, 8 insertions, 2 deletions
diff --git a/render.h b/render.h
index 996ba37..2299a30 100644
--- a/render.h
+++ b/render.h
@@ -42,8 +42,8 @@ typedef struct {
Colour* t;
int* d;
int asp, n;
- int vp[4];
- Rect clip;
+ int vp[2];
+ int clip[4];
} Renderer;
int tri_os(
@@ -95,6 +95,12 @@ void ren_texts(
int y,
const char* t
);
+void ren_line(
+ Renderer* r,
+ Colour c,
+ const int* s,
+ const int* e
+);
/* Vertex format:
* x y z u v r g b
* All fixed point values with 9 bits of precision.