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.

Author
Message
Andy Igoe
23
Years of Service
User Offline
Joined: 6th Oct 2002
Location: United Kingdom
Posted: 15th Sep 2003 16:45
I'm having some difficulty playing with memblock meshes for the first time.

I am creating an object using DB primitives then copying it into a memblock, when I read the information out the FVF format is 274 and not 338 - consequently I cannot read all the data. I get the same format by loading in a similarly designed object.

Does anyone know the FVF 274 format or can explain to me in simpletons terms just how I am being an idiot please?

Pneumatic Dryll
Beta 1
22
Years of Service
User Offline
Joined: 27th Aug 2003
Location:
Posted: 15th Sep 2003 17:28 Edited at: 15th Sep 2003 17:28
LOL. We seem to be doing the same thing!

Check the reply to when I posted almost the same question 2 days ago!

http://www.thegamecreators.com/?m=forum_view&t=16710&b=1
Van B
Moderator
23
Years of Service
User Offline
Joined: 8th Oct 2002
Location: Sunnyvale
Posted: 15th Sep 2003 19:34
The serious difference between 274 and 338 is the length, 338 is 36 bytes long, 274 is 32 bytes long - the missing 4 bytes are the vertice colours which are not in format 274 - but it's the length that'll cause all the problems. When I made my .X import function, I stepped through the data depending on the specified data chunk length, and had an if condition, if the format was 274, set this data, else set it this way. Note that both headers are layed out identically, so it's just the chunks that need attention.

338: (Data chunk pos)
Vert X# (0)
Vert Y# (4)
Vert Z# (8)
Normal X# (12)
Normal Y# (16)
Normal Z# (20)
Vert Colour (24 Dword)
UV X# (28)
UV Y# (32)
Next data chunk (36) - so 36 bytes long

274: (Data chunk pos)
Vert X# (0)
Vert Y# (4)
Vert Z# (8)
Normal X# (12)
Normal Y# (16)
Normal Z# (20)
UV X# (24)
UV Y# (28)
Next data chunk (32) - so 32 bytes long

HTH.


Van-B

My cats breath smells of cat food.
Andy Igoe
23
Years of Service
User Offline
Joined: 6th Oct 2002
Location: United Kingdom
Posted: 15th Sep 2003 19:40
My data seems to be consistent now although my UV data is peculiar and i'm pretty sure my Y data should all be 0 and not -200/+200, i'll make a form of visualisation later and check that the extracted data is OK - or i'll bang my head against a brick wall until programming no longer matters to me - one of the two...

You've both been most helpfull.

Pneumatic Dryll

Login to post a reply

Server time is: 2026-07-26 05:02:32
Your offset time is: 2026-07-26 05:02:32