http://bugs.winehq.org/show_bug.cgi?id=7643
------- Additional Comments From hverbeet@gmail.com 2007-12-03 19:24 ------- I did some testing, and it turns out that's not completely correct either.
The correct way is "((top/4) * pitch) + (left * 4)" for DXT2-5 and "((top/4) * pitch) + (left * 2)" for DXT1.
eg. if you do LockRect with top = 60 and left = 60, that's 15 4x4 blocks down from the top. It's also 15 4x4 blocks from the left, but each 4x4 block consists of 16 bytes for DXT2-5 so you end up with "(left/4) * 16", which simplifies to "left * 4". DXT1 has only 8 bytes per block, so that becomes "left * 2".