<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>rockabit &#187; programming</title>
	<atom:link href="http://www.rockabit.com/category/programming/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.rockabit.com</link>
	<description>personal blog and portfolio website</description>
	<lastBuildDate>Tue, 22 Jun 2010 17:11:01 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.6</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Lightning in OpenFrameworks</title>
		<link>http://www.rockabit.com/2010/06/16/lightning-in-openframeworks/</link>
		<comments>http://www.rockabit.com/2010/06/16/lightning-in-openframeworks/#comments</comments>
		<pubDate>Wed, 16 Jun 2010 10:02:37 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[OpenFrameworks]]></category>
		<category><![CDATA[art & technology]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.rockabit.com/?p=199</guid>
		<description><![CDATA[Yesterday, I ported my AS3 lightning renderer to OpenFrameworks with the help of Rick Companje and Joris Rotteveel.
Edit: download the source at the OpenFrameworks forum
Check out the video:

OpenFrameworks lightning renderer from Ralph Kok on Vimeo.
]]></description>
			<content:encoded><![CDATA[<p>Yesterday, I ported my AS3 lightning renderer to OpenFrameworks with the help of <a href="http://companje.nl/" target="_blank">Rick Companje</a> and <a href="http://www.jorisrotteveel.nl/" target="_blank">Joris Rotteveel</a>.</p>
<p>Edit: download the source at the <a href="http://www.openframeworks.cc/forum/viewtopic.php?f=12&#038;t=4132">OpenFrameworks forum</a></p>
<p>Check out the video:</p>
<p><object width="400" height="300"><param name="allowfullscreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="movie" value="http://vimeo.com/moogaloop.swf?clip_id=12609483&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=&amp;fullscreen=1" /><embed src="http://vimeo.com/moogaloop.swf?clip_id=12609483&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=&amp;fullscreen=1" type="application/x-shockwave-flash" allowfullscreen="true" allowscriptaccess="always" width="400" height="300"></embed></object>
<p><a href="http://vimeo.com/12609483">OpenFrameworks lightning renderer</a> from <a href="http://vimeo.com/user4061354">Ralph Kok</a> on <a href="http://vimeo.com">Vimeo</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.rockabit.com/2010/06/16/lightning-in-openframeworks/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Iris getting somewhere</title>
		<link>http://www.rockabit.com/2009/12/28/iris-getting-somewhere/</link>
		<comments>http://www.rockabit.com/2009/12/28/iris-getting-somewhere/#comments</comments>
		<pubDate>Mon, 28 Dec 2009 21:10:40 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[art & technology]]></category>
		<category><![CDATA[generative art]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.rockabit.com/?p=194</guid>
		<description><![CDATA[My most recent iris rendering:

]]></description>
			<content:encoded><![CDATA[<p>My most recent iris rendering:</p>
<p><a href="http://www.rockabit.com/wp-content/uploads/2009/12/iris_v6_2.jpg"><img class="alignnone size-medium wp-image-197" title="iris_v6_2" src="http://www.rockabit.com/wp-content/uploads/2009/12/iris_v6_2-300x300.jpg" alt="iris_v6_2" width="300" height="300" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.rockabit.com/2009/12/28/iris-getting-somewhere/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>An iris is a beautiful thing</title>
		<link>http://www.rockabit.com/2009/12/19/an-iris-is-a-beautiful-thing/</link>
		<comments>http://www.rockabit.com/2009/12/19/an-iris-is-a-beautiful-thing/#comments</comments>
		<pubDate>Sat, 19 Dec 2009 15:05:01 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[art & technology]]></category>
		<category><![CDATA[generative art]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.rockabit.com/?p=187</guid>
		<description><![CDATA[For a while now I have wanted to render out an iris in code alone, so I have now finally started experimenting in that direction.
I must say I am not unhappy with the results sofar, especially since I have stumbled onto some nice byproducts along the way  
   
]]></description>
			<content:encoded><![CDATA[<p>For a while now I have wanted to render out an iris in code alone, so I have now finally started experimenting in that direction.</p>
<p>I must say I am not unhappy with the results sofar, especially since I have stumbled onto some nice byproducts along the way <img src='http://www.rockabit.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p><a href="http://www.rockabit.com/wp-content/uploads/2009/12/iris_render_v1.jpg"><img class="alignnone size-thumbnail wp-image-189" title="iris_render_v1" src="http://www.rockabit.com/wp-content/uploads/2009/12/iris_render_v1-150x150.jpg" alt="iris_render_v1" width="150" height="150" /></a> <a href="http://www.rockabit.com/wp-content/uploads/2009/12/iris_render_v2.jpg"><img class="alignnone size-thumbnail wp-image-190" title="iris_render_v2" src="http://www.rockabit.com/wp-content/uploads/2009/12/iris_render_v2-150x150.jpg" alt="iris_render_v2" width="150" height="150" /></a> <a href="http://www.rockabit.com/wp-content/uploads/2009/12/iris_render_byproduct.png"><img class="alignnone size-thumbnail wp-image-188" title="iris_render_byproduct" src="http://www.rockabit.com/wp-content/uploads/2009/12/iris_render_byproduct-150x150.png" alt="iris_render_byproduct" width="150" height="150" /></a> <a href="http://www.rockabit.com/wp-content/uploads/2009/12/iris_research_sidestep.jpg"><img class="alignnone size-thumbnail wp-image-191" title="iris_research_sidestep" src="http://www.rockabit.com/wp-content/uploads/2009/12/iris_research_sidestep-150x150.jpg" alt="iris_research_sidestep" width="150" height="150" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.rockabit.com/2009/12/19/an-iris-is-a-beautiful-thing/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>I love particles</title>
		<link>http://www.rockabit.com/2009/12/19/i-love-particles/</link>
		<comments>http://www.rockabit.com/2009/12/19/i-love-particles/#comments</comments>
		<pubDate>Sat, 19 Dec 2009 11:17:51 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[art & technology]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.rockabit.com/?p=178</guid>
		<description><![CDATA[This little diddy was inspired by Ralph Hauert&#8217;s beautiful Bloom animation.
Try moving your mouse and clicking every once in a while  

]]></description>
			<content:encoded><![CDATA[<p>This little diddy was inspired by <a title="Unit Zero One" href="http://www.unitzeroone.com" target="_blank">Ralph Hauert</a>&#8217;s beautiful <a href="http://www.letitbloom.com/#ralph" target="_blank">Bloom animation</a>.</p>
<p>Try moving your mouse and clicking every once in a while <img src='http://www.rockabit.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p><a href="http://www.rockabit.com/uploads/AttractionToMouse.html" target="_blank"><img class="alignnone size-medium wp-image-182" title="attraction" src="http://www.rockabit.com/wp-content/uploads/2009/12/attraction-300x187.png" alt="attraction" width="300" height="187" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.rockabit.com/2009/12/19/i-love-particles/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>L-systems revisited</title>
		<link>http://www.rockabit.com/2009/11/16/l-systems-revisited/</link>
		<comments>http://www.rockabit.com/2009/11/16/l-systems-revisited/#comments</comments>
		<pubDate>Mon, 16 Nov 2009 17:10:13 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[art & technology]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.rockabit.com/?p=168</guid>
		<description><![CDATA[I sat down again to update my ActionScript L-system renderer so that it can use multiple rules and new characters.
Next, I fiddled around a bit with axioms, rules and angles and came up with some pretty cool new curves (if I may say so myself). Check them out below.
I&#8217;ve also added the renderer application, if [...]]]></description>
			<content:encoded><![CDATA[<p>I sat down again to update my ActionScript L-system renderer so that it can use multiple rules and new characters.</p>
<p>Next, I fiddled around a bit with axioms, rules and angles and came up with some pretty cool new curves (if I may say so myself). Check them out below.<br />
I&#8217;ve also added the renderer application, if you run it you can play around with the curves (controls are listed at the bottom of the app). If it is too slow, please decrease the number of iterations or resize the window to be smaller.</p>
<p><span id="more-168"></span></p>
<p><a href="http://www.rockabit.com/wp-content/uploads/2009/11/lsystem_custom_plant.png" target="_blank"><img class="alignnone size-thumbnail wp-image-164" title="custom lsystem: plant" src="http://www.rockabit.com/wp-content/uploads/2009/11/lsystem_custom_plant-150x150.png" alt="" width="150" height="150" /></a> <a href="http://www.rockabit.com/wp-content/uploads/2009/11/lsystem_clouds.png" target="_blank"><img class="alignnone size-thumbnail wp-image-162" title="custom lsystem: clouds" src="http://www.rockabit.com/wp-content/uploads/2009/11/lsystem_clouds-150x150.png" alt="" width="150" height="150" /></a> <a href="http://www.rockabit.com/wp-content/uploads/2009/11/lsystem_square_fractal.png" target="_blank"><img class="alignnone size-thumbnail wp-image-166" title="custom lsystem: square fractal" src="http://www.rockabit.com/wp-content/uploads/2009/11/lsystem_square_fractal-150x150.png" alt="" width="150" height="150" /></a></p>
<p><a href="http://www.rockabit.com/wp-content/uploads/2009/11/lsystem_folding_curve.png" target="_blank"><img class="alignnone size-thumbnail wp-image-165" title="custom lsystem: folding curve" src="http://www.rockabit.com/wp-content/uploads/2009/11/lsystem_folding_curve-150x150.png" alt="" width="150" height="150" /></a> <a href="http://www.rockabit.com/wp-content/uploads/2009/11/lsystem_custom_dragon.png" target="_blank"><img class="alignnone size-thumbnail wp-image-163" title="custom lsystem: dragon" src="http://www.rockabit.com/wp-content/uploads/2009/11/lsystem_custom_dragon-150x150.png" alt="" width="150" height="150" /></a></p>
<p><object type="application/x-shockwave-flash" data="http://www.rockabit.com/wp-content/uploads/2009/11/lsystemcreator.swf" width="425" height="355" class="embedflash"><param name="movie" value="http://www.rockabit.com/wp-content/uploads/2009/11/lsystemcreator.swf" /><param name="allowfullscreen" value="true" /><param name="allowscriptaccess" value="always" /><small>(Please open the article to see the flash file or player.)</small></object></p>
<p>(<a href="http://www.rockabit.com/wp-content/uploads/2009/11/lsystemcreator.swf" target="_blank">full sized flash movie</a>)</p>
]]></content:encoded>
			<wfw:commentRss>http://www.rockabit.com/2009/11/16/l-systems-revisited/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Drawing roots</title>
		<link>http://www.rockabit.com/2009/09/01/drawing-roots/</link>
		<comments>http://www.rockabit.com/2009/09/01/drawing-roots/#comments</comments>
		<pubDate>Tue, 01 Sep 2009 08:12:52 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.rockabit.com/?p=157</guid>
		<description><![CDATA[If you&#8217;ve ever felt the urge to draw plant roots, now&#8217;s your chance!
]]></description>
			<content:encoded><![CDATA[<p>If you&#8217;ve ever felt the urge to draw plant roots, <a href="http://www.rockabit.com/wp-content/uploads/2009/09/treetest.swf" target="_blank">now&#8217;s your chance</a>!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.rockabit.com/2009/09/01/drawing-roots/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Placebo Interactive Video</title>
		<link>http://www.rockabit.com/2009/08/28/placebo-interactive-video/</link>
		<comments>http://www.rockabit.com/2009/08/28/placebo-interactive-video/#comments</comments>
		<pubDate>Fri, 28 Aug 2009 07:46:15 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[game design]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://www.rockabit.com/?p=154</guid>
		<description><![CDATA[Placebo has released a new single called &#8220;The Never-Ending Why&#8221;, which is accompanied by a fantastic music video, created by Champagne Valentine.
We at Random were asked to help in the creation of an interactive video to go alongside the linear video.
After a lot of hard work, the result turned out, if we may say so [...]]]></description>
			<content:encoded><![CDATA[<p>Placebo has released a new single called &#8220;The Never-Ending Why&#8221;, which is accompanied by a fantastic music video, created by <a href="http://www.champagnevalentine.com/" target="_blank">Champagne Valentine</a>.</p>
<p>We at <a href="http://www.random.nu" target="_blank">Random</a> were asked to help in the creation of an interactive video to go alongside the linear video.</p>
<p>After a lot of hard work, the result turned out, if we may say so ourselves, amazingly cool!</p>
<p>Check out the linear video <a href="http://www.vimeo.com/6159370" target="_blank">here</a>, and try the interactive <a href="http://theneverendingwhy.placeboworld.co.uk/" target="_blank">here</a>.</p>
<p><a href="http://theneverendingwhy.placeboworld.co.uk/"><img class="alignnone size-full wp-image-155" title="neverendingwhy_interactive" src="http://www.rockabit.com/wp-content/uploads/2009/08/placebo_new.png" alt="" width="300" height="196" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.rockabit.com/2009/08/28/placebo-interactive-video/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Lightning in AS3</title>
		<link>http://www.rockabit.com/2009/07/30/lightning-in-as3/</link>
		<comments>http://www.rockabit.com/2009/07/30/lightning-in-as3/#comments</comments>
		<pubDate>Thu, 30 Jul 2009 15:39:23 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.rockabit.com/?p=146</guid>
		<description><![CDATA[I&#8217;ve been wanting to do this for a while, but never got around to figuring out how. Until now.
With the help of this post I created a simple but very effective random lightning generator in ActionScript 3.
I was surprised at the simplicity of it, and the clear explanation on drilian.com helped a lot.
So here it [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been wanting to do this for a while, but never got around to figuring out how. Until now.</p>
<p>With the help of <a href="http://drilian.com/2009/02/25/lightning-bolts/" target="_blank">this post</a> I created a simple but very effective random lightning generator in ActionScript 3.</p>
<p>I was surprised at the simplicity of it, and the clear explanation on <a href="http://drilian.com" target="_blank">drilian.com</a> helped a lot.</p>
<p>So here it is: the <a href="http://www.rockabit.com/wp-content/uploads/2009/07/lightningtest1.swf" target="_blank">lightning generator</a>.</p>
<p>EDIT: per request I&#8217;ve put the source files online. <a href="http://www.rockabit.com/wp-content/uploads/2009/07/lightning.zip" target="_blank">Download here</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.rockabit.com/2009/07/30/lightning-in-as3/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>L-system animation</title>
		<link>http://www.rockabit.com/2009/07/30/l-system-animation/</link>
		<comments>http://www.rockabit.com/2009/07/30/l-system-animation/#comments</comments>
		<pubDate>Thu, 30 Jul 2009 15:29:34 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[generative art]]></category>
		<category><![CDATA[l-systems]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.rockabit.com/?p=142</guid>
		<description><![CDATA[A long while ago I wrote a small Flex application to draw L-systems (post).
With this app I noticed how cool it is to play around with drawing angles by moving the slider (post #2).
But somehow, I never thought of adding a play button to the slider so it plays it as an animation.
So now I [...]]]></description>
			<content:encoded><![CDATA[<p>A long while ago I wrote a small Flex application to draw L-systems (<a href="http://www.rockabit.com/2007/07/09/l-systems-in-flex/" target="_blank">post</a>).<br />
With this app I noticed how cool it is to play around with drawing angles by moving the slider (<a href="http://www.rockabit.com/2007/07/11/fractal-spirograph/" target="_blank">post #2</a>).</p>
<p>But somehow, I never thought of adding a play button to the slider so it plays it as an animation.<br />
So now I did. Well, no play button, but just an animation. Here it is. Please enjoy.</p>
<p><a href="http://www.rockabit.com/wp-content/uploads/2009/07/lsystem.swf" target="_blank">lsystem animator</a></p>
<p>Note: after clicking once, you can use the + and &#8211; keys to speed it up or slow it down<a href="http://www.rockabit.com/wp-content/uploads/2009/07/lsystem.swf" target="_blank"></a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.rockabit.com/2009/07/30/l-system-animation/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>stage scaleMode and stage size problems in Firefox</title>
		<link>http://www.rockabit.com/2009/03/19/stage-scalemode-and-stage-size-problems-in-firefox/</link>
		<comments>http://www.rockabit.com/2009/03/19/stage-scalemode-and-stage-size-problems-in-firefox/#comments</comments>
		<pubDate>Thu, 19 Mar 2009 10:13:52 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://www.rockabit.com/?p=137</guid>
		<description><![CDATA[Have you ever had the problem that, when opening the HTML that displays your Flash movie in the browser, all the stuff that is on stage i not positioned correctly?
I have. I encountered this problem with Firefox, when I noticed that objects were not centered on stage while this was the case when I ran [...]]]></description>
			<content:encoded><![CDATA[<p>Have you ever had the problem that, when opening the HTML that displays your Flash movie in the browser, all the stuff that is on stage i not positioned correctly?</p>
<p>I have. I encountered this problem with Firefox, when I noticed that objects were not centered on stage while this was the case when I ran the swf standalone or in Safari.</p>
<p>I managed to isolate the problem, and it turned out that what caused it was setting stage.scaleMode to StageScaleMode.NO_SCALE. After doing that, the stageWidth and stageHeight property values changed to zero.<br />
It turned out that this could be solved by not implementing swfobject, but I didn&#8217;t want that, so I found a workaround in AS3.</p>
<p>To hack around this problem, I check the stageWidth and stageHeight values to see if either equals 0, and if so, I register a resize event listener, because I found that although the values become zero in Firefox, a resize event is also immediately dispatched after this. So setting a listener for this event and initializing the application inside the handler method solved my problem! Of course, you also want to trigger the handler manually in case there&#8217;s no bug, so I just call it directly if neither stageWidth or stageHeight equals 0.</p>
<p>Simple, huh? I know it&#8217;s a hack and I&#8217;d rather not need it, but at least my application behaves like I want it to now <img src='http://www.rockabit.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Here&#8217;s the code:</p>
<p>public function Application()<br />
{<br />
&nbsp;&nbsp;&nbsp;&nbsp;stage.align = StageAlign.TOP_LEFT;<br />
&nbsp;&nbsp;&nbsp;&nbsp;stage.scaleMode = StageScaleMode.NO_SCALE;<br />
&nbsp;&nbsp;&nbsp;&nbsp;if (stage.stageWidth == 0 || stage.stageHeight == 0)<br />
&nbsp;&nbsp;&nbsp;&nbsp;{<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;stage.addEventListener(Event.RESIZE, handleStageResize);<br />
&nbsp;&nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;&nbsp;else<br />
&nbsp;&nbsp;&nbsp;&nbsp;{<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;handleStageResize();<br />
&nbsp;&nbsp;&nbsp;&nbsp;}<br />
}</p>
<p>private function handleStageResize(event : Event = null) : void<br />
{<br />
&nbsp;&nbsp;&nbsp;&nbsp;stage.removeEventListener(Event.RESIZE, handleStageResize);<br />
&nbsp;&nbsp;&nbsp;&nbsp;// initialize application here<br />
}</p>
]]></content:encoded>
			<wfw:commentRss>http://www.rockabit.com/2009/03/19/stage-scalemode-and-stage-size-problems-in-firefox/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
