shapes3d
A library by Peter Lager for the programming environment processing. Last update, 09/26/2010.
This library is useful for any one wishing to do some 3D graphics/games programming in P3D or OPENGL modes. It not only provides a number of 3D shapes but enables simple creation of 3D terrain and a user controllable camera that can traverse over the terrain. Movement on the terrain can be clamped to prevent moving off the edges or wrapped so that as you move off the terrain your position is wrapped to the other side. The terrain class has a method to create a height map based on perlin noise that is seamless, this gives the impression of travelling over an infinite world.
To enable user interaction 2 simple methods are provided to enable shape selection. They both make use of a colour picking technique, first uses an off screen P3D buffer but is affected by the bug previously mentioned. The second uses the OPENGL drawing screen (can't have an off screen OpenGL buffer) so does cause a slight screen flicker when called. When the bug is fixed simply change the method called for 3D picking.
The library only uses Processing methods to access OpenGL commands so should be compatible with future releases of Processing.
Download
Download shapes3d version 1.9.2 in .zip format.
Installation
Unzip and put the extracted shapes3d folder into the libraries folder of your processing sketches. Reference and examples are included in the shapes3d folder.
Keywords opengl, shapes, drawing, 3D, components, processing, sketching
Reference. Have a look at the javadoc reference here. a copy of the reference is included in the .zip as well.
Source. The source code of shapes3d is available at google code, and its repository can be browsed here.
Examples
Find a list of examples in the current distribution of shapes3d, or have a look at them by following the links below.
Tested
Platform XP, Vista
Processing 1.2.1
Dependencies none