[AS3.0]Pixels2Object Class

Somehow i had the urge to do something with the color data from a BitmapData object.
The result is this little class that makes a 2D Array ( Object with arrays inside ) that containtains de values from every pixel inside the BitmapData object.



USAGE:
var newObj:Object = Pixels2Object.getPixels( image.bitmapData );
trace( newObj.row0 );
trace( newObj.row1 );
trace( newObj.row2 ); //you can output a row arrow with –> obj.row+number



Pixels2Object class:

View CodeACTIONSCRIPT

Comments are closed.


Categories
Archives
LinkedIn
R. Kollau