I spent my Memorial Day evening setting up a PaperVision 3D project to serve as a demo for a customer and I just so happened to save the project as I was getting the basics implemented. I thought it would make a perfect blog post for those just getting started with PV3D.
The project covers moving the camera around in 3D space (including focusing in on objects) as well as object distribution including in a straight (horizontal) line and random distribution in 3D space (more screenshots after the jump).
There are two classes in this file, the first (called CustomCube) extends the PaperVision Cube class. This is very basic, the only custom code in here creates random colors for each face and sets a random X/Y position. The other class, which does all the heavy lifting, extends BasicView and includes an ArrayCollection to keep track of references to the CustomCube classes. This class has built in functions to move the camera and distribute CustomCube objects in 3D space.
I’m using the Tweener Libraries to move the camera and cubes.
Check it out below, source code included.
this is nice
Glad you liked it, you should check out part 2 for some more advanced features:
http://www.adambergman.com/2009/06/02/papervision-3d-cubes-part-2/