mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Fix that comment ;).
This commit is contained in:
parent
43d53f8dbe
commit
474d76e645
@ -74,7 +74,7 @@ static uint8_t
|
|||||||
// c = ClampToQuantum((l+(t >= map[(x % mw) + mw * (y % mh)])) * QuantumRange / (L-1));
|
// c = ClampToQuantum((l+(t >= map[(x % mw) + mw * (y % mh)])) * QuantumRange / (L-1));
|
||||||
uint32_t q = ((l + (t >= threshold_map_o8x8[(x & 7U) + 8U * (y & 7U)])) * 17);
|
uint32_t q = ((l + (t >= threshold_map_o8x8[(x & 7U) + 8U * (y & 7U)])) * 17);
|
||||||
// NOTE: We're doing unsigned maths, so, clamping is basically MIN(q, UINT8_MAX) ;).
|
// NOTE: We're doing unsigned maths, so, clamping is basically MIN(q, UINT8_MAX) ;).
|
||||||
// The only overflow we should ever catch should be for a few black (v = 0xFF) input pixels
|
// The only overflow we should ever catch should be for a few white (v = 0xFF) input pixels
|
||||||
// that get shifted to the next step (i.e., q = 272 (0xFF + 17)).
|
// that get shifted to the next step (i.e., q = 272 (0xFF + 17)).
|
||||||
return (q > UINT8_MAX ? UINT8_MAX : static_cast<uint8_t>(q));
|
return (q > UINT8_MAX ? UINT8_MAX : static_cast<uint8_t>(q));
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user