render: texture: Support using 32 texture units.
authorDavid Thompson <dthompson2@worcester.edu>
Fri, 31 Mar 2017 19:14:30 +0000 (15:14 -0400)
committerDavid Thompson <dthompson2@worcester.edu>
Fri, 31 Mar 2017 19:23:41 +0000 (15:23 -0400)
commit8152ddc9e677dcf9bf553d5b9a95148ff48cc17c
treec1537424bedc9dc1a26c821975f7414f603f676e
parent4ba1a03337ec50e3fabe0f50c76fcbfc458f3abf
render: texture: Support using 32 texture units.

* chickadee/render/texture.scm (make-apply-texture, texture-ref,
texture-set!): New procedures.
(*texture-states*): New variable.
(apply-texture, *texture-state*): Delete.
(make-texture): Use 'vector-set!'
* chickadee/render/shader.scm: Export 'uniform-type'.
(default-uniform-value): Remove 'sampler-2d' case.
(extract-uniforms): Handle sampler-2d uniforms specially.
* chickadee/render.scm (current-texture): Add 'i' argument.
(with-texture): Add 'n' argument.
(gpu-apply*): Set textures for all texture units.
* .dir-locals.el: Update indentation rules for 'with-texture'.
.dir-locals.el
chickadee/render.scm
chickadee/render/shader.scm
chickadee/render/sprite.scm
chickadee/render/texture.scm