HIDIHO!

giving something back to the Flash community

icosahedron for pv3d

Tags: ,


a couple of weeks ago, somebody asked me how I would do an icosahedron in 3D, to which I answered “dunno, maybe I’d follow something that explains how to build it”, which I did thanks to that person :)

the icosahedron is a 20 faced polyhedra, it has some graphic qualities, is used in many generative creations. it’s also a very light (12 vertices, 20 faces) approximation of a sphere and a possible base for the geoshpere.

I found this detailed, step by step explanations and followed them.
it gave me this wonderful piece of 3D geometry:

after which I decided to create some UVS to map the mesh ; it goes like this.

uv map for the icosahedron
the checker picture comes from :http://www.uvmapper.com/help/menu_texture.html (yup, I was lazy enough not to create a mere checker…)
and once you’ve mapped the mesh, it gives something like:

here’s the texture, note that edges leak a bit, it’s supposed to be printed, cut and pasted ^^:

it comes from that wonderful DIY paper volumes resource: polyhedra pastimes.

here’s the class:

it extends TriangleMesh3D so you can instantiate it like this:

var icosa:Icosahedron = new Icosahedron( radius, MaterialObject3D );

I said it was a base for geospherisation, I’m not clever enough (and really lazy too) to create a real geospherical tessalation yet I’ve done a quick “face center split / create 3 faces” and the results are pretty graphic:

click anywhere to reset, change the texture with the buttons above.
there are 2 iterations of split, with a random radius to reposition the center vertices.
here are some snapshots I took:



der pate is going to punish me for not having done it for Away3D but who cares.
enjoy :)

Tags: ,

© 2009 HIDIHO!. All Rights Reserved.

This blog is powered by Wordpress and Magatheme by Bryan Helmig.