Can I save the papervision 3d model as image in Flash CS6?

344 Views Asked by At

I am thinking to use Papervision 3d and Flash for my project.

I have doubt that Can I save the Papervision 3d model as image (JPG or PNG) in Flash CS6?

For example, I am going to import a model from blender, after that I will apply texture to that model. So the final result should save in my server as image (public_html/imageeditor/img/final.jpg) Is it possible ? If you have any tutorials or reference please provide me that can help me extra...

Thanks.

1

There are 1 best solutions below

0
redhotvengeance On

You can use BitmapData.draw to "snapshot" something on the stage into a Bitmap.

var container:Sprite = new Sprite(); //container 3D stuff will be in

//code putting the 3D stuff in the container

var snapshotBD:BitmapData = new BitmapData(container.width, container.height)
snapshotBD.draw(container);

From there, you can make a new Bitmap in AS3 of the image:

var bitmap:Bitmap = new Bitmap(snapshotBD);

Or save the image to the server like you would any other Bitmap in Flash.

For more info on BitmapData.draw, check out Adobe's docs.