Hi,

I think one of the neatest features of Factor is being able to
dynamically reload vocabularies and have the changes immediately show up
in running code.  

Now, it seems this behavior is not really "magic" but relies on some
explicit coding.  (I vaguely remember seeing some git commits related to
this, with regard to making sure extant tuples can cope with structural
changes, etc.)  Of course, I forgot where that was in the meantime.

So, my question is, is there an article somewhere or a guide telling how
one's own words or data structures can be integrated into the reloading
mechanism?

For my specific needs, I'm slowly learning GLSL and using the very
convenient gpu.shaders vocabulary with GLSL-SHADER to make shaders
embedded in Factor source.  I have some tuples which reference shader
programs and apply them when drawing a scene.  But I'd like to see if
it's possible to reload/recompile/relink those shaders when I refresh
the vocabulary that defines them, so I can quickly explore the effects
of my changes.  Currently I have to restart my program to do this.

And, in a simpler case, the GL scene itself is defined as a data
structure but created at init time with code.  So again I have to
restart my program to test changes.  Would there be a way to hook things
so I can recreate my scene when I refresh the word or vocabulary that
defines the scene?

Of course, I could make gestures that explicitly reload these things,
but that's not cool enough ;)

Thanks for any pointers,

-- Ed



------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
Factor-talk mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/factor-talk

Reply via email to