Using 3ds Max and OpenGL

Started by
14 comments, last by Aks9 12 years, 10 months ago
Heey guys,

I am kinda new to graphics and game programming and my question is pretty simple. We need to make a 3d model of our school and decided to make use of opengl and 3ds max. But is it possible to use 3ds max models in opengl? Can it be done with the help of Maxscript, in that case I am prepared to learn maxscript. How do professional game developers do that?
I know this question has been asked in previous topics, but these are all outdated and the answers are not very straight to the point. That's why I am asking again.

Thanks for your help.
Advertisement
most likely.
im pretty shure 3DS Max can export to a number of supported formats :)

Never say Never, Because Never comes too soon. - ryan20fun

Disclaimer: Each post of mine is intended as an attempt of helping and/or bringing some meaningfull insight to the topic at hand. Due to my nature, my good intentions will not always be plainly visible. I apologise in advance and assure you I mean no harm and do not intend to insult anyone.

I know 3ds max can export to several different formats, but how are these to be used with opengl? I don't think opengl can open any of these files (or can it?). That's why I was wondering what the use of maxscript was in all of this.
there hould be some type of Load method.
i have not used OpenGL yet.

Never say Never, Because Never comes too soon. - ryan20fun

Disclaimer: Each post of mine is intended as an attempt of helping and/or bringing some meaningfull insight to the topic at hand. Due to my nature, my good intentions will not always be plainly visible. I apologise in advance and assure you I mean no harm and do not intend to insult anyone.

OpenGL is a rendering API. A rendering API does not deal with specific file formats, that would be task of a game engine, a scene manager or an utility library. There should be plenty of loaders out there which can load 3ds files to produce information that can be sent to OpenGL. Alternatively, Maxscript could be used to write custom mesh information which could be loaded by the program without implementing a complete 3ds loader or linking a library to do that job.
So, would you recommend Maxscript then?

So, would you recommend Maxscript then?


I have not used Maxscript for ages and don't remember much from it. Considering you sound like a beginner, I would advise against the double problem of implementing a writer in Maxscript and a corresponding loader in another language. I don't know to what formats 3ds exports to nowadays but there should be an option for something simple like Wavefront obj files. Writing a loader from scratch for that should be simpler if you don't have other alternatives, after all the format is a readable text file.
As BitMaster said OpenGL is for rendering only, it is your responsibility to load the data from whatever source you want. Maxscript is not a solution to this, Maxscript is for use within 3DS Max.

My suggestion would be to export as .OBJ (Wavefront Obj File) and use a prebuilt importer (there are hundreds on the web).
3ds Max does indeed export to .obj files. Is writing a loader very difficult and what does it require?
@AndyEsser, I read your comment too late, I see. Using the importer It is easy to use it in opengl (I assume).

This topic is closed to new replies.

Advertisement