[Fluxus] type polling of scene graph

Kassen signal.automatique at gmail.com
Sat Jan 8 14:14:16 PST 2011


Dear list,

Is there any way to poll a scene-graph id for it's type? What I mean is that
when I know that the scene-graph contains a primitive foo that might be
either a model loaded from a .obj file or a "particles", I'd like to do
something like;

(type foo) -> "particles"

or

(particles? foo) -> #t

If not are there other who would see this as useful or should I keep track
of it myself? If so, would such use be in balance to how hard a
implementation would be to do? Right now it seems to me that Racket
structures all and inherently have functions like "(string? bar)" and
"(number? baz)" yet our scene-graph lacks those.

In fact, in the above examples (number? foo) returns #t, which is fair, as
it *is* a number, literally speaking, but this does seem counter-intuitive
in the context of the scene-graph where we'd like to treat it as a a
"particles" (or a poly, or a ribbon, or a locator or....). Then again, if I
dig that deep I might be causing more trouble than it's worth, and while new
features could be imagined we'd lose the ability to iterate over the
scene-graph, unless that too would become accessible as a list. There might
be more unforeseen consequences.

Yours,
Kas.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pawfal.org/pipermail/fluxus-pawfal.org/attachments/20110108/d8ff38da/attachment-0001.htm>


More information about the Fluxus mailing list