With this ActionScript 3.0 class you can extract the RGB channels of a specified Bitmap. After the extraction, which returns an array with the different color channels, you can use each color channel for animation, or combine the channels to create a fake 3D-effect like below or go nasty with your own ideas ….
If you have any 3D red cyan glasses lying around, go fetch them ….!
Hi Daan
I try to use your code, but actually i didn’t get a a real fake 3d like this http://www.flickr.com/photos/rawshooter72/5477138017/in/pool-52240974383@N01/lightbox/
or
http://farm6.static.flickr.com/5020/5477138017_0577623806_b.jpg
How to make a better result ?
I’m code in Flex
private function fake3d():void {
if (_rgb) {
for (var j:int = 0; j < _rgb.length; j++) { hasil.removeChildAt(_rgb[j]); }
}
_rgb = new Array();
_rgb = RGBSeparater.createRGBChannel(_image);
for (var i:int = 0; i < _rgb.length; i++) {
var bitmap_channel:Bitmap = new Bitmap(_rgb[i], "auto", true);
bitmap_channel.x = (hasil.width / 2 – bitmap_channel.width/2) – ((i == 0) ? 3 : -3);
bitmap_channel.y = hasil.height / 2 – bitmap_channel.height/2;
bitmap_channel.scaleX = bitmap_channel.scaleY = 1 + (i * .01);
bitmap_channel.blendMode = BlendMode.SCREEN;
hasil.addChildAt(bitmap_channel,0);
}
}
Thanks
Can you post an image preview of your current result, so i can see what your code is doing? With above code you should be able to produce a fake 3D effect …
Maybe try changing the Blend Modes of your channels, and try to reposition them …
Thanks for the response
here the result http://fathihadi.net/upload/3d.jpg
when i compare to this http://farm6.static.flickr.com/5020/5477138017_0577623806_b.jpg
it’s quite big different
Thanks
this is the coolest, thanks! Just what I was looking for. My Favorite Wife SMS
Thank YOu Very Much