views:

409

answers:

9

One thing I always shy away from is 3d graphics programming, so I've decided to take on a project working with 3d graphics for a learning experience. I would like to do this project in Linux.

I want to write a simple 3d CAD type program. Something that will allow the user to manipulate objects in 3d space. What is the best environment for doing this type of development? I'm assuming C++ is the way to go, but what tools? Will I want to use Eclipse? What tools will I want?

+8  A: 

OpenGL/SDL, and the IDE is kind-of irrelevant.

My personal IDE preference is gedit/VIM + Command windows. There are tons of IDE's, all of which will allow you to program with OpenGL/SDL and other utility libraries.

I am presuming you are programming in C, but the bindings exist for Python, Perl, PHP or whatever else, so no worries there.

Have a look online for open-source CAD packages, they may offer inspiration!

Another approach might be a C#/Mono implementations ... these apps are gaining ground ... and you might be able to make it a bit portable.

Aiden Bell
using pure OpenGL would be hard to implement..
ufukgun
@ufukgun: How so?
EFraim
+3  A: 

For the 3D part, I strongly recommend the SDL Library with the OpenGL library

You can get some tutorials here

ThibThib
+2  A: 

Qt has a pretty decent OpenGL-based graphics module.

Mike McQuaid
+2  A: 

Maybe you should consider using a graphics rendering engine such as OGRE. Coding a CAD program from scratch using OpenGL will take lots of time.

Cagdas Altinkaya
+1  A: 

you may use OpenSceneGraph for rendering.. it is an OpenGL based library..

and you may use OpenCascade.. it is good for 3D modelling...

we are implementing such an IDE at work and we use these things.. using pure OpenGL may be hard for you... anyway you may try...

for interface it is good to use Qt..

and i suggest you to use Eclipse if it is Linux..

(if it was Windows, suggestion would be Visual Studio)

ufukgun
hard is okay, i'm looking for hard
Max Schmeling
as u wish :)
ufukgun
A: 

For a C/C++ IDE, you have the following options:

Of course, you could also use a language like C# or Java:

There's really no reason why a simple CAD application would have to be written in C++.

jsight
+2  A: 

On Linux you have no competition to OpenGL.

It's one of the big players in the 3D field, so it's definitely worth learning.

This site has some excellent guides and code examples (on various languages).

You can use OpenGL with many languages, naturally on C and C++ but also for example with JAVA using LWJGL or other API's.

Liran Orevi
+3  A: 

It depends on what exactly you want to learn.
At the heart of the 3d stuff is openGL, there is really no competitor for 3d apps, especially on non-windows platforms.

On top of this you might want a scenegraph (osg, openscengraph, coin) - this handles the list of objects you want to draw, their relationship to each other in space the ability to move one relative to the others, selecting objects etc. It calls opengGL to do the actual rendering.

Then on top of this you need a gui library. Qt, Fltk, wxWigets or one built into the scene library or written directly in openGL. This handles the menus, dialogs frames etc of your app. It provides an openGL canvas to draw into.

Personal choices are openscenegraph and Qt

Martin Beckett
+2  A: 

If you want to program at "a higher level" than opengl, use vtk. It is quite easy to get started and has bindings to many languages.

See www.vtk.org

Torleif