summaryrefslogtreecommitdiff
path: root/internal.h
diff options
context:
space:
mode:
Diffstat (limited to 'internal.h')
-rw-r--r--internal.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/internal.h b/internal.h
index 6cd512c..8b6784f 100644
--- a/internal.h
+++ b/internal.h
@@ -45,7 +45,6 @@ void rmfbctl(Framebufctl*);
/* vertex */
Vertex dupvertex(Vertex*);
-void swapvertex(Vertex*, Vertex*);
void lerpvertex(Vertex*, Vertex*, Vertex*, double);
void berpvertex(Vertex*, Vertex*, Vertex*, Vertex*, Point3);
void delvattrs(Vertex*);
@@ -58,8 +57,6 @@ int rectclipline(Rectangle, Point*, Point*, Vertex*, Vertex*);
/* util */
int min(int, int);
int max(int, int);
-void swapi(int*, int*);
-void swappt(Point*, Point*);
void memsetf(void*, float, usize);
void memsetl(void*, ulong, usize);
@@ -70,3 +67,6 @@ uvlong nanosec(void);
#define getpixel(fb, p) (((fb)->cb)[Dx((fb)->r)*(p).y + (p).x])
/* void putpixel(Framebuf *fb, Point p, ulong c) */
#define putpixel(fb, p, c) (((fb)->cb)[Dx((fb)->r)*(p).y + (p).x] = (c))
+
+/* void SWAP(type t, type *a, type *b) */
+#define SWAP(t, a, b) {t tmp; tmp = *(a); *(a) = *(b); *(b) = tmp;}