PDA

View Full Version : 3D File to OpenGL c/c++ files



Ryan_WA
05-09-2007, 08:50 PM
I have a scene in Google SketchUp Pro and need to get it to a c/c++ file. I have been able to export to 3DS->.c through 3DWin - however, the file format is a pain. Does anyone know any better way to convert? Or, could anyone explain how the scene.c file works through the 3DWin converter?

I was thinking maybe .(some file)->Maya + c plugin->.c file.

Thanks.

def
05-10-2007, 01:09 AM
Originally posted by Ryan_WA:
Or, could anyone explain how the scene.c file works through the 3DWin converter?
Well, you will still need to do your own OpenGL programming! ;)
3DWin will only give you the 3d data organized into C structures. There is no actual code exported.
Use glDrawElements(...) to render the data in OpenGL. http://www.opengl.org/documentation/specs/man_pages/hardcopy/GL/html/gl/drawelements.html