[Fluxus] Question (attempt 2, please ignore the previous incomplete message)

Hugo van Galen hugovangalen at gmail.com
Tue Jun 29 00:23:30 PDT 2010


OK apparently my fat fingers hit the Gmail Send button way too early. Please
disregard the previous mail I sent.

--

    Hi list,

I have only recently joined this list, so please be gentle ;-)

I am a coder by profession with a C, C++ and Pascal background. Recently I
discovered (fluxus) and have been playing around with it and it has been fun
so far, although a little frustrating at times.

See, and hence this message to the list, I seem to be running into some
practical problems which I cannot find a solution for. (This may be partly
because of my inexperience with LISP in general: the last time I used it was
in AutoCAD in the late 80's...)

Anyway, here is the situation:

- I build an X amount of cubes with the "build-cube" command.
    From what I understand so far, this is the best philosophy: "building"
the primitives rather than "drawing" them every-time.

- I want to manipulate its size and rotation.
    So far, not a problem. After I 'build-cube' I manipulate this with:

      (with-primitive cube
            (rotate (vector rotation rotation rotation))
            (scale 1.2)
      )

   Doing that every-frame will grow the primitive too large to display in
the window, so it mans that this scale of 1.2 is 'multiplied' against the
primitives current scale factor.

That effect was 'interesting' so I kept it in. Then I ran into the problem I
am trying to find a solution for:

- At a certain point, I want to "re-set" all the cubes to their initial
size, i.e. "scale = 1".  This, without reseting its position and/or
rotation. So the (identity) call is not what I am looking for (or is it?)].


I have taken a look at all the various examples but there doesn't seem to be
anything resembling what I'm trying to do here (and I cannot imagine me
being the first trying). Iit seems to me that, if (scale 1.5) increases the
size by 150%, the environment *must* know the current scale/size of that
primitive? Or is my understanding completely flawed here? ;)

I have seen the "get-transform" function, but I am a bit puzzled by what it
returns, it doesn't seem to have the info I'm looking for.



As a workaround, I have tried to maintain an array of 'sizes' that I
inspect, and calculate the new "scale factor" from it. Interesting idea but
this horribly fails due to not having grasped how LISP handles variables /
lists [array element does not get updated].


I have a feeling that what I am trying to accomplish is already perfectly
possible and hope to get a hint into the right direction.

Thanks in advance for any replies,

Best regards,
Hugo
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pawfal.org/pipermail/fluxus-pawfal.org/attachments/20100629/946ae459/attachment-0002.htm>


More information about the Fluxus mailing list