<?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>Luke Loeffler &#187; dance</title>
	<atom:link href="http://lukeloeffler.com/tag/dance/feed/" rel="self" type="application/rss+xml" />
	<link>http://lukeloeffler.com</link>
	<description></description>
	<lastBuildDate>Mon, 30 Jan 2012 19:47:45 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Gesture</title>
		<link>http://lukeloeffler.com/2009/gesture/</link>
		<comments>http://lukeloeffler.com/2009/gesture/#comments</comments>
		<pubDate>Wed, 29 Jul 2009 03:40:34 +0000</pubDate>
		<dc:creator>luke</dc:creator>
				<category><![CDATA[gallery]]></category>
		<category><![CDATA[dance]]></category>
		<category><![CDATA[processing]]></category>
		<category><![CDATA[video]]></category>

		<guid isPermaLink="false">http://lukeloeffler.com/?p=320</guid>
		<description><![CDATA[Custom video processing software uniting the movement of dance and drawing]]></description>
			<content:encoded><![CDATA[<p>Gesture is an animation generated by custom video processing software that seeks to unite the movements of dance and drawing by distilling the dancer&#8217;s poses into a sequence fluid lines. As a spotlight follows the dancer across the new stage, indications of movement are left behind by soft erased lines.</p>
<p><object classid="clsid:02bf25d5-8c17-4b23-bc80-d3488abddc6b" width="640" height="480" codebase="http://www.apple.com/qtactivex/qtplugin.cab#version=6,0,2,0"><param name="src" value="http://lukeloeffler.com/wordpress/wp-content/uploads/2009/07/gesture.mov" /><embed type="video/quicktime" width="640" height="480" src="http://lukeloeffler.com/wordpress/wp-content/uploads/2009/07/gesture.mov"></embed></object></p>
<p>If you&#8217;re interested in a technical description of the code, read on. The main hurdle to getting this completed was implementing a fast &#8220;nearest neighbor&#8221; system. From the chroma-key footage (&#8220;green screen&#8221; as it&#8217;s often called), I threshold it (which means turn it to black and white). Next, I perform edge detection which leaves just the outline to the dancer. By altering the edge detector&#8217;s &#8220;kernel,&#8221; a mathematical term for a table of numbers, I can degrade the outline so it is a series of dots rather than one solid line. Next, I go through the image and make note of the locations of all the points. All that&#8217;s left to do is to connect them with a continuous line. However, if you simply connect the dots in the order they were found (top to bottom, left to right), you will get a zig-zag line that fills the area of the dancer. The next logical step is to take a starting point and ask for it&#8217;s nearest neighbor and connect the two. Then continue the line to the nearest neighbor after that, and so on. Unfortunately, this naive approach does not scale well and takes an enormous amount of time to compute. Enter the <a href="http://en.wikipedia.org/wiki/Kd-tree">KD Tree</a>, a method of storing the points for fast retrieval. I had started to write my own implementation last year and got distracted. Thankfully, I found a simple <a href="http://www.cs.wlu.edu/~levy/software/kd/">implementation</a> for Java which worked perfectly. It&#8217;s beautiful to see a series of techniques converge to produce something entirely new.</p>
<p>The source code is provided in two files: <a href="http://lukeloeffler.com/wordpress/wp-content/uploads/2009/07/dancers_outlined.pde">dancers_outlined.pde</a> and <a href="http://lukeloeffler.com/wordpress/wp-content/uploads/2009/07/Tree.java">Tree.java</a> for reference. Please be warned&#8211;it is very rough and not intended for public consumption, although I tried to comment as much as possible.</p>
]]></content:encoded>
			<wfw:commentRss>http://lukeloeffler.com/2009/gesture/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
<enclosure url="http://lukeloeffler.com/wordpress/wp-content/uploads/2009/07/gesture.mov" length="5065959" type="video/quicktime" />
		</item>
	</channel>
</rss>

