summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Thompson <dthompson2@worcester.edu>2015-03-11 22:22:17 -0400
committerDavid Thompson <dthompson2@worcester.edu>2015-03-11 22:27:25 -0400
commit8cb85c6c2cb7ec7cb2621cd6871b3b29711cff99 (patch)
treea6fb3f9fe5f1088bef8bebb6bf3bbb3e7062c570
parent0fb4ec6b8cf60981bd1b96cfbf3bc41e0afead0d (diff)
render: shader: Add null-shader-program.
* sly/render/shader.scm (null-shader-program): New variable.
-rw-r--r--sly/render/shader.scm4
1 files changed, 3 insertions, 1 deletions
diff --git a/sly/render/shader.scm b/sly/render/shader.scm
index cf89427..f9949fa 100644
--- a/sly/render/shader.scm
+++ b/sly/render/shader.scm
@@ -52,6 +52,7 @@
shader-program-id
shader-program?
shader-program-linked?
+ null-shader-program
apply-shader-program
with-shader-program
load-default-shader
@@ -281,7 +282,8 @@ VERTEX-SHADER and FRAGMENT-SHADER."
(load-fragment-shader fragment-shader-file-name)
uniforms attributes))
-(define current-shader-program (make-parameter #f))
+(define null-shader-program
+ (%make-shader-program 0 '() '()))
(define (apply-shader-program shader-program)
(glUseProgram (shader-program-id shader-program)))