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 / Objects Problem

Author
Message
Peter150
15
Years of Service
User Offline
Joined: 25th Nov 2008
Location:
Posted: 25th Nov 2008 21:26
Hey,

I've created a 2D game based on Sprites using DarkGDK before, and am wanting to try a 3D one.

The problem i'm having at the moment is that the objects appear to loose all their quality and the textures get mixed up.

I'm making the objects in a freeware program called "Object Creator" (I don't think its around any more, but i'm familiar with, and its easy to use) which exports the object as a .3ds file format.

This is the object in the editor:

http://i36.tinypic.com/2ijj94y.jpg

The object is not yet finished, i'm just testing whilst I make the object. If anyone is interested, the game is going to be a roller coaster simulator (i'm a coaster enthusiast ) and the object is the start of the station.

I had the problems with the file taking ages to load in DarkGDK, so i've used to Conv3ds.exe program to convert them to .x files, and that dramatically decreases the loading times.

When you view the object in the Direct X Viewer, it looks clean, sharp and smooth, as it should. The textures get messed up though, with the walls and fences taking on the wrong texture. You can see the object in the Direct X Viewer in the following pic:

http://i37.tinypic.com/v80f9s.jpg

When I come to load the object in DarkGDK with dbLoadObject(), the quality gets even worse, and the textures become 2D in a sort of way. The edges of the object become very sharp and flickery, as if it needs a bit of anti aliasing to smooth it. If I load the .3ds object rather than the .x object, it appears fine as it did in the editor at the very beginning.

You can see the .x version of the object in Dark GDK here:

http://i35.tinypic.com/2zod5ps.jpg

You can see a direct comparison between the .3ds and .x objects in the following screen shot. The air gate (the gate that lets people onto the ride) on the left is a .3ds, and the gate on the right is in the .x version. Note how the .3ds version has shadows and everything, whilst the .x version looks flat and 2D.

http://i35.tinypic.com/23mr7s8.jpg

Its also probably worth noting that light from dbMakeLight() has no effect on the .x object, but it does effect the .3ds object.

So my question is, does anyone know what might be causing this? My best guess is something wrong with the .3ds to .x conversion, but everyone is saying to use the Conv3ds.exe program, which is what i'm using. Is there a function in DarkDGK that renders the .x objects correctly that i'm just missing? Also, anyone know why the textures might be getting mixed around? Help!

Many Thanks. Hope I explained myself ok.
IanM
Retired Moderator
22
Years of Service
User Offline
Joined: 11th Sep 2002
Location: In my moon base
Posted: 26th Nov 2008 09:40
Try using the dbSetObjectFilter function to change the way the texture is used during rendering.

Another thing you could try is instead of using Conv3ds, load the object into a small GDK program, and then use the dbSaveObject function to save it as a .dbo file - they load faster than .x files, and load back exactly as you had them in your program, with all settings intact.

Morcilla
21
Years of Service
User Offline
Joined: 1st Dec 2002
Location: Spain
Posted: 26th Nov 2008 10:08
Try dbSetNormalizationOn() to see if that fixes the .x behaviour. Perhaps the object and/or its normals are too tiny

Login to post a reply

Server time is: 2024-09-30 11:29:30
Your offset time is: 2024-09-30 11:29:30