Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / dbLoadObject help

Author
Message
Jamie_Leigh
12
Years of Service
User Offline
Joined: 15th Dec 2011
Location:
Posted: 23rd Sep 2012 13:13
Hello everyone!

I've just started using Dark GDK for my next year at college and I have already encountered a problem. I cant seem to load a 3d model into my game.

Here is my code;


I have put the .x file in projects\thisproject\thisproject but all I see is a black screen when I go to debug the game. I have also tried putting the load object command in the main loop with no luck.

Thanks for your time
Matty H
15
Years of Service
User Offline
Joined: 7th Oct 2008
Location: England
Posted: 23rd Sep 2012 16:25
You need to call the function you have created. The program does not start at the top, it starts at 'void DarkGDK(void)'.



If you still get a black screen then your object has not loaded, an empty blue screen means it loaded but your camera is not pointing at it. If you see a gun then you're good

Jamie_Leigh
12
Years of Service
User Offline
Joined: 15th Dec 2011
Location:
Posted: 24th Sep 2012 12:02
Thanks for your help.

I have tried doing what you have suggested but with no luck, The screen is still black!
Matty H
15
Years of Service
User Offline
Joined: 7th Oct 2008
Location: England
Posted: 24th Sep 2012 15:56
Are you sure the model is in the correct place? It should be in the same directory as your main.cpp file for that project.

Rudolpho
18
Years of Service
User Offline
Joined: 28th Dec 2005
Location: Sweden
Posted: 24th Sep 2012 16:10
If the screen is indeed black I assume either the object is loaded and too close to the camera / the camera is inside the object or you are somehow not entering the main loop (calling sync).
Unless explicitly changed the 3d screen will be cleared to a blue colour (meaning the background will be drawn as blue).


"Why do programmers get Halloween and Christmas mixed up?"
Jamie_Leigh
12
Years of Service
User Offline
Joined: 15th Dec 2011
Location:
Posted: 25th Sep 2012 15:04 Edited at: 25th Sep 2012 15:04
It seems the fault was the .x and .3DS files I was using from the models folder that comes with Dark GDK.

I tried the models from the Dark Matter folder and they work fine.

Thanks for your help

Login to post a reply

Server time is: 2024-03-28 13:13:39
Your offset time is: 2024-03-28 13:13:39