problems with MapViewOfFile
the code :
short* sig = (short * ) MapViewOfFile (hCubeMapping,
FILE_MAP_COPY,
offset >> 32,
offset,
size);
works perfectly when offset = 0, but fails when offset is greater. I know that the offset must be a multiple of the allocation granularity (64K), but it returns NULL in any case. Please, help me to solve this problem
Re: problems with MapViewOfFile
Perhaps the problem is in your use of the Bitwise shift operator. I suspect that the dwFileOffsetHigh and dwFileOffsetLow aren't being set correctly. I think it works when offset is 0 because bit-shifting zero is still zero, however when you use a non-zero offset, the bitwise math is probably incorrect.
Good Luck.
John