]> Dogcows Code - chaz/rasterize/blobdiff - vec.h
add opengl support
[chaz/rasterize] / vec.h
diff --git a/vec.h b/vec.h
index 2634de621fc590366e61e3a109188eb817de3e54..15de4845c5f87843f4c8a37390d33e385b4b0ae8 100644 (file)
--- a/vec.h
+++ b/vec.h
@@ -64,6 +64,16 @@ vec_t vec_new(scal_t x, scal_t y, scal_t z)
 #define VEC_ZERO_FREE vec_new2(S(0.0), S(0.0), S(0.0), S(0.0))
 
 
+/*
+ * Get a pointer to the vector data.
+ */
+INLINE_MAYBE
+const scal_t* vec_data(const vec_t* v)
+{
+    return &v->x;
+}
+
+
 /*
  * Print the vector to stdout.
  */
This page took 0.019561 seconds and 4 git commands to generate.