Re: MFC Porting Issues
Re: MFC Porting Issues
- Subject: Re: MFC Porting Issues
- From: Kevin Wojniak <email@hidden>
- Date: Fri, 20 Jan 2006 16:20:53 -0500
Thanks John. However, that didn't appear to make any difference. The
values are still not correct.
What I noticed though, on the 2nd iteration of the loop, "width",
"d2", and "blockLen" are the same, but the rest are different. Except
w1 on the Mac == bitDepth on the PC.. so that's very odd... it
doesn't make sense why the first time it works perfectly, and then
after that it gets messed up..
Kevin
On Jan 20, 2006, at 4:04 PM, John Stiles wrote:
Try this
#pragma pack(1)
typedef struct
{
BYTE b1[8];
DWORD height;
DWORD width;
WORD w1;
WORD bitDepth;
DWORD d2;
DWORD blockLen;
} IPOD_PICTURE_HEADER;
#pragma pack()
Kevin Wojniak wrote:
Oops, yes WORD = unsigned short, sorry.
I'm not sure what you mean by structure packing..
Also, no matter what value the loop starts off at (0, 4, 16, etc),
the structure appears identical to its PC equivalent at that same
iteration of the loop. But as soon as it increments and goes to
the next part of the loop, the values aren't correct. So I'm not
sure what's going on there..
Kevin
On Jan 20, 2006, at 3:52 PM, Shawn Erickson wrote:
On 1/20/06, Kevin Wojniak <email@hidden> wrote:
Here's the structure:
typedef struct
{
BYTE b1[8];
DWORD height;
DWORD width;
WORD w1;
WORD bitDepth;
DWORD d2;
DWORD blockLen;
} IPOD_PICTURE_HEADER;
BYTE = unsigned char
DWORD = unsigned long
WORD = unsigned char
What is sizeof(WORD) on Windows? I think is it larger the a byte.
Also what structure packing is being used or expected?
-Shawn
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40blizzard.com
This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden