Dont understand: (x>>24)&0xff
This question already has an answer here:
Those are bitwise operations. p>>24 shifts first byte in p int 24 places to the right and &0xff performs bitwise and with shifted number and hexadecimal number ff(decimal 255). avg << 16 shifts first byte in avg int 16places to the left. And | performs bitwise or with other values. These are so called bitmasks. Search terms bitwise operations and bitmasks for more information. Hope i helped :)
链接地址: http://www.djcxy.com/p/12584.html上一篇: 为什么不移位工作
下一篇: 不明白:(x >> 24)&0xff