[Fluxus] render to texture

gabor papp gabor.lists at mndl.hu
Fri Jan 2 09:40:51 PST 2009


i am working on rendering to textures in fluxus, but got a bit stuck. i
modified the pixel primitive to use a framebuffer object, and i'm
planning to use it somehow like this:

(define pixels (build-pixels 256 256))

(bind pixels)
(draw-cube)
(unbind)

(bind) and (unbind) could be used similarly to (with-primitive ...)
using something like (bind-pixels ...).
if the pixels fbo is bound rendering is directed to the fbo instead of
the output window. when it is unbound the target of rendering is set
back to the window. then the rendered buffer can be used as a texture
using (pixels->texture).

the problem is that interpreting the script and rendering the scene is
done at different places, so as far as i understand binding should be
done when the rendering is taking place. am i right? or is there a more
logical way how to do this? should it be done by adding the target
buffer to the state? so when the scenegraph is rendered the target
buffer can be queried and bind/unbound? any suggestions are welcome.

best,
gabor





More information about the Fluxus mailing list