Basic image processing - pixel operations and error diffusion