OpenCL
output = dither_ATI(input);
Both output and input are float types.
The general idea is from [4] which pre-computes the scheduling and process independent data items in parallel.
Please refer to our published paper for detailed information.
INPUT IMAGE and OUTPUT IMAGE from MATLAB dither function:
OUTPUT IMAGE from GPU-accelerated dither implementation:
References:
1). Floyd, R. W., and L. Steinberg, "An Adaptive Algorithm for Spatial Gray Scale," International Symposium Digest of Technical Papers, Society for Information Displays, 1975, p. 36.
2). Lim, Jae S., Two-Dimensional Signal and Image Processing, Englewood Cliffs, NJ, Prentice Hall, 1990, pp. 469-476.
3). Matlab implementation (dither):
MATLAB\R2008a\toolbox\images\images\private\ditherc.c (ditherc.m)
4). Optimal Parallel Error-Diffusion Dithering, Proceedings of the 1999 Electronic Imaging, SPIE, San Jose, CA, January, 1999.