Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
QM translation of C++
#5
that's exactly where i'm lost, even with extensive researches.

Quote:wBitrate offset = 5. Without it would be 6.

i must then suppose that the compiler would align automagically bymode to 2 byte to fit alignment of WORD wBitrate and that the C headers use pragma to
force it to be it's "right" alignment (for memory saving i guess)?



as
DWORD dwSampleRate => size 4 bytes offset 0

BYTE byMode => size 1 byte offset 4

WORD wBitrate size 2 bytes, offset should be 5 not 6 (4+1)

i will play with sizeof(i 'm away from my laptop right now) later to understand.

Quote:>would it be possible to invert bymode and wBitrate
no.

why? the order of the variables does not seem to be important...


Messages In This Thread

Forum Jump:


Users browsing this thread: 8 Guest(s)