Page 1 of 1

DMF documentation question

PostPosted: Tue Oct 10, 2006 5:05 am
by cliff
Hi, there. I'm looking at the DMF documentation here, and comparing it to the DMF file I'm trying to work with and I find that the structure of each pixel seems to not quite be exactly as described. I notice that there seems to be a byte at the beginning of the section (usually a 0) and a byte missing at the end, making me wonder if things got re-ordered and just not documented.

Here's what I'm seeing:

00000000h: 4C 33 44 54 C8 00 00 08 00 01 00 1E 02 48 31 54
00000010h: 02 00 00 00 00 8A 02 47 55 53 02 00 00 00 00 DE

So, 4 bytes for the L3DT, 2 bytes for "200", 2 bytes for 2048, 2 bytes for 256... and then an extra zero before the first height value of 1E 02 (542 - the actual height at that position) but the datablock is still 10 bytes long, it just seems like it's out of order or something.

I'd use the provided DLL, but I'm writing my app in C# and it's more trouble to get it working with a native DLL than it is to just create a simple loop to do it myself.

PostPosted: Tue Oct 10, 2006 9:53 am
by Aaron
Hi Cliff,

Well spotted. There's an extra byte at the end of the header for the wrap state, so the header is actually 11 bytes (Eleven? What was I on at the time?!). I've updated the docs accordingly.

Best regards,
Aaron.