<br><br><br><div><span class="gmail_quote">On 3/5/07, <b class="gmail_sendername">Jon Molesa</b> &lt;<a href="mailto:rjmolesa@consoltec.net">rjmolesa@consoltec.net</a>&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Nice solution to a problem.&nbsp;&nbsp;Mind if I include this in the wip<br>documentation as an example?</blockquote><div><br><br>what is the &quot;wip&quot; documentation? -- sure.. you can use the example in the doc.<br>&nbsp;</div><br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">In either case, your issue isn&#39;t so much with swfmill as it is a<br>mathematical conversion from ms to fps.&nbsp;&nbsp;Is that a correct assessment?
</blockquote><div><br><br>You&#39;re absolutely right.&nbsp; The real question here is what is a good formula for converting milliseconds to frames.&nbsp; Right now I&#39;m doing this in my perl script:<br><br>$fps = 15;<br>$frameNum = int($millisecondTimeStamp/1000 * $fps);
<br><br>&nbsp;</div><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">My first thought is to decide on a fps rate that you&#39;d like to have.<br>
Then there _could_ be total of 1000 fps with the framegrabber. A fps of<br>12 fps is a good speed for the human eye I believe?? Double check on that.<br>You&#39;d have to figure out which block the captured frame fell into and place it
<br>in that frame.&nbsp;&nbsp;On a 12 second frame rate, 1 frame would contain<br>83.33ms.&nbsp;&nbsp;So you&#39;d just have to figure out what which block the captured<br>frame fell into.&nbsp;&nbsp;swfmill frame second1-frame1~=84ms, second1-frame2~=168ms... and so on.
<br>It&#39;s too early to come up with a formula, but maybe later, or maybe<br>someone else can develop that.&nbsp;&nbsp;Anyway, I hope it helps and is close to<br>correct.&nbsp;&nbsp;But that&#39;s the way I see it.<br><br>* Seth Markowitz &lt;
<a href="mailto:seth.markowitz@gmail.com">seth.markowitz@gmail.com</a>&gt; wrote:<br><br>&gt; Hi,<br>&gt;<br>&gt; I&#39;m a newbie to swfmill, but I did get it working for my purposes... I&#39;m<br>&gt; just trying to figure out how to make it more efficient.&nbsp;&nbsp;Here is my
<br>&gt; situation:<br>&gt;<br>&gt; Here&#39;s my inventory:<br>&gt; 1. I have 1000 jpg images taken from a vga frame grabber - NOT in frames per<br>&gt; second... the timing is variable.&nbsp;&nbsp;For example, file1.jpg was grabbed at
<br>&gt; 30ms, file2.jpg was grabbed at 400ms, file3.jpg at 410ms, an so on. The time<br>&gt; starts from Time == 0ms when the frame grabber was turned on.<br>&gt;<br>&gt; 2. I have an XML file called capture.xml&nbsp;&nbsp;that contains the timestamp in
<br>&gt; milliseconds for when each jpg was captured:<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&lt;Capture&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;FileName&gt;Slide_0020.jpg&lt;/FileName&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;SlideNumber&gt;20&lt;/SlideNumber&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;CaptureTime&gt;64174&lt;/CaptureTime&gt;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&lt;/Capture&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&lt;Capture&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;FileName&gt;Slide_0021.jpg&lt;/FileName&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;SlideNumber&gt;21&lt;/SlideNumber&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;CaptureTime&gt;64869&lt;/CaptureTime&gt;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&lt;/Capture&gt;<br>&gt;<br>&gt; So....<br>&gt; By putting all the jpg files together into a SWF via swfmill, I should have<br>&gt; a fairly descent &quot;flipbook&quot; type animation.&nbsp;&nbsp;I&#39;ve created a perl script to
<br>&gt; parse the capture.xml file and creates a swfml file that looks like this:<br>&gt;<br>&gt; &lt;?xml version=&quot;1.0&quot; encoding=&quot;iso-8859-1&quot; ?&gt;<br>&gt; &lt;movie width=&quot;640&quot; height=&quot;480&quot; framerate=&quot;15&quot;&gt;
<br>&gt;&nbsp;&nbsp;&lt;background color=&quot;#ffffff&quot;/&gt;<br>&gt; &lt;frame&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&lt;!-- frame:0&nbsp;&nbsp;ptime:54 --&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&lt;library&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;clip id=&quot;image1&quot; import=&quot;Slide_0001_Full_resize.jpg&quot; /&gt;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&lt;/library&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&lt;place id=&quot;image1&quot; name=&quot;myImage1&quot; x=&quot;0&quot; y=&quot;0&quot; depth=&quot;1&quot; /&gt;<br>&gt; &lt;/frame&gt;<br>&gt; &lt;frame/&gt;&lt;frame/&gt;&lt;frame/&gt;&lt;frame/&gt;&lt;frame/&gt;&lt;frame/&gt;&lt;frame&gt;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&lt;!-- frame:6&nbsp;&nbsp;ptime:408 --&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&lt;library&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;clip id=&quot;image2&quot; import=&quot;Slide_0002_Full_resize.jpg&quot; /&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&lt;/library&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&lt;place id=&quot;image2&quot; name=&quot;myImage2&quot; x=&quot;0&quot; y=&quot;0&quot; depth=&quot;2&quot; /&gt;
<br>&gt; &lt;/frame&gt;<br>&gt; &lt;frame/&gt;&lt;frame/&gt;&lt;frame/&gt;&lt;frame/&gt;&lt;frame/&gt;&lt;frame&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&lt;!-- frame:11&nbsp;&nbsp;ptime:752 --&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&lt;library&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;clip id=&quot;image3&quot; import=&quot;Slide_0003_Full_resize.jpg&quot; /&gt;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&lt;/library&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&lt;place id=&quot;image3&quot; name=&quot;myImage3&quot; x=&quot;0&quot; y=&quot;0&quot; depth=&quot;3&quot; /&gt;<br>&gt; &lt;/frame&gt;<br>&gt;<br>&gt; .....<br>&gt;<br>&gt; Right now this is klunky because I&#39;m trying to convert the millisecond
<br>&gt; timestamp into frames per second.&nbsp;&nbsp;For example, if I want to run this<br>&gt; animation at 10fps, I know that the jpg captured at 100ms will appear in<br>&gt; frame 1 and so on (is that right??).&nbsp;&nbsp;So what happens in between each
<br>&gt; frame... if&nbsp;&nbsp;file1.jpg is captures at 10seconds before file2.jpg, I just<br>&gt; stick (10x10) 100 &lt;frame /&gt; tags as filler in between the two images.&nbsp;&nbsp;There<br>&gt; must be a better way than this.&nbsp;&nbsp;Also, since I&#39;m converting from
<br>&gt; milliseconds to frames per second... I think I&#39;m losing a lot of precision.<br>&gt;<br>&gt; How could I create this &quot;flipbook&quot; effect, given the inventory above using<br>&gt; swfmill simple?<br>&gt;
<br>&gt; I think this is a pretty interesting problem and I really wanted to thank<br>&gt; the creators of swfmill... it&#39;s a great solution to this type of thing.&nbsp;&nbsp;I<br>&gt; was orginally trying to create an AVI file from this series of jpg files,
<br>&gt; but it got way too complicated for me.<br>&gt;<br>&gt; Looking forward to some suggestions!!<br>&gt;<br>&gt; Seth<br><br>&gt; _______________________________________________<br>&gt; swfmill mailing list<br>&gt; <a href="mailto:swfmill@osflash.org">
swfmill@osflash.org</a><br>&gt; <a href="http://osflash.org/mailman/listinfo/swfmill_osflash.org">http://osflash.org/mailman/listinfo/swfmill_osflash.org</a><br><br><br>--<br>Jon Molesa<br><a href="mailto:rjmolesa@consoltec.net">
rjmolesa@consoltec.net</a><br><br>_______________________________________________<br>swfmill mailing list<br><a href="mailto:swfmill@osflash.org">swfmill@osflash.org</a><br><a href="http://osflash.org/mailman/listinfo/swfmill_osflash.org">
http://osflash.org/mailman/listinfo/swfmill_osflash.org</a><br></blockquote></div><br>