<?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>Smart-Page.net &#187; boids</title>
	<atom:link href="http://www.smart-page.net/blog/tag/boids/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.smart-page.net/blog</link>
	<description>C++ / C# / Py / Actionscript ... &#039;My God. It&#039;s full of stars!&#039;</description>
	<lastBuildDate>Thu, 23 Jun 2011 00:14:09 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Py4D Examples &#8211; particle party</title>
		<link>http://www.smart-page.net/blog/2010/04/10/py4d-examples-particle-party/</link>
		<comments>http://www.smart-page.net/blog/2010/04/10/py4d-examples-particle-party/#comments</comments>
		<pubDate>Sat, 10 Apr 2010 15:33:42 +0000</pubDate>
		<dc:creator>flashgordon</dc:creator>
				<category><![CDATA[3D]]></category>
		<category><![CDATA[General]]></category>
		<category><![CDATA[Python]]></category>
		<category><![CDATA[boids]]></category>
		<category><![CDATA[Particles]]></category>
		<category><![CDATA[Physics]]></category>
		<category><![CDATA[py4d]]></category>
		<category><![CDATA[Stars]]></category>
		<category><![CDATA[Strange Attractor]]></category>

		<guid isPermaLink="false">http://www.smart-page.net/blog/?p=964</guid>
		<description><![CDATA[<a href="http://www.smart-page.net/blog/2010/04/10/py4d-examples-particle-party/" title="Py4D Examples &#8211; particle party"><img src="http://www.smart-page.net/blog/wp-content/uploads/yapb_cache/py4d_title1.3t0udbr1iklkrowok0g4owsgc.h9fw4mcunmtegc04wgoo4wck.th.jpeg" width="200" height="150" alt="Py4D Examples &#8211; particle party" style="float:left;padding:0 10px 10px 0;" ></a>I haven´t written about Py4D for quite a while now&#8230; In the meantime, Maxon has first announced a cooperation with &#8211; and now the acquisition of Sebastian Rath´s praised python implementation for Cinema4D. So finally &#8211; Cinema4D meets Python! Let´s celebrate with some cool experiments! If you are new to this blog or Py4D &#8211; [...]]]></description>
			<content:encoded><![CDATA[<a href="http://www.smart-page.net/blog/2010/04/10/py4d-examples-particle-party/" title="Py4D Examples &#8211; particle party"><img src="http://www.smart-page.net/blog/wp-content/uploads/yapb_cache/py4d_title1.3t0udbr1iklkrowok0g4owsgc.h9fw4mcunmtegc04wgoo4wck.th.jpeg" width="200" height="150" alt="Py4D Examples &#8211; particle party" style="float:left;padding:0 10px 10px 0;" ></a><p>I haven´t written about <a href="http://www.py4d.com/" target="_blank">Py4D</a> for quite a while now&#8230;</p>
<p>In the meantime, <a href="http://www.maxon.net" target="_blank">Maxon</a> has first announced a cooperation with &#8211; and now the acquisition of Sebastian Rath´s praised python implementation for Cinema4D.</p>
<p>So finally &#8211; Cinema4D meets Python!</p>
<p><strong>Let´s celebrate with some cool experiments!</strong></p>
<p><strong><span id="more-964"></span><br />
</strong></p>
<p>If you are new to this blog or Py4D &#8211; a short introduction:</p>
<p>Py4D enhances C4D with a standard Python interpreter that provides access to the C4D SDK and allows to easily code platform indepentent scripts and plugins that control or extend C4D.</p>
<p>Basicly the same as COFFEE, C4D´s own scripting language, but Py4D has two major advantages:</p>
<ul>
<li> It follows the C++ SDK more closely and implements it further than COFFEE does.</li>
<li>It is a easy to pickup, widely known language with a huge community and tons of existing code and librarys.</li>
</ul>
<p><br/><br />
While C4D is a mighty tool in itself, this powerful scripting interface enables the user to work with external data, automate processes or build his own tools.</p>
<p>Being more the C++ type when it comes to plugin development and C4D, I enjoy being able to solve small problems just by hacking a few lines of code into the script manager.<br />
I also prototype most of my plugins in Py4D before I start developing in C++ &#8211; it´s just more convenient.<br />
The step of compiling for every test takes much more time in the long run.</p>
<p><br/></p>
<h3>So here´s the meat:</h3>
<p>Four simple examples how to have a good time with Py4D and some particles&#8230;</p>
<p><del datetime="2010-09-09T18:26:28+00:00">Everyone requires C4D R11.5, the Thinking Particles module and the actual version of Py4D.</del></p>
<p><strong><span style="color: #ff9900;">Update:</span></strong> <em>All files have been updated to work with the R12 version of Cinema 4D.</em></p>
<p>Py4D has been through some changes since the open beta started, so I took the time to update the scripts I published in the <a href="http://www.smart-page.net/blog/2009/08/07/py4d-boids/" target="_blank">boids</a>, and <a href="http://www.smart-page.net/blog/2009/09/15/strange-attractor-c4dpy4d-particle-bench/" target="_blank">strange attractor</a> posts and included them here.</p>
<p><em>Click the images for a preview.</em><br />
<br/></p>
<h3>1. Stars4Py4D</h3>
<p><a href="http://www.smart-page.net/as3d/sp_stars" target="_blank"><img class="size-full wp-image-965 alignnone" title="py4" src="http://www.smart-page.net/blog/wp-content/uploads/2010/04/py4.jpg" alt="" width="680" height="100" /></a></p>
<p>This is a Py4D port of the <a href="http://www.smart-page.net/blog/2010/04/03/cruising-the-cosmos-sagan-style-flash-in-outer-space/" target="_blank">Sagan experiment</a> I did in flash <- check out this link, it´s fun <img src='http://www.smart-page.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>A good and simple first step with particles - position vectors get parsed from a CVS <a href="http://www.astronexus.com/node/34" target="_blank">database</a> and from a galaxy of suns&#8230; “My God. It’s full of stars!”</p>
<p>Hint: <em>this example might be the best to start with, as it includes comments &#8211; the others don´t, because they use pretty much the same pattern. </em> </p>
<p>Just <a href="http://www.smart-page.net/python/Stars4Py.zip" target="_blank">download the package</a>, load the scene and change the path to the CSV file within the &#8220;file&#8221; user data field of the Py4D Tag.</p>
<p><br/></p>
<h3>2. Phy4D</h3>
<p><a href="http://www.vconverter.de/?file=py4d_simple_phy" target="_blank"><img class="alignnonesize-full wp-image-968" title="py2" src="http://www.smart-page.net/blog/wp-content/uploads/2010/04/py2.jpg" alt="" width="680" height="100" /></a></p>
<p>A very simple adaptation of a 2D &#8220;physic engine&#8221; &#8211; works only with spheres.<br />
The direction of gravitation is animated to make this a little more interesting.</p>
<p>Have a look at the <a href="http://www.vconverter.de/?file=py4d_simple_phy" target="_blank">preview video</a> and <a href="http://www.smart-page.net/python/Phy4Py.c4d">scene file</a>.</p>
<p><br/></p>
<h3>3. Boids</h3>
<p><a href="http://www.vconverter.de/?file=sp_boids" target="_blank"><img class="alignnonesize-full wp-image-970" title="py1" src="http://www.smart-page.net/blog/wp-content/uploads/2010/04/py1.jpg" alt="" width="680" height="100" /></a></p>
<p>This is simply a revival of the <a href="http://www.smart-page.net/blog/2009/08/07/py4d-boids/" target="_blank">Py4D Boids post</a> &#8211; same beast, but updated to the Py4D release version.<br />
The script creates a flocking boids swarm, that behaves according to the <a href="http://en.wikipedia.org/wiki/Boids" target="_blank">rules</a> outlined by Craig Reynolds.</p>
<p>Checkout <a href="http://www.vconverter.de/?file=sp_boids" target="_blank">this video</a> from Sebastian and get the <a href="http://www.smart-page.net/python/Boids4Py.c4d">scenefile</a>.</p>
<p><br/></p>
<h3>4. Strange Attractor</h3>
<p><a href="http://www.vconverter.de/?file=strangeattractor" target="_blank"><img class="alignnonesize-full wp-image-969" title="py3" src="http://www.smart-page.net/blog/wp-content/uploads/2010/04/py3.jpg" alt="" width="680" height="100" /></a></p>
<p>Again just the script from the original strange attractor post, but ported to the final SDK.<br />
View the <a href="http://www.vconverter.de/?file=strangeattractor" target="_blank">final rendering</a> and the <a href="http://www.smart-page.net/blog/2009/09/15/strange-attractor-c4dpy4d-particle-bench/" target="_blank">original post</a> &#8211; you can use the <a href="http://www.smart-page.net/as3/sp_safinder/" target="_blank">Strange Attractor Finder</a> to locate your very own, chaotic attractor!</p>
<p>Here´s the <a href="http://www.smart-page.net/py4d/SA4Py4D.c4d">scene file</a>.</p>
<p><br/></p>
<h3>Conclusion</h3>
<p>Python and Cinema4D are a great team and Py4D is THE alternative to COFFEE.</p>
<p>I hope this gives everybody who is interested in Py4D and controlling particles, a small head start, some inspiration or at least something fun to play with <img src='http://www.smart-page.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /><br />
<br/><br />
Thanks to Sebastian for suggestions, support &#8211; and of course Py4D.</p>
<p><br/><br />
Cheers!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.smart-page.net/blog/2010/04/10/py4d-examples-particle-party/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>PY4D Boids</title>
		<link>http://www.smart-page.net/blog/2009/08/07/py4d-boids/</link>
		<comments>http://www.smart-page.net/blog/2009/08/07/py4d-boids/#comments</comments>
		<pubDate>Fri, 07 Aug 2009 17:17:02 +0000</pubDate>
		<dc:creator>flashgordon</dc:creator>
				<category><![CDATA[3D]]></category>
		<category><![CDATA[C++]]></category>
		<category><![CDATA[General]]></category>
		<category><![CDATA[Python]]></category>
		<category><![CDATA[boids]]></category>
		<category><![CDATA[cinema 4D]]></category>
		<category><![CDATA[flocking]]></category>
		<category><![CDATA[py4d]]></category>

		<guid isPermaLink="false">http://www.smart-page.net/blog/?p=309</guid>
		<description><![CDATA[<a href="http://www.smart-page.net/blog/2009/08/07/py4d-boids/" title="PY4D Boids"><img src="http://www.smart-page.net/blog/wp-content/plugins/yet-another-photoblog/YapbThumbnailer.php?post_id=309&amp;w=200&amp;h=150&amp;zc=1" width="200" height="150" alt="PY4D Boids" style="float:left;padding:0 10px 10px 0;" ></a>Sebastian Rath´s PY4D is a new, alternative way to script with or to code plugins for Cinema4D &#8211; without COFFE or C++ &#8211; but in Python. The current beta (v0.9.0001) already makes a fine impression and proves itself easy to get started with. This video shows a little script that was adapted in a twinkling [...]]]></description>
			<content:encoded><![CDATA[<a href="http://www.smart-page.net/blog/2009/08/07/py4d-boids/" title="PY4D Boids"><img src="http://www.smart-page.net/blog/wp-content/plugins/yet-another-photoblog/YapbThumbnailer.php?post_id=309&amp;w=200&amp;h=150&amp;zc=1" width="200" height="150" alt="PY4D Boids" style="float:left;padding:0 10px 10px 0;" ></a><p>Sebastian Rath´s <a href="http://py4d.xpresso24.com" target="_blank">PY4D</a> is a new, alternative way to script with or to code plugins for Cinema4D &#8211; without COFFE or C++ &#8211; but in Python.</p>
<p>The current beta (v0.9.0001) already makes a fine impression and proves itself easy to get started with.</p>
<p><b><a href="http://www.vconverter.de/?file=fishboids" target="_blank">This video</a></b> shows a little script that was adapted in a twinkling and controls the particles of a TP-Storm to behave after the three flocking boids rules.<a href="http://www.py4d.com/2009/08/there-comming/" target="_blank"><br />
Don</a> has rendered a <b><a href="http://www.vconverter.de/?file=tunaboids" target="_blank">much prettyer version</a></b> of the dummy above.</p>
<p>You can download the C4D-scene <a href="http://www.smart-page.net/python/Boids4Py.c4d">here</a>.</p>
<p><strong><span style="color: #ff9900;">Update:</span></strong> <em>The file has been updated to work with the R12 version of Cinema 4D.</em></p>
]]></content:encoded>
			<wfw:commentRss>http://www.smart-page.net/blog/2009/08/07/py4d-boids/feed/</wfw:commentRss>
		<slash:comments>16</slash:comments>
		</item>
	</channel>
</rss>

