<html>
<head>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
I think it may make sense in addition to having a
one-shot-independent animations that have no guarantee of staying in
sync with the audio (e.g. these could be useful for mouse-over
button animations) that your animation object can also receive a
decimal value between its originator and destination, allowing for
each keyframe to be a whole number. So, 0-1 would interpolate
between the starting state and first keyframe, 1-2 between first and
second keyframes, etc., and thus allow pd to use its timing
mechanism to project changes in animation state via a line object, a
counter or something similar. IIRC most (all?) HTML5-based
animations can be triggered as independent events or can be given a
specific percentage value. The one-shot object could interact with
independent events, while the proposed object could interact with
the latter.<br>
<br>
That said, not knowing how you have imagined your animation object,
it may be tricky to implement this as it would require object to
keep track of all the keyframed events (assuming there are more than
one). If you are thinking of having the animation object track only
one single animation (e.g. something progressing from 30% to 90%),
the same could still prove useful except in this case you would only
allow for values between 0 and 1.<br>
<br>
<div class="moz-cite-prefix">On 1/2/2016 1:12 PM, Jonathan Wilkes
via Pd-list wrote:<br>
</div>
<blockquote
cite="mid:1690050110.6243255.1451758342294.JavaMail.yahoo@mail.yahoo.com"
type="cite">
<div style="color:#000; background-color:#fff;
font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial,
Lucida Grande, sans-serif;font-size:16px">
<div id="yui_3_16_0_1_1451752408813_3953">Hi list,</div>
<div id="yui_3_16_0_1_1451752408813_3952">I'm playing with
adding a simple animation api to data structure drawing
commands. <br>
</div>
<div id="yui_3_16_0_1_1451752408813_3951">The parameters will be
sent to the GUI, and the GUI will take care of the ramp,
delay, etc.</div>
<div id="yui_3_16_0_1_1451752408813_3950"><br>
</div>
<div id="yui_3_16_0_1_1451752408813_9398">I'm thinking of just
making it a simple "set it and forget it" api. That is, you
send a message <br>
</div>
<div id="yui_3_16_0_1_1451752408813_7749" dir="ltr">with your
ramp and delay times to the GUI, and you just blindly trust
that the GUI will make <br>
</div>
<div id="yui_3_16_0_1_1451752408813_9399" dir="ltr">things
happen in the right amount of time. The alternative I can
think of is to have the GUI <br>
</div>
<div id="yui_3_16_0_1_1451752408813_7739" dir="ltr">call back
when an animation is finished, but that would encourage mixing
the two clocks <br>
</div>
<div dir="ltr">(i.e., GUI and Pd clock) in unpredictable <br>
</div>
<div id="yui_3_16_0_1_1451752408813_7740" dir="ltr">ways.</div>
<div id="yui_3_16_0_1_1451752408813_9400" dir="ltr"><br>
</div>
<div id="yui_3_16_0_1_1451752408813_9401" dir="ltr">Does this
simple approach seem like a reasonable design? The biggest
problem would be that <br>
</div>
<div id="yui_3_16_0_1_1451752408813_9402" dir="ltr">a
long-running animation could skew. But in that case you could
probably amortize the cost of</div>
<div id="yui_3_16_0_1_1451752408813_9431" dir="ltr">sending more
messages over the longer time period.<br>
</div>
<div id="yui_3_16_0_1_1451752408813_9403" dir="ltr"><br>
</div>
<div dir="ltr">-Jonathan<br>
</div>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
<a class="moz-txt-link-abbreviated" href="mailto:Pd-list@lists.iem.at">Pd-list@lists.iem.at</a> mailing list
UNSUBSCRIBE and account-management -> <a class="moz-txt-link-freetext" href="http://lists.puredata.info/listinfo/pd-list">http://lists.puredata.info/listinfo/pd-list</a>
</pre>
</blockquote>
<br>
</body>
</html>