Open daviddoria opened 13 years ago
line 185 of Label.cpp
The data is stored as a bit array (like a bool array, but there are 8 data points stored in each byte instead of just 1). The /8 determines which byte it is in. The &7 keeps the lower 3 bits, as there are only 8 bits in a byte so the shift output will be from 0 to 7. ?
it might help to think of the /8 as a >>3
and in that sense, an absolute 32-bit integer index resembles BBBBBBBBBBBBBBBBBBBBBBBBBBBBB.bbb where the Bs contain the byte index and the b's contain the bit indices within the byte
There is a 7 and 8 that should be commented.