Adapting source code to rotate 3-D mesh

1 reply [Last post]
Pi
User offline. Last seen 9 years 33 weeks ago. Offline
Joined: 04/26/2012
Posts:

Can anyone familiar with the source code for molecules help me here?

I am making an iOS application which needs to let the user freely rotate a 3-D model in a window. This is basically going to be a textured triangle mesh.

Would it make sense to use this project as a base?

PS Hi Brad if you are reading this; I've come to recognise you as one of the elders on Stack Overflow -- always fantastic to see what you guys get up to :) thanks for enriching the community!

Brad Larson
Brad Larson's picture
User offline. Last seen 4 years 51 weeks ago. Offline
Joined: 05/14/2008
Posts:

I would not recommend using the Molecules code as a starting point, because it's too complex for what you want to do. In particular, the OpenGL ES 2.0 rendering engine is really only suited to the visualization of spheres and cylinders, not arbitrary meshes.

Instead, I'd recommend starting from this simple example of a rotating cube in OpenGL ES 1.1 and 2.0, or this iPad OpenGL ES 2.0 teapot exposed to various shaders. Both of those can easily be adapted to support meshes.

Syndicate content