summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sly/render/mesh.scm9
1 files changed, 9 insertions, 0 deletions
diff --git a/sly/render/mesh.scm b/sly/render/mesh.scm
index 5f577ca..1a666e3 100644
--- a/sly/render/mesh.scm
+++ b/sly/render/mesh.scm
@@ -25,6 +25,7 @@
#:use-module (system foreign)
#:use-module (ice-9 match)
#:use-module (srfi srfi-9)
+ #:use-module (srfi srfi-9 gnu)
#:use-module (srfi srfi-43)
#:use-module (rnrs bytevectors)
#:use-module (gl)
@@ -56,6 +57,14 @@
(usage vertex-buffer-usage)
(data vertex-buffer-data))
+(set-record-type-printer! <vertex-buffer>
+ (lambda (vbo port)
+ (format port
+ "#<vertex-buffer id: ~d type: ~a usage: ~a"
+ (vertex-buffer-id vbo)
+ (vertex-buffer-type vbo)
+ (vertex-buffer-usage vbo))))
+
(define (generate-vertex-buffer)
(let ((bv (u32vector 1)))
(glGenBuffers 1 (bytevector->pointer bv))