views:

66

answers:

3

I know that Floyd–Steinberg dithering algorithm can't be implemented with pixel shader, because that algorithm is strictly sequential. But maybe there exist some higly parallel dithering algorithm which by it's visual output is similar to Floyd-Steinberg algorithm ?

So the question is - What are dithering algorithms which are suitable to implement on pixel shader (preferably GLSL) and with output quality (very) similar to Floyd-Steinberg dithering ?

BTW. Multi-pass algorithms are allowed until there are not more than 2 passes and CPU overhead between those passes is small.

Any ideas ?

EDIT:
I need dithering from 24-bit color to 21-bit color.
(That is - i need to convert from 8 bits/channel to 7 bits/channel.)