<?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>Zachernuk.com &#187; Uncategorized</title>
	<atom:link href="http://www.zachernuk.com/category/uncategorized/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.zachernuk.com</link>
	<description>The desk of Brandel Zachernuk</description>
	<lastBuildDate>Tue, 27 Jul 2010 01:39:26 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Yes Unity can (do lots of particles)</title>
		<link>http://www.zachernuk.com/2010/05/11/yes-unity-can-do-lots-of-particles/</link>
		<comments>http://www.zachernuk.com/2010/05/11/yes-unity-can-do-lots-of-particles/#comments</comments>
		<pubDate>Tue, 11 May 2010 11:03:00 +0000</pubDate>
		<dc:creator>Brandel Zachernuk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[3d]]></category>
		<category><![CDATA[algorithmic]]></category>
		<category><![CDATA[face]]></category>
		<category><![CDATA[generative]]></category>
		<category><![CDATA[obama]]></category>
		<category><![CDATA[particles]]></category>
		<category><![CDATA[unity]]></category>
		<category><![CDATA[unity3d]]></category>

		<guid isPermaLink="false">http://www.zachernuk.com/?p=443</guid>
		<description><![CDATA[I was just looking into Unity&#8217;s 2D features &#8211; after having to build a line draw function myself I was wondering what I could get for free, and this is one of them! If you leave it running for a while you will see a hidden pattern in the particles.  Also, &#8216;reset&#8217; will just [...]]]></description>
			<content:encoded><![CDATA[<p>I was just looking into Unity&#8217;s 2D features &#8211; after having to build a line draw function myself I was wondering what I could get for free, and this is one of them! If you leave it running for a while you will see a hidden pattern in the particles.  Also, &#8216;reset&#8217; will just reset the position of the particles&#8230; try it after you have a few thousand &#8211; it looks cool!</p>
<p><em>Please view the full post to see the Unity content.</em></p>
]]></content:encoded>
			<wfw:commentRss>http://www.zachernuk.com/2010/05/11/yes-unity-can-do-lots-of-particles/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Dabbling in Java 3D</title>
		<link>http://www.zachernuk.com/2010/04/10/dabbling-in-java-3d/</link>
		<comments>http://www.zachernuk.com/2010/04/10/dabbling-in-java-3d/#comments</comments>
		<pubDate>Sat, 10 Apr 2010 04:13:44 +0000</pubDate>
		<dc:creator>Brandel Zachernuk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[3d]]></category>
		<category><![CDATA[anemone]]></category>
		<category><![CDATA[animation]]></category>
		<category><![CDATA[generative]]></category>
		<category><![CDATA[j3d]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[java3d]]></category>
		<category><![CDATA[jogl]]></category>
		<category><![CDATA[procedural]]></category>

		<guid isPermaLink="false">http://www.zachernuk.com/?p=413</guid>
		<description><![CDATA[I have been using Actionscript for a long time now.  In order to break out of that, I have started to play around with some slightly more &#8216;direct&#8217; languages &#8211; while Java is by no means a &#8216;low level&#8217; language, I thought it would be worth making baby steps down from the convenient-but-inefficient heights [...]]]></description>
			<content:encoded><![CDATA[<p>I have been using Actionscript for a long time now.  In order to break out of that, I have started to play around with some slightly more &#8216;direct&#8217; languages &#8211; while Java is by no means a &#8216;low level&#8217; language, I thought it would be worth making baby steps down from the convenient-but-inefficient heights of Flash down to the powerful-but-fiddly directness of C/C++.  Towards that end, I have been reading through the tutorials for <a href="http://java.sun.com/developer/onlineTraining/java3d/index.html">the Java 3D API tutorial</a>, and despite being pretty obtuse at the outset, it gets fun pretty quickly.</p>
<p>I believe this could just as easily been produced in <a href="http://www.processing.org">processing</a> but I find the lack of assistance from the IDE to be too frustrating to manage.  On the other hand, though, processing / Java is apparently very similar to the kind of instruction set that can be compiled on to <a href="http://www.sparkfun.com/commerce/categories.php?c=103">arduino </a>micro-controllers.  Hopefully more on that later! In the meantime, here is a video of my anemone:<br />
<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="480" height="385" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="allowFullScreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://www.youtube.com/v/CXwi74uz1T8&amp;hl=en_GB&amp;fs=1&amp;" /><param name="allowfullscreen" value="true" /><embed type="application/x-shockwave-flash" width="480" height="385" src="http://www.youtube.com/v/CXwi74uz1T8&amp;hl=en_GB&amp;fs=1&amp;" allowscriptaccess="always" allowfullscreen="true"></embed></object></p>
<p>Note: the jitter is from the capture process &#8211; I am using <a href="http://camstudio.org/">CamStudio </a>to grab the footage, which requires a little more of the system than Java wants to give up.  If you want to <a href="https://java3d.dev.java.net/binary-builds.html">install Java3D</a>, you can <a href="http://www.zachernuk.com/wp-content/2010/04/">view the Applet</a> at a much higher resolution.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.zachernuk.com/2010/04/10/dabbling-in-java-3d/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Freaky awesome 3d camera-projection</title>
		<link>http://www.zachernuk.com/2009/11/12/freaky-awesome-3d-camera-projection/</link>
		<comments>http://www.zachernuk.com/2009/11/12/freaky-awesome-3d-camera-projection/#comments</comments>
		<pubDate>Wed, 11 Nov 2009 20:24:55 +0000</pubDate>
		<dc:creator>Brandel Zachernuk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.zachernuk.com/?p=328</guid>
		<description><![CDATA[After promising myself I would go to bed early tonight, I got sidetracked looking through Mr Doob&#8217; s excellent flash experimentations.  Some of which involve camera input, some involving Pv3d.  A few involve both!  I have only very recently begun to dabble in camera input, but I have some experience with pv3d,  so I decided [...]]]></description>
			<content:encoded><![CDATA[<p>After promising myself I would go to bed early tonight, I got sidetracked looking through <a href="http://mrdoob.com/">Mr Doob&#8217; </a>s excellent flash experimentations.  Some of which involve camera input, some involving Pv3d.  A few involve both!  I have only very recently begun to dabble in camera input, but I have some experience with pv3d,  so I decided to have a quick go &#8211; making a relief map out of the greyscale pixel values of the camera feed.</p>
<p><a href="http://www.zachernuk.com/wp-content/2009/11/meshcam.jpg"><img class="alignnone size-medium wp-image-329" title="meshcam" src="http://www.zachernuk.com/wp-content/2009/11/meshcam-300x260.jpg" alt="meshcam" width="300" height="260" /></a></p>
<p>One thing I hadn&#8217;t thought of was the fact that, on a laptop with a monitor-fixed webcam, in a room where the monitor is the only light,  The relief map does a reasonable job of being a depth map!  The luminance might map to the square of the height or something but you can see from the image above how well it works.</p>
<p>You can try it for yourself if you like &#8211; Note the usual applies with the webcam&#8230; If you can see what it&#8217;s like in a darkened room, do try it! I&#8217;d love to see what other people come up with!</p>
<p>(mouse controls rotation, buttons toggle params &#8211; try the relief map with the original bitmap laid on top for freaky 3d-ness!)</p>

<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
			id="fm_meshcam_963872533"
			class="flashmovie"
			width="800"
			height="600">
	<param name="movie" value="http://www.zachernuk.com/wp-content/2009/11/meshcam.swf" />
	<!--[if !IE]>-->
	<object	type="application/x-shockwave-flash"
			data="http://www.zachernuk.com/wp-content/2009/11/meshcam.swf"
			name="fm_meshcam_963872533"
			width="800"
			height="600">
	<!--<![endif]-->
		<a href="http://adobe.com/go/getflashplayer"><img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" /></a></p>

	<!--[if !IE]>-->
	</object>
	<!--<![endif]-->
</object>
<p><strong>Update 2009-12-26<br />
</strong><br />
It is possible to make a 3d depth map in realtime, although there are a couple of hurdles to jump through. Even on a reasonable computer, the highest poly count you can expect out of Flash at present is about 5,000 triangles, so the resolution of the mesh used in this Flash experiment is 64 x 48.</p>
<p>If you were to do the same thing in a language that gave you access to DirectX or openGL you can expect to have poly counts in the millions, so one vertex per pixel is an easily achievable goal.</p>
<p>The next part is more complicated:  Getting a color channel to look like a depth channel.  The experiment above is using the red channel as the depth map.  This will yield a real depth map, but only under these two conditions:</p>
<p>1.  The light must originate from (close to) the camera.  That way, the brighter a point is, the closer to the camera it is. For objects that are reasonably distant &#8211; say, 50 cm away, it is sufficient for the light to be within 5cm, but the closer the lights are, the better.  You can buy some webcams with a built-in ring of LEDs &#8211; these are ideal.</p>
<p>2.  All the objects must exhibit <a href="http://en.wikipedia.org/wiki/Diffuse_reflection">Diffuse </a>/ <a href="http://en.wikipedia.org/wiki/Lambertian_reflectance">Lambertian </a>luminance.  Not as complicated as it sounds:  Basically, when an object has a mirrored or a shiny surface, its brightness depends on both how it is lit <em>and</em> the camera position (where you are looking at it.)  When you change your point of view, you change the brightness of the surface.  There are commercially-available Lambert materials like <a href="http://www.labsphere.com/productdetail.aspx?id=329">Spectralon</a>, but an unfired white clay will do just as well.  In fact, you could probably dust an object in any white powder &#8211; something like flour or baking soda,  light it under the right conditions and see what it looks like.</p>
<p>If anyone tries this I would love to see the results!  Under the two conditions above,  you should be able to use my mesh experiment above to make  meshes that show depth.  If you&#8217;re interested in some of the lower-level stuff in this subject, it&#8217;s part of <strong>Computer Vision, </strong>specifically<strong> Shape from Shading. </strong>As with any vision project, the best port-of-call is the <a href="http://opencv.willowgarage.com/wiki/">openC</a>V project.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.zachernuk.com/2009/11/12/freaky-awesome-3d-camera-projection/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Buffer Snake</title>
		<link>http://www.zachernuk.com/2009/11/11/buffer-snake/</link>
		<comments>http://www.zachernuk.com/2009/11/11/buffer-snake/#comments</comments>
		<pubDate>Tue, 10 Nov 2009 19:04:57 +0000</pubDate>
		<dc:creator>Brandel Zachernuk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.zachernuk.com/?p=323</guid>
		<description><![CDATA[The Fanciest version of snake you&#8217;ll play today.  It has a winning ending, my best time is 160 seconds.   How fast can you do it?
Click in the panel to get focus, then use left and right to steer your accumulation buffer-derived snake to victory.  Good luck!

<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
			id="fm_BufferSnake2_566948605"
			class="flashmovie"
			width="800"
			height="600">
	<param name="movie" value="http://www.zachernuk.com/wp-content/2009/11/BufferSnake2.swf" />
	<!--[if !IE]>-->
	<object	type="application/x-shockwave-flash"
			data="http://www.zachernuk.com/wp-content/2009/11/BufferSnake2.swf"
			name="fm_BufferSnake2_566948605"
			width="800"
			height="600">
	<!--<![endif]-->
		


	<!--[if !IE]>-->
	</object>
	<!--<![endif]-->
</object>
]]></description>
			<content:encoded><![CDATA[<p>The Fanciest version of snake you&#8217;ll play today.  It has a winning ending, my best time is 160 seconds.   How fast can you do it?</p>
<p>Click in the panel to get focus, then use left and right to steer your accumulation buffer-derived snake to victory.  Good luck!</p>

<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
			id="fm_BufferSnake2_1508154447"
			class="flashmovie"
			width="800"
			height="600">
	<param name="movie" value="http://www.zachernuk.com/wp-content/2009/11/BufferSnake2.swf" />
	<!--[if !IE]>-->
	<object	type="application/x-shockwave-flash"
			data="http://www.zachernuk.com/wp-content/2009/11/BufferSnake2.swf"
			name="fm_BufferSnake2_1508154447"
			width="800"
			height="600">
	<!--<![endif]-->
		
<p><a href="http://adobe.com/go/getflashplayer"><img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" /></a></p>

	<!--[if !IE]>-->
	</object>
	<!--<![endif]-->
</object>
]]></content:encoded>
			<wfw:commentRss>http://www.zachernuk.com/2009/11/11/buffer-snake/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Evident Utensil-inspired experiments</title>
		<link>http://www.zachernuk.com/2009/11/05/evident-utensil-experiment/</link>
		<comments>http://www.zachernuk.com/2009/11/05/evident-utensil-experiment/#comments</comments>
		<pubDate>Thu, 05 Nov 2009 07:33:49 +0000</pubDate>
		<dc:creator>Brandel Zachernuk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.zachernuk.com/?p=307</guid>
		<description><![CDATA[Still working ridiculous hours at the moment so I haven&#8217;t had much time for consideration, but I just wanted to share this somewhere people will see it.
(you need a webcam to make it work)
I partied to this all night.

<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
			id="fm_Displacer_1289263087"
			class="flashmovie"
			width="640"
			height="480">
	<param name="movie" value="http://www.zachernuk.com/wp-content/2009/11/Displacer.swf" />
	<!--[if !IE]>-->
	<object	type="application/x-shockwave-flash"
			data="http://www.zachernuk.com/wp-content/2009/11/Displacer.swf"
			name="fm_Displacer_1289263087"
			width="640"
			height="480">
	<!--<![endif]-->
		

	<!--[if !IE]>-->
	</object>
	<!--<![endif]-->
</object>
]]></description>
			<content:encoded><![CDATA[<p>Still working ridiculous hours at the moment so I haven&#8217;t had much time for consideration, but I just wanted to share this somewhere people will see it.</p>
<p>(you need a webcam to make it work)<br />
I partied to this all night.</p>

<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
			id="fm_Displacer_1816834437"
			class="flashmovie"
			width="640"
			height="480">
	<param name="movie" value="http://www.zachernuk.com/wp-content/2009/11/Displacer.swf" />
	<!--[if !IE]>-->
	<object	type="application/x-shockwave-flash"
			data="http://www.zachernuk.com/wp-content/2009/11/Displacer.swf"
			name="fm_Displacer_1816834437"
			width="640"
			height="480">
	<!--<![endif]-->
		<a href="http://adobe.com/go/getflashplayer"><img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" /></a><br />

	<!--[if !IE]>-->
	</object>
	<!--<![endif]-->
</object>
]]></content:encoded>
			<wfw:commentRss>http://www.zachernuk.com/2009/11/05/evident-utensil-experiment/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Cached particle field</title>
		<link>http://www.zachernuk.com/2009/10/23/cached-particle-field/</link>
		<comments>http://www.zachernuk.com/2009/10/23/cached-particle-field/#comments</comments>
		<pubDate>Thu, 22 Oct 2009 17:02:03 +0000</pubDate>
		<dc:creator>Brandel Zachernuk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.zachernuk.com/?p=303</guid>
		<description><![CDATA[Hello!
Long time no post, I have been (and still am) on-site on a contract job, and haven&#8217;t had a lot of time outside of work.  Nevertheless, I have been doing some interesting things!  Here is one of them &#8211; a test of the practicality for particle fields to be drawn from cached BitmapDatas, rather than [...]]]></description>
			<content:encoded><![CDATA[<p>Hello!</p>
<p>Long time no post, I have been (and still am) on-site on a contract job, and haven&#8217;t had a lot of time outside of work.  Nevertheless, I have been doing some interesting things!  Here is one of them &#8211; a test of the practicality for particle fields to be drawn from cached BitmapDatas, rather than generated per-frame.  It&#8217;s not fast,  but it&#8217;s much faster than the alternative:</p>

<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
			id="fm_cacheField_1512651166"
			class="flashmovie"
			width="400"
			height="600">
	<param name="movie" value="http://www.zachernuk.com/wp-content/2009/10/cacheField.swf" />
	<!--[if !IE]>-->
	<object	type="application/x-shockwave-flash"
			data="http://www.zachernuk.com/wp-content/2009/10/cacheField.swf"
			name="fm_cacheField_1512651166"
			width="400"
			height="600">
	<!--<![endif]-->
		<a href="http://adobe.com/go/getflashplayer"><img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" /></a></p>

	<!--[if !IE]>-->
	</object>
	<!--<![endif]-->
</object>
<p>In case you&#8217;re wondering what is going wrong, this is what happens when the pre-drawn circle bitmap isn&#8217;t offset appropriately.  To see it working properly, click the flash file and just hold down any key for the shapes to make proper circles.  Releasing again will revert to the crazy, checkerboard-like state.</p>
<p>The project I&#8217;m working on is very exciting, and should be ready for public unveiling in 3 weeks or so.  In the meantime, I can happily say that video uploads and downloads with Red5 and a basic apache HTTP install are far, far easier than I had ever hoped. Thank you to both project teams for being so awesome!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.zachernuk.com/2009/10/23/cached-particle-field/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Prince of Persia it ain&#8217;t</title>
		<link>http://www.zachernuk.com/2009/09/27/prince-of-persia-it-aint/</link>
		<comments>http://www.zachernuk.com/2009/09/27/prince-of-persia-it-aint/#comments</comments>
		<pubDate>Sat, 26 Sep 2009 17:19:27 +0000</pubDate>
		<dc:creator>Brandel Zachernuk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.zachernuk.com/?p=296</guid>
		<description><![CDATA[The pre-rendering idea that Playfish uses has made me eager to get animation control and manipulation, as well as geometry instancing to reduce overhead.  Since there are some obvious similarities between what I&#8217;m trying to do here and Prince of Persia, I tried to dig some information up on it.  It turns out Jordan Mechner [...]]]></description>
			<content:encoded><![CDATA[<p>The pre-rendering idea that Playfish uses has made me eager to get animation control and manipulation, as well as geometry instancing to reduce overhead.  Since there are some obvious similarities between what I&#8217;m trying to do here and Prince of Persia, I tried to dig some information up on it.  It turns out <a href="http://jordanmechner.com/prince-of-persia/">Jordan Mechne</a>r has his<a href="http://jordanmechner.com/old-journals/page/42/"> entire development diary</a> online!  And some of the<a href="http://vimeo.com/3858091"> reference footage of  his brother David jumping around</a> for him!  Inspiring stuff.  Anyway,  in aid of that, I thought I would start doing some more practical motion stuff, which has led me to this:</p>

<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
			id="fm_runmonk_709705511"
			class="flashmovie"
			width="400"
			height="600">
	<param name="movie" value="http://www.zachernuk.com/wp-content/2009/09/runmonk.swf" />
	<param name="allowfullscreen" value="true" />
	<!--[if !IE]>-->
	<object	type="application/x-shockwave-flash"
			data="http://www.zachernuk.com/wp-content/2009/09/runmonk.swf"
			name="fm_runmonk_709705511"
			width="400"
			height="600">
		<param name="allowfullscreen" value="true" />
	<!--<![endif]-->
		<a href="http://adobe.com/go/getflashplayer"><img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" /></a></p>

	<!--[if !IE]>-->
	</object>
	<!--<![endif]-->
</object>
<p>Yes, I am aware that there are occlusion issues.  I&#8217;m not completely certain how the 3d is going to integrate into the 2d environment, so it may prove to be unnecessary to do anything at all about it.  I&#8217;m thinking that only dynamic characters need be rendered in 3d, though it depends on whether the camera view will have any aspect of dynamic-ness,  and how well 2d / pre-rendered assets can integrate.</p>
<p>Re: the core game engine:  I&#8217;m running up against a bit of an irritating problem with keeping the optical, mechanical and visual representations of polygons in sync with one another.  There are a good number of advances since the last display, but unfortunately they&#8217;ll have to wait until this niggly issue is fixed!</p>
<p>I&#8217;ve also started making serious progress with Flash-PHP-SQL interactions, and vice versa, as well as beginning to make hooks into Facebook.  Interesting times ahead!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.zachernuk.com/2009/09/27/prince-of-persia-it-aint/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Papervision, Playfish and general 3D Pottering</title>
		<link>http://www.zachernuk.com/2009/09/22/papervision-playfish-and-general-3d-pottering/</link>
		<comments>http://www.zachernuk.com/2009/09/22/papervision-playfish-and-general-3d-pottering/#comments</comments>
		<pubDate>Mon, 21 Sep 2009 14:02:06 +0000</pubDate>
		<dc:creator>Brandel Zachernuk</dc:creator>
				<category><![CDATA[The Order]]></category>
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.zachernuk.com/?p=277</guid>
		<description><![CDATA[I&#8217;ve been thinking about how much I&#8217;d like perspective to make it into the mix of features for the Opticks engine, and have had a bit of experience with the Papervision3d engine, as seen on the lovely The Chills website.   Creating basic geometry and loading in stuff created from modeling packages was pretty straightforward, but [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been thinking about how much I&#8217;d like perspective to make it into the mix of features for the Opticks engine, and have had a bit of experience with the Papervision3d engine, as seen on the lovely <a href="http://www.softbomb.com/">The Chills </a>website.   Creating basic geometry and loading in stuff created from modeling packages was pretty straightforward, but I had always run up against a wall when loading and dealing with animations.</p>
<p>Another thing I noticed when pushing PV3d to the performance limit (and beyond, according to some people), is something that I have seen a lot of other complaints about: Papervision is very slow.  This is a fair accusation in comparison with, say, the Unreal engine (or even the Quake 1 engine at this point, but I&#8217;m convinced it&#8217;ll improve with time)  &#8211; but the thing about real-time 3d applications, games included, is that they have always been about the cheapest hacks available.</p>
<p>With the Chills animation I did things the hard way &#8211; hard for me, and unfortunately, hard for Papervision.  It looks pretty &#8211; there&#8217;s an aurora, reflections, changing colours for the clouds and the sky, dynamically generated igloos and a shaded, textured mountainscape.  And a motion blur.    All good things, save for the fact that it runs at about 5FPS without hardware acceleration. When I added more features in &#8211; a better motion blur, more detailed shading and mesh detailing, it brought even the most powerful desktops to their knees.  Screenshots looked <em>fantastic</em>, though.</p>
<div id="attachment_290" class="wp-caption alignnone" style="width: 310px"><a href="http://www.zachernuk.com/wp-content//chills-move.jpg"><img class="size-medium wp-image-290" title="chills-move" src="http://www.zachernuk.com/wp-content//chills-move-300x295.jpg" alt="This is a great movie, save for the framerate." width="300" height="295" /></a><p class="wp-caption-text">This is a great movie, save for the framerate.</p></div>
<p><strong>That&#8217;s not a movie, that&#8217;s a slideshow<br />
</strong></p>
<p>Let&#8217;s think of the possibilities for a second.  Instead of being required to produce 25+ FPS, if you could render one frame every second or two, and give the user a fancy zoom/fade/wipe/etc. transition between them,  you&#8217;d get away with much more.  It might even give them a more enjoyable experience than struggling to cram everything you can into the constraints of realtime.  If you wanted to go further, you could even pre-render an entire sequence to play back at realtime later &#8211; providing you had something to show now, and you could properly bridge the two sequences.</p>
<p>The slideshow idea is still something I&#8217;m interested in but we didn&#8217;t have time on that particular project.  The second option, using Papervision as a pre-renderer &#8211; was impractical because of the first-person, full-scene animation of the thing.  It was an idea I considered, discounted as inappropriate, and forgot about.</p>
<p>Until recently.   Earlier last month, <a href="http://www.meaningfulplay.com/2009/8/16/the-flash-frontier">Tim posted about Playfish</a>, who are doing some amazing things with Flash and social media.  After seeing this mention, and generally seeing Pet Society being spammed about for a while, I was curious about their offerings, so I signed up for a few of their games.</p>
<p>I wasn&#8217;t impressed with the first experience, but it turns out that Pet Society is probably the weakest title in their stable.  Since then they have made a series of Isometric titles with customizable characters.  Since I&#8217;m always fascinated by new technical developments in flash, and the fact that these titlesseem to run surprisingly well given the amount of stuff happening on-screen, I tried to dig up what the underlying technology is.</p>
<p><strong>It&#8217;s Papervision, but not as we know it</strong></p>
<div id="attachment_282" class="wp-caption alignnone" style="width: 310px"><a href="http://www.zachernuk.com/wp-content//mgp.jpg"><img class="size-medium wp-image-282" title="mgp" src="http://www.zachernuk.com/wp-content//mgp-300x191.jpg" alt="Minigolf party " width="300" height="191" /></a><p class="wp-caption-text">Minigolf party cleverly sidesteps Pv3d&#39;s tendency to crawl </p></div>
<p>They&#8217;ve done what I was pondering over earlier this year &#8211; According to some discussion on old papvervison3d mailing lists, they&#8217;re using pv3d to pre-render elements like characters to a series of bitmaps in a preload phase, and just playing them as simple movies as required.  This can be seen in titles like <em>Minigolf Party,</em> where the load time includes the pre-render stuff.  In more recent titles like <em>Restaurant City</em>, where there is a constant flow of characters in and out of the player&#8217;s view, I&#8217;m guessing they&#8217;re being generated just prior to display, and (hopefully) being dumped afterward.</p>
<div id="attachment_289" class="wp-caption alignnone" style="width: 310px"><a href="http://www.zachernuk.com/wp-content//restaurantcity.jpg"><img class="size-medium wp-image-289" title="restaurantcity" src="http://www.zachernuk.com/wp-content//restaurantcity-300x210.jpg" alt="RC displays a rolling cast of new, dynamically generated characters" width="300" height="210" /></a><p class="wp-caption-text">RC displays a rolling cast of new, dynamically generated characters</p></div>
<p><a href="http://www.zachernuk.com/wp-content//rc3.jpg"><br />
</a></p>
<p>Aside from sounding like a somewhat perverse approach to art, this is genius.  While the artists lose the fine-grained control of painting pixels or drawing out vector points, they can create much more content by rendering all necessary angles automatically, as well as change a hairstyle or a shirt without having to redraw the whole thing.</p>
<p>It cuts down on bandwidth, too &#8211; instead of sending out all the character animation that a user might need to see, you send them the model and the animations, and they handle it.</p>
<p>That&#8217;s all advantage which is shared between real-time and pre-rendered 3d.  Where they differ, though, is performance.   In most 3d engines, and in most Papervision-based systems, the whole scene is drawn every frame.  Papervision is fast, but it&#8217;s still running inside Flash, which means it is (at <em>least) </em>thousands of times slower than a modern game engine.   In order to have any performance at all, the detail has to be thousands of times simpler.</p>
<p>Unless you&#8217;re pre-rendering!  For animations that can be repeated (walk cycles, attacks etc), you can take as long as you want to render in a &#8216;load&#8217; phase, and then just play back the results as necessary.  This only works when you can guarantee you&#8217;ll use the same animation at least twice, and what you gain in performance comes at the cost of more storage  &#8211; the inevitable space / time tradeoff we always run up against in computing.  In most applications &#8211; consoles, mobile devices and such &#8211; the storage (in RAM) and processing capabilities are more or less equal.  In Flash, though, the storage is <em>vastly</em> greater than the processing power, so it makes sense to cache heavily.</p>
<p>Since I plan on using using this in my Opticks game,  I thought it would be worth trying out how hard it is to make this stuff happen.  Toward that end, I have been experimenting.  Below is a Playfish-style representation of what I have been doing. To do the things it says to, click in the panel and press keys ( Press &#8220;J&#8221;! It&#8217;s amazing!)</p>

<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
			id="fm_typeytypey_1160359660"
			class="flashmovie"
			width="400"
			height="600">
	<param name="movie" value="http://www.zachernuk.com/wp-content//typeytypey.swf" />
	<param name="seamlesstabbing" value="false" />
	<param name="allowfullscreen" value="true" />
	<param name="allownetworking" value="all" />
	<!--[if !IE]>-->
	<object	type="application/x-shockwave-flash"
			data="http://www.zachernuk.com/wp-content//typeytypey.swf"
			name="fm_typeytypey_1160359660"
			width="400"
			height="600">
		<param name="seamlesstabbing" value="false" />
		<param name="allowfullscreen" value="true" />
		<param name="allownetworking" value="all" />
	<!--<![endif]-->
		
<p><a href="http://adobe.com/go/getflashplayer"><img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" /></a></p>

	<!--[if !IE]>-->
	</object>
	<!--<![endif]-->
</object>
]]></content:encoded>
			<wfw:commentRss>http://www.zachernuk.com/2009/09/22/papervision-playfish-and-general-3d-pottering/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Natal, MotionPlus and the bright new frontiers of HCI</title>
		<link>http://www.zachernuk.com/2009/06/11/natal-motionplus-and-the-bright-new-frontiers-of-hci/</link>
		<comments>http://www.zachernuk.com/2009/06/11/natal-motionplus-and-the-bright-new-frontiers-of-hci/#comments</comments>
		<pubDate>Thu, 11 Jun 2009 11:48:16 +0000</pubDate>
		<dc:creator>Brandel Zachernuk</dc:creator>
				<category><![CDATA[Games]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[future]]></category>
		<category><![CDATA[gaming]]></category>
		<category><![CDATA[hci]]></category>
		<category><![CDATA[microsoft]]></category>
		<category><![CDATA[motionplus]]></category>
		<category><![CDATA[natal]]></category>
		<category><![CDATA[outside]]></category>
		<category><![CDATA[paintball]]></category>
		<category><![CDATA[vision]]></category>
		<category><![CDATA[wii]]></category>

		<guid isPermaLink="false">http://www.zachernuk.com/?p=226</guid>
		<description><![CDATA[When I started to catch up on what happened at E3 recently, I was dumbstruck. Between Microsoft&#8217;s Natal and Sony&#8217;s yet-unnamed motion control, we are seeing quite a turnaround. Motion control is the new bandwagon to jump on &#8211; and everyone seems to want a piece.
Maybe not everyone.  Gamers seem to be in violent opposition [...]]]></description>
			<content:encoded><![CDATA[<p>When I started to catch up on what happened at E3 recently, I was dumbstruck. Between Microsoft&#8217;s Natal and Sony&#8217;s yet-unnamed motion control, we are seeing quite a turnaround. Motion control is the new bandwagon to jump on &#8211; and everyone seems to want a piece.</p>
<p>Maybe not everyone.  Gamers seem to be in violent opposition to the idea of changing input methods.  On Slashdot, Gametrailers and other forums I still see people insist that the two-thumb controller is the best input method for platformers, a mouse the best method for Realtime Stragety (RTS), and a mouse and keyboard for First Person Shooter (FPS) games.</p>
<div id="attachment_229" class="wp-caption alignright" style="width: 310px"><a href="http://www.zachernuk.com/wp-content//gaming1990.jpg"><img class="size-medium wp-image-229  " title="Gaming in 1990" src="http://www.zachernuk.com/wp-content//gaming1990-300x218.jpg" alt="Gaming in 1990" width="300" height="218" /></a><p class="wp-caption-text">Gaming in 1990 (click to enlarge)</p></div>
<p>I find that reaction disappointing.  For a start, It&#8217;s probably not true.  Prior to Quake, most &#8216;gamers&#8217; (though they did not exist in the same numbers or have the same recognition as a demographic) insisted that a mouse was an unnecessary and fiddly complication to the task of moving a character around, and that looking up or down could be done easily enough entirely with the keyboard. As strange as it seems, gamers and technophiles in general appear to be a very conservative lot.*</p>
<p>Second, even if it were true, and it is a possibility &#8211; it is only because the RTS, FPS and platformer genres have been forced to work as effectively as they can the available systems.  They&#8217;ve been designed with these input methods in mind, so of course they&#8217;re going to seem like the only option available.</p>
<div id="attachment_230" class="wp-caption alignright" style="width: 310px"><a href="http://www.zachernuk.com/wp-content//gaming2000.jpg"><img class="size-medium wp-image-230 " title="Gaming in 2000" src="http://www.zachernuk.com/wp-content//gaming2000-300x218.jpg" alt="Gaming in 2000" width="300" height="218" /></a><p class="wp-caption-text">Gaming in 2000 (click to enlarge)</p></div>
<p>When you change the range of input devices, though, the options broaden.  It&#8217;s not hard to imagine a shooter where the player can lean around corners, duck projectiles or operate machinery with a little more nuance than just a &#8216;use&#8217; button.  With RTS games, we could issue two orders simultaneously with each hand, draw out formation plans with gestures or guide the attitude a subordinate AI officer commands with through a facial expression.</p>
<p>While I&#8217;m glad that &#8220;Motion Control&#8221; appears to be the bandwagon to jump on at present, I urge developers, gamers, and the public at large to see motion gaming as a &#8216;gateway drug&#8217; to better and weirder things. We can turn this into a watershed moment in history not just for gaming but for computing in general, where we decide that the main challenges in computing today are with Human-Computer Interaction (HCI), rather than computation or processing.</p>
<div id="attachment_231" class="wp-caption alignright" style="width: 310px"><a href="http://www.zachernuk.com/wp-content//gaming2010.jpg"><img class="size-medium wp-image-231" title="Gaming in 2010" src="http://www.zachernuk.com/wp-content//gaming2010-300x218.jpg" alt="Gaming in 2010" width="300" height="218" /></a><p class="wp-caption-text">Gaming in 2010 (click to enlarge)</p></div>
<p>One relatively recent breakthrough in Artificial Intelligence is the realization that agents are far, far more effective if they are properly embedded in the environment in which they operate.  That means having both consistency of &#8211; and plenty of &#8211; sensory information. Problems involving vision become (comparatively) simple when a number of camera views are added and combined as input, the problem of balance is made much easier if acceleration and force data is collected directly from multiple points rather than modelling &#8216;expected&#8217; values internally.</p>
<p>It follows, then, that the task of making sense of what a user wants from a computer would be made easier by giving it more information.  What may be less obvious is that it works the other way around, too.  The more sensory input from a system we have, the more sense the system is going to make, and the more immersive that system becomes.  The &#8220;next big thing&#8221; in mobile devices after touch-screen interfaces is tactile feedback from interfaces.  The Nokia Haptikos display will try to simulate the press of a button by shaking on confirmation.</p>
<p>I welcome the shift in emphasis of the console vendors.  We need to ignore the grumbling from current gamers and game developers, who are very stuck in their ways.  These detractors are ignoring the trends in gaming that have led us to this point, and where these trends indicate that gaming will go.  I hope that by the time I have kids who are old enough to lecture, I can tell them to go outside and play a videogame.</p>
<div id="attachment_232" class="wp-caption alignright" style="width: 310px"><a href="http://www.zachernuk.com/wp-content//gaming2020.jpg"><img class="size-medium wp-image-232" title="Gaming in 2020" src="http://www.zachernuk.com/wp-content//gaming2020-300x218.jpg" alt="Gaming in 2020" width="300" height="218" /></a><p class="wp-caption-text">Gaming in 2020 (click to enlarge)</p></div>
<p>* As an aside on the conservatism of technophiles, I remember that, at the ripe old age of 10, I was incensed at the suggestion that people were installing &#8220;sound cards&#8221; and other add-on hardware into IBM-PC compatible computers.  PCs were supposed to be generalized computing devices! If you wanted sound that badly, you should wait until the CPU could process it all in software! If I had heard that people were going to then go on and make cards that dealt exclusively with 3d graphics, I probably would have passed out from sheer indignation.  I was an unusual child.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.zachernuk.com/2009/06/11/natal-motionplus-and-the-bright-new-frontiers-of-hci/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>On Simulations and Agency</title>
		<link>http://www.zachernuk.com/2009/04/27/on-simulations-and-agency/</link>
		<comments>http://www.zachernuk.com/2009/04/27/on-simulations-and-agency/#comments</comments>
		<pubDate>Mon, 27 Apr 2009 06:50:38 +0000</pubDate>
		<dc:creator>Brandel Zachernuk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.zachernuk.com/?p=217</guid>
		<description><![CDATA[During my time at Clocktower Games, I had an on-going debate with Henry, the writer.  He was of the opinion that realism in games &#8211; creating accurate simulations of water, ragdoll physics, gravity or any other natural phenomenon was a pointless waste of time.  These things already exist in reality, so why bother making what [...]]]></description>
			<content:encoded><![CDATA[<p>During my time at Clocktower Games, I had an on-going debate with Henry, the writer.  He was of the opinion that realism in games &#8211; creating accurate simulations of water, ragdoll physics, gravity or any other natural phenomenon was a pointless waste of time.  These things already exist in reality, so why bother making what would inevitably be a poor copy of them?</p>
<p>Over the course of this Opticks project, I&#8217;ve been wondering a lot about that &#8211; after adding in lensing and additive/subtractive light systems it started to get important.  The next step is chromatic aberration &#8211; making red split from green and green from blue &#8211; but what&#8217;s the point of this? How far is it worth going?</p>
<div id="attachment_219" class="wp-caption alignnone" style="width: 310px"><a href="http://www.zachernuk.com/wp-content//screen1.jpg"><img class="size-medium wp-image-219" title="screen1" src="http://www.zachernuk.com/wp-content//screen1-300x199.jpg" alt="Fiat Lux!" width="300" height="199" /></a><p class="wp-caption-text">Fiat Lux!</p></div>
<p>I think the answer is this:  When you create an artificial system that mimics the laws of nature, you&#8217;re in control of when the laws are the same and when the laws are different.  In reality, mirrors are never perfect reflectors &#8211; they might reflect 99.99% of light (many do) &#8211; but if you bounce light between them indefinitely then it&#8217;s eventually going to dissipate.</p>
<p>In Opticks, I can make a perfect reflector &#8211; even a mirror that reflects 110% of the light that falls on it.  I don&#8217;t know why I&#8217;d want to right now, but the point is that I can.</p>
<div id="attachment_218" class="wp-caption alignnone" style="width: 310px"><a href="http://www.zachernuk.com/wp-content//screen2.jpg"><img class="size-medium wp-image-218" title="screen2" src="http://www.zachernuk.com/wp-content//screen2-300x215.jpg" alt="And the errors in simulated reality can look so funny!" width="300" height="215" /></a><p class="wp-caption-text">And the errors in simulated reality can look so funny!</p></div>
<p>Arbitrarily altering the simulated reality doesn&#8217;t even need to be useful, either &#8211; it can be done just for the enjoyment of experiencing an altered reality.  If you want to change your perception of a thing, you can either change your perception, or change the thing.  Drugs do the former,  simulations allow me to do the latter.  This way, I can take screenshots of what I see!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.zachernuk.com/2009/04/27/on-simulations-and-agency/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
