17 March 2008

Dithering in actionscript 3.0

I had to convert some images from color to monochrome while keeping as much detail as possible therefore I had to dither images.

The closest thing in as3 I found was this experiment on Sephiroth's website. You can read his blog entry here.

These are some pretty nice experiments, but not quite what I needed. So there was some research going on and the result is this:

Some of the algorithms were ported in as3 from pseudo code and explanations found in the following resources: this, this , this, this, this, and this

This port would not be possible without the help of Iulia Nastasoiu - Java developer, singer, dancer and ocasional philosopher and Teodor Stoenescu - programmer, drummer and general wise ass. Check out Pandrea for a heavy dose of 'mioritic metal'

I found the image in one of the sites listed above and I see it as a 'Hello World!' of the dithering algorithms

You can view code here


Ralph Hauwert, a very important contributor to the Papervision3D project ( thank you for the cool materials and shaders ) has his own Dithering experiments.

There might be some confusion, so I'll try to break it down. I needed a monochrome dithered image resulting from any given image, so my version is thought for only one color. Ralph's version supports colour. For further info on his implementation I advise you to read his blog entry here

You can find his classes on Google Code



radu narcis said...

si nu existau alte programe dedicate, decat flash? :D

bine .. fiecare cu ce-l doare.

George Profenza said...

Ai dreptate, dar aveam nevoie de ceva dinamic pt o aplicatie in care userul upload-a imaginea. Daca puneam in help o rubrica despre cum sa instaleze si sa foloseasca vreun soft pt dithering si pe urma sa foloseasca aplicatia, nu cred ca ajuta prea mult. Oricum era ceva care ma interesa de mult, dar nu aveam habar cum se face :)