<?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>JActionScripters &#187; Experiment</title>
	<atom:link href="http://blog.jactionscripters.com/category/experiment/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.jactionscripters.com</link>
	<description>More than 20 Japanese flash coders share the blog/ You will be junkie for this crazy Japanese Flash news</description>
	<lastBuildDate>Sun, 20 Jun 2010 10:03: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>Genie effect with as3</title>
		<link>http://blog.jactionscripters.com/2009/09/09/genie-effect-with-as3/</link>
		<comments>http://blog.jactionscripters.com/2009/09/09/genie-effect-with-as3/#comments</comments>
		<pubDate>Wed, 09 Sep 2009 08:01:14 +0000</pubDate>
		<dc:creator>Takayuki Fukatsu</dc:creator>
				<category><![CDATA[Experiment]]></category>

		<guid isPermaLink="false">http://blog.jactionscripters.com/?p=934</guid>
		<description><![CDATA[Here is a Mac OSX like Genie effect made with AS3.
It&#8217;s basically made with Flash 10&#8217;s drawTriangles API &#038; Yoshihiro Shindo&#8217;s betweenAS3 tween library.
It&#8217;s just a initial sketch, but seems there is plenty of possibilities around the new bitmap drawing API.
]]></description>
			<content:encoded><![CDATA[<p>Here is a Mac OSX like <a href="http://fladdict.net/exp/ginnyeffect/">Genie effect made with AS3</a>.</p>
<p>It&#8217;s basically made with Flash 10&#8217;s drawTriangles API &#038; <a href="http://blog.jactionscripters.com/author/beinteractive/">Yoshihiro Shindo</a>&#8217;s <a href="http://www.libspark.org/svn/as3/BetweenAS3/tags/alpha-r3022/">betweenAS3 </a>tween library.</p>
<p>It&#8217;s just a initial sketch, but seems there is plenty of possibilities around the new bitmap drawing API.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.jactionscripters.com/2009/09/09/genie-effect-with-as3/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Particle Storm demo &amp; source</title>
		<link>http://blog.jactionscripters.com/2009/06/23/particle-storm-demo-source/</link>
		<comments>http://blog.jactionscripters.com/2009/06/23/particle-storm-demo-source/#comments</comments>
		<pubDate>Mon, 22 Jun 2009 15:41:12 +0000</pubDate>
		<dc:creator>Takayuki Fukatsu</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[Experiment]]></category>
		<category><![CDATA[VisualSketch]]></category>

		<guid isPermaLink="false">http://blog.jactionscripters.com/?p=736</guid>
		<description><![CDATA[FITC: Cool Japan side A / Particle sample of SMOKE &#8211; wonderfl build flash online
I think I have forgotton to post this experiment to JActionScripters.
Here is a playable demo &#038; source code that I showed on the FITC2009 session. Storm simulation with 10000 particle.
Basically all physic and mouse interaction is calculated with bitmap force map. [...]]]></description>
			<content:encoded><![CDATA[<div style="text-align:center;width:465px;"><iframe title="FITC: Cool Japan side A / Particle sample of SMOKE - wonderfl build flash online" src="http://wonderfl.net/blogparts/e5458ebf7b16817e3529321415c4f17ce965515a" width="465" height="490" style="border:1px black solid;"></iframe><a href="http://wonderfl.net/code/e5458ebf7b16817e3529321415c4f17ce965515a" title="FITC: Cool Japan side A / Particle sample of SMOKE - wonderfl build flash online">FITC: Cool Japan side A / Particle sample of SMOKE &#8211; wonderfl build flash online</a></div>
<p>I think I have forgotton to post this experiment to JActionScripters.<br />
Here is a <a href="http://wonderfl.net/code/e5458ebf7b16817e3529321415c4f17ce965515a">playable demo &#038; source</a> code that I showed on the FITC2009 session. Storm simulation with 10000 particle.</p>
<p>Basically all physic and mouse interaction is calculated with bitmap force map. Precalculating mouse interaction with bitmap is much faster than doing mouse distance with 10000 particles every frame.</p>
<p>You can also see stupid <a href="http://wonderfl.net/code/0108d7b3b7a336aa406134e62ae6a50736519c08">250000 particle version</a> here.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.jactionscripters.com/2009/06/23/particle-storm-demo-source/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>ARMessageCard (ARSandPainting)</title>
		<link>http://blog.jactionscripters.com/2009/06/02/armessagecard-arsandpainting/</link>
		<comments>http://blog.jactionscripters.com/2009/06/02/armessagecard-arsandpainting/#comments</comments>
		<pubDate>Tue, 02 Jun 2009 07:06:01 +0000</pubDate>
		<dc:creator>Yoshihiro Shindo</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[Experiment]]></category>
		<category><![CDATA[Showcase]]></category>

		<guid isPermaLink="false">http://blog.jactionscripters.com/?p=730</guid>
		<description><![CDATA[
In the Spark meeting #09, I presented an ARMessageCard for Geoff. At first, a card on the marker seems to be white, but a message will be rose by particles moves if you tilt the card. It works like a sand painting.

ARMessageCard from Yoshihiro Shindo on Vimeo.
You can try it at here (Please use this [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://blog.jactionscripters.com/wp-content/uploads/2009/05/armessagecard.png" alt="ARMessageCard" title="ARMessageCard" width="640" height="360" class="alignnone size-full wp-image-706" /></p>
<p>In <a href="http://blog.jactionscripters.com/2009/05/29/monthly-spark-meeting-09/">the Spark meeting #09</a>, I presented an ARMessageCard for Geoff. At first, a card on the marker seems to be white, but a message will be rose by particles moves if you tilt the card. It works like a sand painting.</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=4901020&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=4901020&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/4901020">ARMessageCard</a> from <a href="http://vimeo.com/user1825548">Yoshihiro Shindo</a> on <a href="http://vimeo.com">Vimeo</a>.</p>
<p>You can try it at <a href="http://www.be-interactive.org/works/20090528/ARMessageCard/ARMessageCard.swf">here</a> (Please use <a href="http://www.be-interactive.org/works/20090528/ARMessageCard/Data/flarlogo-marker.pdf">this marker</a>). Of course, <a href="http://www.be-interactive.org/works/20090528/ARMessageCard.zip">source code was uploaded</a>.</p>
<p>A point of this Flash is calculating gravity from the inclination of the card to move particles.</p>
<p>If you defined variables like:</p>
<p><code-style>
<pre name="code" class="as3">
private var _mat:Matrix3D = new Matrix3D();
private var _rot:Number3D = Number3D.ZERO;
private var _v:Number3D = new Number3D();
</pre>
<p></code-style></p>
<p>*Matrix3D and Number3D are provided by Papervision3D.</p>
<p>You can get gravity by the following code:</p>
<p><code-style>
<pre name="code" class="as3">
_mat.copy(_baseNode.transform);
_mat.invert();
_rot = Matrix3D.matrix2euler(_mat, _rot);
_v.reset(0, 1, 0);
_v.rotateY(_rot.y);
_v.rotateX(_rot.x);
_v.rotateZ(_rot.z);
var gx:Number = -_v.x * 2.0;
var gy:Number = -_v.y * 2.0;
</pre>
<p></code-style></p>
<p>*_baseNode is provided by FLARToolKit.</p>
<p>First, invert the transform matrix calculated by the FLARToolKit to get a transform matrix of gravity about the marker. Next, apply only rotations from the transform matrix to a normalized vector for gravity. Finally, get x value and y value from it. If you move particles based on these values, it will work fine <img src='http://blog.jactionscripters.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://blog.jactionscripters.com/2009/06/02/armessagecard-arsandpainting/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Porting a few Max/MSP Objects</title>
		<link>http://blog.jactionscripters.com/2009/05/26/porting-a-few-maxmsp-objects-in-as/</link>
		<comments>http://blog.jactionscripters.com/2009/05/26/porting-a-few-maxmsp-objects-in-as/#comments</comments>
		<pubDate>Tue, 26 May 2009 14:11:13 +0000</pubDate>
		<dc:creator>Takuho Yoshizu</dc:creator>
				<category><![CDATA[Experiment]]></category>

		<guid isPermaLink="false">http://blog.jactionscripters.com/?p=649</guid>
		<description><![CDATA[
I started to port a few Max/MSP Objects such as &#8220;groove~&#8221; &#8220;waveform~&#8221; &#8220;buffer~&#8221; &#8220;dac~&#8221; to ActionScript Classes.
It&#8217;s not been completed yet but here is the first sample.
Random Groove
(you can cut up synchronized two audio files randomly)
These API is something like below.

dac = new DAC();
buffer = new Buffer(2000);  // buffer length(ms)

groove = new Groove(buffer);
groove.loop = true;

waveform [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://seagirl.jp/labs/randomgroove/"><img class="alignnone size-full wp-image-659" title="randomgroove" src="http://blog.jactionscripters.com/wp-content/uploads/2009/05/randomgroove.jpg" alt="randomgroove" width="640" height="396" /></a></p>
<p>I started to port a few Max/MSP Objects such as &#8220;groove~&#8221; &#8220;waveform~&#8221; &#8220;buffer~&#8221; &#8220;dac~&#8221; to ActionScript Classes.</p>
<p>It&#8217;s not been completed yet but here is the first sample.</p>
<p><a href="http://seagirl.jp/labs/randomgroove/">Random Groove</a><br />
(you can cut up synchronized two audio files randomly)</p>
<p>These API is something like below.<br />
<code-style>
<pre name="code" class="as3">dac = new DAC();
buffer = new Buffer(2000);  // buffer length(ms)

groove = new Groove(buffer);
groove.loop = true;

waveform = new Waveform(buffer);
addChild(waveform);
waveform.addEventListener(Event.CHANGE, waveformChangeHandler);

private function waveformChangeHandler(event:Event):void
{
    begin.text = String(int(waveform.range.x));
    end.text = String(int(waveform.range.y));

    groove.range(waveform.range);
    dac.play(groove.data);
}</pre>
<p></code-style></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.jactionscripters.com/2009/05/26/porting-a-few-maxmsp-objects-in-as/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Optimize iteration for Particle</title>
		<link>http://blog.jactionscripters.com/2009/05/22/optimize-iteration-for-particle/</link>
		<comments>http://blog.jactionscripters.com/2009/05/22/optimize-iteration-for-particle/#comments</comments>
		<pubDate>Fri, 22 May 2009 05:08:45 +0000</pubDate>
		<dc:creator>Yoshihiro Shindo</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[Experiment]]></category>
		<category><![CDATA[Tips]]></category>

		<guid isPermaLink="false">http://blog.jactionscripters.com/?p=598</guid>
		<description><![CDATA[Few weeks ago, Particle was a trend in Japanese Flash guys. Many works were posted to the Wonderfl with a tag &#8220;パーティクル祭 (Particle Matsuri)&#8221; (means Particle Festival).
In one of them, there is &#8220;100,000 particles&#8221; posted by bkzen. I think it&#8217;s pretty cool! but I need more speed. :p So I posted a quick optmized one. [...]]]></description>
			<content:encoded><![CDATA[<p>Few weeks ago, <a href="http://en.wikipedia.org/wiki/Particle_system">Particle</a> was a trend in Japanese Flash guys. Many works <a href="http://wonderfl.kayac.com/tag/%E3%83%91%E3%83%BC%E3%83%86%E3%82%A3%E3%82%AF%E3%83%AB%E7%A5%AD">were posted to the Wonderfl with a tag &#8220;パーティクル祭 (Particle Matsuri)&#8221;</a> (means Particle Festival).</p>
<p>In one of them, there is <a href="http://wonderfl.kayac.com/code/b218434cf7db99283847f9947b221628ac408346">&#8220;100,000 particles&#8221;</a> posted by <a href="http://blog.bk-zen.com/">bkzen</a>. I think it&#8217;s pretty cool! but I need more speed. :p So I posted a <a href="http://wonderfl.kayac.com/code/6efe4c0d9b5e27e91db92b1175409f31e7005dca">quick optmized one</a>. It brings 33% faster (21fps -> 28fps) in my Mac. <img src='http://blog.jactionscripters.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>You can see what did I changed by clicking &#8220;diff&#8221; link in above page. In short, I changed an iteration method from Array to <a href="http://en.wikipedia.org/wiki/Linked_list">LinkedList</a>. Because array index access and calculating and checking an index (variable i) are pretty slow.</p>
<p><code-style>
<pre name="code" class="as3">
// Slow
while (i > num) {
    p = particles[i];
    // do something
    i++;
}
</pre>
<p></code-style></p>
<p>But accessing an member variable is fast because it's optimized by AVM2. So it causes fast iteration.</p>
<p><code-style>
<pre name="code" class="as3">
// Fast
while ((p = p.next) != null) {
    // do something
}
</pre>
<p></code-style></p>
<p>Please use this optimization if you need fast iteration especially in case you have a large data.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.jactionscripters.com/2009/05/22/optimize-iteration-for-particle/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Study &#8211; Long Exposure-Like Visual Effect</title>
		<link>http://blog.jactionscripters.com/2009/05/21/study-long-exposure-like-visual-effect/</link>
		<comments>http://blog.jactionscripters.com/2009/05/21/study-long-exposure-like-visual-effect/#comments</comments>
		<pubDate>Thu, 21 May 2009 03:04:01 +0000</pubDate>
		<dc:creator>Jin Saburi</dc:creator>
				<category><![CDATA[Experiment]]></category>
		<category><![CDATA[VisualSketch]]></category>

		<guid isPermaLink="false">http://blog.jactionscripters.com/?p=542</guid>
		<description><![CDATA[One of my professions is a professional photographer. Of many techniques,
I love to take long exposure photos and often like to light-paint within them.

This is a real photo taken with a Nikon DSLR, 30secs, drawn with two LED penlights (blue/white) for a new year's card in 2006.

Usually, you would take a long exposure photo, by [...]]]></description>
			<content:encoded><![CDATA[<p>One of my professions is a professional photographer. Of many techniques,<br />
I love to take <a href="http://en.wikipedia.org/wiki/Long_exposure_photography" target="_blank">long exposure photos</a> and often like to <a href="http://en.wikipedia.org/wiki/Light_painting" target="_blank">light-paint</a> within them.</p>
<p><img src="http://jactionscripters.com/files/saburicom/long_exposure/nenga2006_front.jpg" alt="2006_HNY_card" title="2006_HNY_card" width="640" height="480" /><br />
<code>This is a real photo taken with a Nikon DSLR, 30secs, drawn with two LED penlights (blue/white) for a new year's card in 2006.</code><br />
<span id="more-542"></span></p>
<p>Usually, you would take a long exposure photo, by controlling the contrast between light sources.<br />
First, you set your camera to take time &#8211; let&#8217;s say 10 secs &#8211; to produce a composition. You seek the best aperture to give you the most &#8216;working time&#8217;, that means a long enough shutter speed to let you draw whatever you want within the frame, with a penlight or fire from a lighter, cars&#8217; head/rear lights drifting on a highway, etc. While the surrounding environment slowly burns into the film, the strong light sources would be able to burn instantly, and give you a nice line of light at your control.</p>
<p>But, if you were to do this with a USB camera input, there are several issues to be considered.</p>
<p>Firstly, since you can only access the bitmapData that comes into Flash as an image. This means you don&#8217;t know whether the white pixels are strong light, or just a white background. So, let&#8217;s say you blend each frame with a slight alpha. Since you can&#8217;t properly divide the strong light and weak light, the strong light would become as black as your white background, which will not produce the proper result.<br />
Your face will be as bright as the penlight, making a big, white, blob &#8211; a disaster.</p>
<p>Even more, each pixel has only 256 levels of data, so if you want to blend 256 frames (just about 8.5 secs), the data will be all black, since the levels will be shut down to zero. Even if you darken it a bit lighter, you will only have several levels to work with, leading to a posterized, contrasty failure.</p>
<p><img src="http://jactionscripters.com/files/saburicom/long_exposure/blob_bright.jpg" alt="Bright Blob 5secs with lighten blend" title="Bright Blob 5secs with lighten blend" width="310" height="233" class="alignleft size-full wp-image-21" />So, even if it is not logically correct, we will make a long exposure &#8216;like&#8217; effect this time, using the &#8216;lighten&#8217; blend mode rather than the &#8216;add&#8217; mode. Brighter pixels will be recorded. So, if you do this in a bright room, the results would look like this left image.</p>
<p>But, if you turn off the lights, you will be able to successfully draw your laser-lines.<br clear="all"/><br />
<img src="http://jactionscripters.com/files/saburicom/long_exposure/jas_02.jpg" alt="Light drawing w/ USB camera" title="Light drawing w/ USB camera"" width="640" height="480" /><code>This is done with a MacBook Pro/iSight and Flash CS3, in a dark room, and a small flashlight.</code></p>
<p>If you are satisfied with this, you are already at your finish line, but I would like to add what photographers call a &#8216;fill-in flash&#8217;, to give you more nice image. Please note that this is a digital version, so it will not be pixel-perfect.</p>
<p><img src="http://jactionscripters.com/files/saburicom/long_exposure/polaroid.jpg" alt="fill-in flash w/ Polaroid NightCam" title="fill-in flash w/ Polaroid NightCam" width="310" height="310" class="alignright size-full wp-image-21" />A &#8216;fill-in flash&#8217; with a real camera gives a dark foreground some light to brighten up the area after you record all the light drawings. Usually, this technique is used to take nice night photos of let&#8217;s say a cityscape. You would set the camera to take several seconds to burn the city lights into the film in the darkness, then flash the person in the foreground to finalize the composition.</p>
<p>To mimick this effect, we will &#8216;burn&#8217; the video input into the bitmapData with the &#8216;add&#8217; blendmode. But the problem still remains &#8211; it is still a digital effect, so you need the proper preparation to give you nice results.<br />
<br clear="all"/><br />
<img src="http://jactionscripters.com/files/saburicom/long_exposure/nd_filter.jpg" alt="ND8 filter taped to my MBP" title="ND8 filter taped to my MBP" width="310" height="233" class="alignleft size-full wp-image-21" />My solution is quite analog. I used a ND8 filter that I use for my cameras, and attached it to my iSight camera. It depends on your USB camera&#8217;s specs, but my iSight had neat results with the ND8 filter, with 2 flashes &#8211; meaning burning two frames with additive mode digitally. ND8 filters are like sunglasses to the USB cam.</p>
<p>The point to this digital long exposure-like effect is, that since it is tweaked to show light-drawings mainly, the blurring of normal recordings are not correct. On the other hand, since it is NOT using the additive mode (which would burn up to 0xFF white), you can set the &#8217;shutter&#8217; to 8 secs or 8 mins, and it will not over-expose (this is quite handy compared to an analog camera).<br clear="all"/></p>
<p><img src="http://jactionscripters.com/files/saburicom/long_exposure/jas_01.jpg" alt="JAS light drawing w/ USB camera" title="JAS light drawing w/ USB camera" width="640" height="480" /><br />
<code>JAPAN ActionScripters !!!</code><br />
<img src="http://jactionscripters.com/files/saburicom/long_exposure/heart.jpg" alt="JAS light drawing w/ USB camera" title="JAS light drawing w/ USB camera" width="640" height="480" /><br />
<code>Love Flash. Love you all.</code><br />
<img src="http://jactionscripters.com/files/saburicom/long_exposure/s_imgs.jpg" alt="JAS light drawing w/ USB camera" title="JAS light drawing w/ USB camera" width="640" height="240" /><br />
<code>left : Waving a flashlight in the dark. Red is actually my blood in my hand lit up.<br />
right : Flashing my face with a flashlight in the dark several times to simulate multiple exposures (even though it's me, it's SCARY)</code><br />
The parameters in this project are set to a ND8 filter covered camera, and setting default to my environment. Play around with the setting to get similar results.</p>
<p><a href="http://jactionscripters.com/files/saburicom/long_exposure/project" target="_blank">Here is the working project (new window).</a></p>
<p><code><strong>Additive Composition</strong> : this checkbox will enable additive blending, so you can see that the levels are not enough, and the composition is HORRIBLE ;D</code></p>
<p><code><strong>Capture Button</strong> : use this button to start recording.</code></p>
<p><code><strong>Seconds</strong> : set this to how long you want to record. 5s to 30s, defalt 15s.</code></p>
<p><code><strong>Flash</strong> : this is how many times you want to use the 'fill-in flash'</code></p>
<p>What do you think about this study ? If the lights are not drawing as a line, and becoming a dotted-line, draw slower, as the USB camera only records 30 frames per second, compared to a seamless recording of a camera.</p>
<p>I think fladdict will make us an iPhone version of this toy. Of course he will <img src='http://blog.jactionscripters.com/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> </p>
<p>Here are the files : <a href="http://jactionscripters.com/files/saburicom/long_exposure/project/long_exposure.zip">long_exposure.zip (772KB)</a></p>
<p>Just an idea that came to me about 6 hours ago, and took me about two to experiment, and write this post. Hope you enjoyed it !!!</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.jactionscripters.com/2009/05/21/study-long-exposure-like-visual-effect/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Adaptive thresholding experiment</title>
		<link>http://blog.jactionscripters.com/2009/05/18/adaptive-thresholding-experiment/</link>
		<comments>http://blog.jactionscripters.com/2009/05/18/adaptive-thresholding-experiment/#comments</comments>
		<pubDate>Mon, 18 May 2009 00:09:23 +0000</pubDate>
		<dc:creator>Saqoosha</dc:creator>
				<category><![CDATA[Experiment]]></category>

		<guid isPermaLink="false">http://blog.jactionscripters.com/?p=351</guid>
		<description><![CDATA[Hello, World!
My name is Tomohiko Koyama aka Saqoosha. I think everyone knows me as a developer of FLARToolKit. I joined JActionScripters.com too, and I hope that Japanese Flashers are exposed to the world more and more. My English is not so good. If you find a mistake, please correct me.
Recently, I researched about Thresholding algorithms. [...]]]></description>
			<content:encoded><![CDATA[<p>Hello, World!</p>
<p>My name is Tomohiko Koyama aka <a href="http://saqoosha.net/en/">Saqoosha</a>. I think everyone knows me as a developer of <a href="http://www.libspark.org/wiki/saqoosha/FLARToolKit/en">FLARToolKit</a>. I joined JActionScripters.com too, and I hope that Japanese Flashers are exposed to the world more and more. My English is not so good. If you find a mistake, please correct me.</p>
<p>Recently, I researched about <a href="http://en.wikipedia.org/wiki/Thresholding_(image_processing)">Thresholding</a> algorithms. Thresholding algorithms are used to binarize and preprocess the input to find some objects within the image. FLARToolKit uses a thresholding algorithm to detect the marker.</p>
<p>The algorithm currently using in FLARToolKit is Global Thresholding.</p>
<p><img src="http://blog.jactionscripters.com/wp-content/uploads/2009/05/saq-global-thresholding.png" border="0" alt="Saq-Global-Thresholding" hspace="0" vspace="0" width="640" height="240" /></p>
<p>Its implementation is simple and faster, but no flexibility about illumination variation. I looked for a thresholding algorithm to improve this weak point. Then found <a href="http://homepages.inf.ed.ac.uk/rbf/HIPR2/adpthrsh.htm">Adaptive Thresholding</a>.</p>
<p><span id="more-351"></span>Adaptive thresholding doesn&#8217;t use constant thresholding values as with Global thresholding. Thresholding value is calculated for each pixel using surrounding pixels. It&#8217;s result is amazingly adaptive to various illumination. Please watch this video.</p>
<p><object width="640" height="480" data="http://vimeo.com/moogaloop.swf?clip_id=4697603&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=ffff00&amp;fullscreen=1" type="application/x-shockwave-flash"><param name="allowfullscreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://vimeo.com/moogaloop.swf?clip_id=4697603&amp;server=vimeo.com&amp;show_title=1&amp;show_byline=1&amp;show_portrait=0&amp;color=ffff00&amp;fullscreen=1" /></object></p>
<p>Upper is the source video. Left is global thresholding, and right is adaptive thresholding. The marker (square at the center) is always visible in adaptive thresholding result. It&#8217;s using BlurFilter to calculate local thresholding value. <a href="http://jactionscripters.com/files/Saqoosha/adaptive-thresholding/srcview/">Source code is here</a>. <a href="http://jactionscripters.com/files/Saqoosha/adaptive-thresholding/">Online demo</a> (requires webcam) is also uploaded. Use up and down arrow keys to simulate illumination variation.</p>
<p><a href="http://makc3d.wordpress.com/2009/05/05/flartoolkit-adaptive-filter-experiment-sources/">Makc3d already implemented</a> this method into FLARToolKit, but I think it&#8217;s required more optimization to reduce calculation time.</p>
<p>The future version of FLARToolKit will include Adaptive thresholding filter to adapt to various illumination.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.jactionscripters.com/2009/05/18/adaptive-thresholding-experiment/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
	</channel>
</rss>
