Not 3D game.. but 3D rendering..

Hi all,
  We need to create a software which can 3D render house interior (like kitchens and bedrooms ) and so it can do jobs like.. change colour of the table or a sofa.. or replace the texture of the wooden floor... and probably replace a chair and another kind of chair "easily" wanna know what 3D tools should i use to create the software? We normally write our softwares using VC++ 6.0. This project will be done by 1-2 ppl only.. and we have no 3D programing skills at all.. so..
I heard that OpenGl and Direct3D are the 2 most commmon choices.. so.. which should one i choose? any ad/disadanvatage of each inidividualy language? how difficult would it be for us? and how to get it started??

I really need someone to give me some hints/guides so that i know from where should i start...
Who is Participating?
spilockeConnect With a Mentor Commented:
Hi rw8,

You need textures, shadows and reflections to appear in your picture. This all actually refers more to realistic renderings than those produced by OpenGL and Direct3D.
Sure you get shadows, textures and reflections with OpenGL and Direct3D but they are not realistic enough.

In OpenGL you defined 3D objects by their vertices or predefined shapes something like below.

      glRotatef( theta, 0.0f, 0.0f, 0.1f );
      glBegin( GL_TRIANGLES );
      glColor3f( 1.0f, 0.0f, 0.0f ); glVertex2f( 0.0f, 1.0f );
      glColor3f( 0.0f, 1.0f, 0.0f ); glVertex2f( 0.87f, -0.5f );
      glColor3f( 0.0f, 0.0f, 1.0f ); glVertex2f( -0.87f, -0.5f );

You get a flat triangle. You will need to write a porgram to model out your items ( Chairs, Tables, Cups ) or you can predefined the items and provide a view for them to populate into your virtual house.

Actually, povray provides a scripting like language called scene description language which you can just summit to the povray.exe to render out a scene realistically. It looks something like this.

#include ""
#include ""
#include ""

camera {
     location <0,0.5,-7>
     look_at <0,0,0> }

light_source { <100,140,-300> color White}

plane { <0,1,0>,-1
     texture {
     pigment {color Silver}
     normal {bumps 0.5 scale .8}
     finish {phong 1 reflection .5 ambient 0.4 diffuse 0.2} } }

sphere { <0,0,0>,1
     texture {
     pigment { color Blue }
        finish { reflection 0.2 diffuse 0.1 ambient 0.8 phong .8 } } }

This renders out a blue sphere with a flat bump floor.
You don't need to compile the description language. Save it in a file (test.pov) and just pass it in command line (DOS version):

 povray.exe +itest.pov +otest.tga +w320 +h240

You will get a 320 x 240 TGA image ready.
So you can describe a chair by putting boxes together or by their individual vertices and even with their textures.
Try to take a look of sample pictures produced by povray users and sample codes, you will get the idea.

Well, what I am trying to say here is I can see 2 clear parts to your program.
1. The modeller
2. The renderer

You can use OpenGL for the interactive modelling part. The user will be able to place chairs, cups and tables in the virtual 3D environment. You get to see your house with texture and shadows but the renderings produced are not accurate and game like. You can stop here if you want to. But if you want to further on, then just grab the info produced by OpenGL, translate it to Povray format and pass it to povray to render it out. Here you get a nice accurate shadows, textures, reflections and other stuffs.

Hope this helps.

You are taking on a HUGE task ... why not get a free copy of strata3d ... and away you go ... you can achieve the results u want with no programming .

But if u want to write your own code, download the latest DX8 SDK from microsoft and start from there ... there are samples and tutorials for C.
rw8Author Commented:
Which one is easier to learn and use? DX8 or OpenGL???
Upgrade your Question Security!

Your question, your audience. Choose who sees your identity—and your question—with question security.

Hi there,

Personally, I think OpenGL is easier to use than Direct X. But since you are a VC++ 6.0 programmer, I guess DirectX wouldn't be a problem.

OpenGL is just a graphic library. Include them in your program like any includes, study the functions and you are away. It includes translation, rotation and just about any helpful functions you might want. You can get information about OpenGL at along with samples and developers guide.

DirectX is a whole different story. It is a COM object. You need a very basic understanding of COM initialization and COM usage. It does provide 3D manipulation functions like OpenGL. You can get the infos at

OpenGL and DirectX are for realtime rendering usually used for games and other interactive 3D application. They give you game type of feel and image quality. From what I get from your question, you are more towards making a 3D renderer like Lightwave, Softimage, Maya and 3D Studio Max. You would want high quality 3D images to be rendered out to present to client. It is good to use OpenGL / DirectX for the part of providing the modelling interface for your client but then to render out realistic 3D images for presentation use you need something more powerful. You need a raytracing program/algo. Try looking at POVRAY at It is a freeeware, the source is distributed so you can compile it on virtually any platform.  

What we usually do is build the application in OpenGL/DX. Get the modellers and animation modules ready. Create object in modellers and animate them in the animator. We use OpenGL and Direct3D for all these to provide a realtime 3D interactive environment for the client to model their dream mesh and animate them if proper. Later when all the mesh ( kitchen, bedroom ) is in place ( saved in file ), we use a ray tracing algo to render them out. The quality of the 3D pictures rendered out are pretty much impressive but it takes lots of computer cal so do expect long hours for complicated scenes.

If you are more towards a 3D interactive environment type of application, then ray tracing need not apply.

Hope this helps.
rw8Author Commented:
Although i said i'm a VC++ programmer.. I've no experience at all in COM programming.  :(
Therefore.. is it better if i study OpenGL instead of DX??
and since the project i'm going to do is a commerical software, so future development and compatiblilty (with different software plaform and hardware) are very important to me...  

i assume i don't have to worri too much about these issues if i'm using DX because it is a microsoft thing. (i.e. they will support it and make it a standard thing)
Hi rw8,

Future development and compatibility with different platforms and hardware are important. DirectX only works with Windows only ( and XboX ). I don't think DirectX will ever appear on MacOS. OpenGL on the other hand, is multiplatform. It runs on Mac OS, OS/2, UNIX, Windows 95/98, Windows 2000, Windows NT, Linux, OPENStep, and BeOS.

Now on to the hardware stuffs. Graphic cards. Most hardware supports both OpenGL and DirectX. Microsoft is trying to have all cards having DirectX support but you have to know that OpenGL has been in the picture (1992) way long before DirectX come into picture. The OpenGL Architecture Review Board (ARB) has representatives from 3DLabs, ATI, Compaq, Evans & Sutherland, Hewlett-Packard, IBM, Intel, NVidia, Microsoft, and SGI to discuss and agree on Graphic Card standards and features.

Try working out in OpenGL first. I guess it is much easier to learn.
But I thought you are doing 3D rendering?
If that is the case, you should be looking into ray tracers and radiosity stuffs to render out high quality images. Otherwise you are limited to game like quality renderings.

Hope this helps.
I've an unfinished projet(OpenSource) using basic OPENGL if you want !(no rendering, just load somes 3dfile like 3dsASC,3ds ASE,MD3,OBJ,...).
rw8Author Commented:
spilocke:   the project need to be able to render pics of interior rooms (of predefined shape and furnitures within the room) according to the different colour and texture of furniture and paints they want to put to the room. And maybe able to change a coffee table to another shape or so....  
so.. i need to find a way that i can render and define the 3D objects easily (i.e. how to model chair and table..etc) so that i can get some other ppl to model different rooms for me..  
game like quality renderings?  um.. i don't think i need (and have the time and resource to do) Jurassic Park quality 3D rendering...   I think game like quality rendering is OK for me. I need texture, shadow, reflection..etc..

rw8Author Commented:
Thanx ! spilocke  :)
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.