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 .NET / Creating Object from Mesh

Author
Message
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 21st Nov 2009 22:01
I am trying to create an object from a mesh. The mesh has been created using DGK.net code and the contents look OK. However, if I create an object from the mesh, and save the object, I get no file at all. The object size is zero, any ideas where i an going wrong? Project attached, including mesh.



Attachments

Login to view attachments
APEXnow
Retired Moderator
21
Years of Service
User Offline
Joined: 15th Apr 2003
Location: On a park bench
Posted: 22nd Nov 2009 01:49
I'll take a look Batvink.

Paul.

APEXnow
Retired Moderator
21
Years of Service
User Offline
Joined: 15th Apr 2003
Location: On a park bench
Posted: 22nd Nov 2009 02:07
Batvink, can you test something for me. I noticed that you're attempting to create a Mesh from a .dbo file. Can you try this with an .X model file instead. When I tried to display the tempmesh.dbo file instead of the cube model in the sample application, it didn't display at all. I'm not sure if the Mesh constructor takes DBO files as an option. I thought that mesh objects were derived from .x model files.

Anyway, let me know what happens.

Paul.

BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 22nd Nov 2009 10:39
Paul, I tried this, it fails too using DB Primitives as the source:



BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 22nd Nov 2009 13:39
I have more info on where it goes wrong

This doesn't work:



But this DOES work...



So it looks like the class initiator that just accepts the mesh doesn't work. This is making more sense now, as my whole reason for running this test is that my objects don't appear on screen. Extending this test above, I get the same results - the object doesn't appear on screen unless it is created from the mesh WITH texture.

APEXnow
Retired Moderator
21
Years of Service
User Offline
Joined: 15th Apr 2003
Location: On a park bench
Posted: 22nd Nov 2009 15:28
I'm wondering if this is behaviour in the engine itself. Both constructors are basically calling into the engine code, so I'm wondering if you're up for it, to test the Interop function calls directly. This will at least rule out the possibility of the wrapper being bugged. I'll test this myself to see if there is a problem with the class rather than something in the main engine code.

Paul.

BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 23rd Nov 2009 22:06
I can try whatever, but you'd have to tell me what's needed, I'm a standard user of VB.net. If it helps, the last example uses standard primitives and should work for any test.

BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 29th Nov 2009 17:48
Mnemonix tried this for me in DGK - it doesn't work. Think these needs reporting as a bug in DGK, I'll get the code from him.

Login to post a reply

Server time is: 2024-04-16 10:40:50
Your offset time is: 2024-04-16 10:40:50