<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: OpenSource Image Dithering for AS3. (demo+source).</title>
	<atom:link href="http://www.unitzeroone.com/blog/2008/05/06/opensource-image-dithering-for-as3-demosource/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.unitzeroone.com/blog/2008/05/06/opensource-image-dithering-for-as3-demosource/</link>
	<description>A blog written by Ralph Hauwert, freelance developer, specialized in realtime visualisation, 3D and application development.</description>
	<lastBuildDate>Thu, 18 Mar 2010 23:23:59 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Brian</title>
		<link>http://www.unitzeroone.com/blog/2008/05/06/opensource-image-dithering-for-as3-demosource/comment-page-1/#comment-2343</link>
		<dc:creator>Brian</dc:creator>
		<pubDate>Wed, 11 Nov 2009 01:27:24 +0000</pubDate>
		<guid isPermaLink="false">http://www.unitzeroone.com/blog/?p=155#comment-2343</guid>
		<description>Is it possible to use this to do floyd-steinberg dithering into a pre-defined palette of 256 colors?</description>
		<content:encoded><![CDATA[<p>Is it possible to use this to do floyd-steinberg dithering into a pre-defined palette of 256 colors?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Michael</title>
		<link>http://www.unitzeroone.com/blog/2008/05/06/opensource-image-dithering-for-as3-demosource/comment-page-1/#comment-1246</link>
		<dc:creator>Michael</dc:creator>
		<pubDate>Thu, 19 Mar 2009 01:32:21 +0000</pubDate>
		<guid isPermaLink="false">http://www.unitzeroone.com/blog/?p=155#comment-1246</guid>
		<description>Cool!

We did some pattern dithering a year back on this site:

http://www.firstinflight.com.au

The nice thing about it is most of the backgrounds are 20kb jpgs which the dithering nicely hides.</description>
		<content:encoded><![CDATA[<p>Cool!</p>
<p>We did some pattern dithering a year back on this site:</p>
<p><a href="http://www.firstinflight.com.au" rel="nofollow">http://www.firstinflight.com.au</a></p>
<p>The nice thing about it is most of the backgrounds are 20kb jpgs which the dithering nicely hides.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: import.labs*</title>
		<link>http://www.unitzeroone.com/blog/2008/05/06/opensource-image-dithering-for-as3-demosource/comment-page-1/#comment-1154</link>
		<dc:creator>import.labs*</dc:creator>
		<pubDate>Sat, 29 Nov 2008 15:35:17 +0000</pubDate>
		<guid isPermaLink="false">http://www.unitzeroone.com/blog/?p=155#comment-1154</guid>
		<description>[...] this out Demo + source    Leave your comment  [...]</description>
		<content:encoded><![CDATA[<p>[...] this out Demo + source    Leave your comment  [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: FlÃ¼ge Thailand</title>
		<link>http://www.unitzeroone.com/blog/2008/05/06/opensource-image-dithering-for-as3-demosource/comment-page-1/#comment-1094</link>
		<dc:creator>FlÃ¼ge Thailand</dc:creator>
		<pubDate>Mon, 01 Sep 2008 15:06:40 +0000</pubDate>
		<guid isPermaLink="false">http://www.unitzeroone.com/blog/?p=155#comment-1094</guid>
		<description>Oh thanks! Since I use AS3 I got to learn some things again. I already forgot that IÂ´ve dithered in AS2 already.</description>
		<content:encoded><![CDATA[<p>Oh thanks! Since I use AS3 I got to learn some things again. I already forgot that IÂ´ve dithered in AS2 already.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: George Profenza</title>
		<link>http://www.unitzeroone.com/blog/2008/05/06/opensource-image-dithering-for-as3-demosource/comment-page-1/#comment-1000</link>
		<dc:creator>George Profenza</dc:creator>
		<pubDate>Wed, 14 May 2008 10:59:58 +0000</pubDate>
		<guid isPermaLink="false">http://www.unitzeroone.com/blog/?p=155#comment-1000</guid>
		<description>Hi,

Great stuff,

I&#039;ve done a similar experiment back in February and posted something in March.
When I say pretty similar, I&#039;m not kidding :)

http://tomaterial.blogspot.com/2008/03/dithering-in-actionscript-30.html</description>
		<content:encoded><![CDATA[<p>Hi,</p>
<p>Great stuff,</p>
<p>I&#8217;ve done a similar experiment back in February and posted something in March.<br />
When I say pretty similar, I&#8217;m not kidding <img src='http://www.unitzeroone.com/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p><a href="http://tomaterial.blogspot.com/2008/03/dithering-in-actionscript-30.html" rel="nofollow">http://tomaterial.blogspot.com/2008/03/dithering-in-actionscript-30.html</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: UnitZeroOne</title>
		<link>http://www.unitzeroone.com/blog/2008/05/06/opensource-image-dithering-for-as3-demosource/comment-page-1/#comment-982</link>
		<dc:creator>UnitZeroOne</dc:creator>
		<pubDate>Tue, 06 May 2008 20:57:01 +0000</pubDate>
		<guid isPermaLink="false">http://www.unitzeroone.com/blog/?p=155#comment-982</guid>
		<description>You&#039;re right. I was actually also still thinking about that one....I didn&#039;t want to go all out on this, but really what it should have is some kind of ImageFormat class, to specify the bits per channel and amount of channels. Not sure...2 levels is probably the best approach now, I&#039;ll check it in ....</description>
		<content:encoded><![CDATA[<p>You&#8217;re right. I was actually also still thinking about that one&#8230;.I didn&#8217;t want to go all out on this, but really what it should have is some kind of ImageFormat class, to specify the bits per channel and amount of channels. Not sure&#8230;2 levels is probably the best approach now, I&#8217;ll check it in &#8230;.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mario Klingemann</title>
		<link>http://www.unitzeroone.com/blog/2008/05/06/opensource-image-dithering-for-as3-demosource/comment-page-1/#comment-979</link>
		<dc:creator>Mario Klingemann</dc:creator>
		<pubDate>Tue, 06 May 2008 17:44:17 +0000</pubDate>
		<guid isPermaLink="false">http://www.unitzeroone.com/blog/?p=155#comment-979</guid>
		<description>Sorry for nagging but I have a tiny cosmetic issue: I think the correct way to pick just black and white would be to say &quot;2 Levels&quot; and not &quot;1 Level&quot; as it is currently implemented. To me &quot;1 Level&quot; would be just one color aka black.</description>
		<content:encoded><![CDATA[<p>Sorry for nagging but I have a tiny cosmetic issue: I think the correct way to pick just black and white would be to say &#8220;2 Levels&#8221; and not &#8220;1 Level&#8221; as it is currently implemented. To me &#8220;1 Level&#8221; would be just one color aka black.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mario Klingemann</title>
		<link>http://www.unitzeroone.com/blog/2008/05/06/opensource-image-dithering-for-as3-demosource/comment-page-1/#comment-978</link>
		<dc:creator>Mario Klingemann</dc:creator>
		<pubDate>Tue, 06 May 2008 17:18:19 +0000</pubDate>
		<guid isPermaLink="false">http://www.unitzeroone.com/blog/?p=155#comment-978</guid>
		<description>Oh yes of course - now I see it. Well, that makes it indeed difficult to impossible to use paletteMap here. BTW - it looks like my code above was garbled by html.</description>
		<content:encoded><![CDATA[<p>Oh yes of course &#8211; now I see it. Well, that makes it indeed difficult to impossible to use paletteMap here. BTW &#8211; it looks like my code above was garbled by html.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: UnitZeroOne</title>
		<link>http://www.unitzeroone.com/blog/2008/05/06/opensource-image-dithering-for-as3-demosource/comment-page-1/#comment-977</link>
		<dc:creator>UnitZeroOne</dc:creator>
		<pubDate>Tue, 06 May 2008 16:39:59 +0000</pubDate>
		<guid isPermaLink="false">http://www.unitzeroone.com/blog/?p=155#comment-977</guid>
		<description>Good to hear it had some use ;-)

Posterization through paletteMap is implemented for the NO_DITHER mode...but...and here&#039;s where I stumbled upon trying to &quot;filterize+blendmode&quot; the whole thing...these error diffusion kernels iteratively add to the image per pixel...the kernel runs from top left to bottom right and adds to pixels in between, finding the best color for them after they have been error-diffused....so far I haven&#039;t come up with a blendmode + filter solution yet.</description>
		<content:encoded><![CDATA[<p>Good to hear it had some use <img src='http://www.unitzeroone.com/blog/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /> </p>
<p>Posterization through paletteMap is implemented for the NO_DITHER mode&#8230;but&#8230;and here&#8217;s where I stumbled upon trying to &#8220;filterize+blendmode&#8221; the whole thing&#8230;these error diffusion kernels iteratively add to the image per pixel&#8230;the kernel runs from top left to bottom right and adds to pixels in between, finding the best color for them after they have been error-diffused&#8230;.so far I haven&#8217;t come up with a blendmode + filter solution yet.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mario Klingemann</title>
		<link>http://www.unitzeroone.com/blog/2008/05/06/opensource-image-dithering-for-as3-demosource/comment-page-1/#comment-975</link>
		<dc:creator>Mario Klingemann</dc:creator>
		<pubDate>Tue, 06 May 2008 16:09:36 +0000</pubDate>
		<guid isPermaLink="false">http://www.unitzeroone.com/blog/?p=155#comment-975</guid>
		<description>Great job - works smoothly in Peacock already. 

Just as an idea - how about adding the option to provide a custom color palette?

I haven&#039;t tried it, but it might speed up your code event a little bit more if you use paletteMap first to do the quantization - here&#039;s a posterization code from Peacock:

var levels:Number = __parameters.getValue(&quot;levels&quot;);
var r:Array = [];
var g:Array = [];
var b:Array = [];
var a:Array = [];
					
var vStepF:Number = 255 / levels;
var vStep:int = 0.5 + vStepF;
var v:int = 0;
for (var i:int = 0;i255) v=255;
     a[i] = v &lt;&lt; 24;
     r[i] = v &lt;&lt; 16;
     g[i] = v &lt;&lt; 8;
     b[i] = v;
}
					
output.paletteMap(output,output.rect, origin,r,g,b,__parameters.getValue(&quot;posterizeAlpha&quot;) ? a : null);</description>
		<content:encoded><![CDATA[<p>Great job &#8211; works smoothly in Peacock already. </p>
<p>Just as an idea &#8211; how about adding the option to provide a custom color palette?</p>
<p>I haven&#8217;t tried it, but it might speed up your code event a little bit more if you use paletteMap first to do the quantization &#8211; here&#8217;s a posterization code from Peacock:</p>
<p>var levels:Number = __parameters.getValue(&#8220;levels&#8221;);<br />
var r:Array = [];<br />
var g:Array = [];<br />
var b:Array = [];<br />
var a:Array = [];</p>
<p>var vStepF:Number = 255 / levels;<br />
var vStep:int = 0.5 + vStepF;<br />
var v:int = 0;<br />
for (var i:int = 0;i255) v=255;<br />
     a[i] = v &lt;&lt; 24;<br />
     r[i] = v &lt;&lt; 16;<br />
     g[i] = v &lt;&lt; 8;<br />
     b[i] = v;<br />
}</p>
<p>output.paletteMap(output,output.rect, origin,r,g,b,__parameters.getValue(&#8220;posterizeAlpha&#8221;) ? a : null);</p>
]]></content:encoded>
	</item>
</channel>
</rss>
