render: scene: Stop allocating matrices when rendering.
authorDavid Thompson <dthompson2@worcester.edu>
Thu, 6 Sep 2018 16:19:22 +0000 (12:19 -0400)
committerDavid Thompson <dthompson2@worcester.edu>
Thu, 6 Sep 2018 16:19:22 +0000 (12:19 -0400)
commitbafb3b241cd0c07a41e932caa195a3a1144f7167
tree928b8317d70b285f99f5c267f5331714df4f0950
parent7703e6646b2ea3db978bb1f749b2eb5b257867de
render: scene: Stop allocating matrices when rendering.

* chickadee/render/scene.scm (<primitive>): Add matrix field.
(make-primitive): Call %make-primitive with additional matrix arg.
(<scene-node>): Add world-matrix field.
(make-scene-node): Call %make-scene-node with additional matrix arg.
(modelview): Delete.
(draw-primitive): Perform matrix multiplication without allocating.
(draw-scene-node): Likewise.
(draw-scene): Pass pre-built matrix rather than allocating.
chickadee/render/scene.scm