Talk:Dither

4 bit example pictures
Would be interesting to see not dithered and dithered pictures with an unoptimized 16 colour vga standard palette. Sure, the first one will look terrible and the second on not really good, but they'll serve as good comparisons to the other pictures and show what's possible with very few colours.
 * i have several implementations of several dithering algorithms on my end, i would be happy to do this but can you please show me the "unoptimized 16 colour vga standard palette" ? google isn't being helpful lol
 * Marbelynrye (talk) 08:02, 28 June 2024 (UTC)


 * I think the 16-colour VGA palette only makes sense on an old-fashioned colour display that, compared to modern ones, emitted light much more like a lamp, and much less like a piece of paper.
 * They had the 8 basic colours that may be represented as 000000 (black), 0000FF (blue), 00FF00 (green), FF0000 (red), 00FFFF (cyan), FF00FF (magenta), FFFF00 (yellow) and FFFFFF (white). The other 8 colours were the same with extra highlight.
 * Now, in modern colour models you cannot add highlight to e.g. FFFFFF (white).
 * One could instead say that the 8 colour codes I listed are the highlighted ones, and the non-highlighted are the ones where you replace each FF by half (80, say). But that would not be quite right either, as the colours black-without-highlight, black-with-highlight, white-witout-highlight and white-with-highlight in fact formed a sort of greyscale.
 * The following is something I just made up, but it at least it seems consistent: The non-highlighted colours could be represented as 000000, 0000AA, 00AA00, AA0000, 00AAAA, AA00AA, AAAA00, AAAAAA, and the highlighted as 555555, 5555FF, 55FF55, FF5555, 55FFFF, FF55FF, FFFF55, FFFFFF. (Here, 55 is one third of FF, and AA is two thirds.) Nø (talk) 12:01, 28 June 2024 (UTC)
 * so like,
 * RGB(0 0 0 255)
 * RGB(0 0 255 1)
 * RGB(0 128 0 1)
 * RGB(255 0 0 1)
 * RGB(0 255 255 1)
 * RGB(255 0 255 1)
 * RGB(255 255 0 1)
 * RGB(255 255 255 1)
 * RGB(0 0 0 255)
 * RGB(0 0 127.5 255)
 * RGB(0 64 0 255)
 * RGB(127.5 0 0 255)
 * RGB(0 127.5 127.5 255)
 * RGB(127.5 0 127.5 255)
 * RGB(127.5 127.5 0 255)
 * RGB(127.5 127.5 127.5 255)
 * did 50% color mixes in RGB with black Marbelynrye (talk) 12:18, 28 June 2024 (UTC)
 * oops sorry for the tall reply, and ignore the alpha value Marbelynrye (talk) 12:20, 28 June 2024 (UTC)
 * here's how that looks like with floyd steinberg error diffusion and basic rgb euclidean distance Filename(1).pngSaulasldalsdlaldalsdlas.png Marbelynrye (talk) 12:26, 28 June 2024 (UTC)
 * oh shit i think i broke the layout of this page lmao Marbelynrye (talk) 12:26, 28 June 2024 (UTC)
 * No, as shown in my last paragraph I would go with the values 00, 55, AA, FF (hex) equal to 0, 85, 170, 255 (decimal), rather than 0, 127.5 and 255 (decimal) Nø (talk) 08:01, 1 July 2024 (UTC)
 * ah sorry i don't really understand hexes, i'll try to convert them Marbelynrye (talk) 11:00, 1 July 2024 (UTC)
 * is this right?
 * RGB(0, 0, 0),
 * RGB(0, 0, 170),
 * RGB(0, 170, 0),
 * RGB(170, 0, 0),
 * RGB(0, 170, 170),
 * RGB(170, 0, 170),
 * RGB(170, 170, 0),
 * RGB(170, 170, 170),
 * RGB(85, 85, 85),
 * RGB(85, 85, 255),
 * RGB(85, 255, 85),
 * RGB(255, 85, 85),
 * RGB(85, 255, 255),
 * RGB(255, 85, 255),
 * RGB(255, 255, 85),
 * RGB(255, 255, 255) Marbelynrye (talk) 11:10, 1 July 2024 (UTC)
 * Yes. As you said, there are no sources (or we haven't found them) giving such RGB codes for the standard 16-colour VGA palette, so it is based my recollection (which I am sure is fairly accurate) and then devising a scheme that is consistent with this. The exact values 85 and 170 could be different, and my assumption that highlighting adds a fixed values to each channel (R, G and B), irrespective of which colour we are considerng, could be different too; e.g., one could instead let the highlighted values be double the un-highlighted ones, except that would make "highlighted black" still black, and I am sure that would be incorrect. -- By the way, you may want to check out List of monochrome and RGB color formats, which, however, doesn't mention the 16-colour palette. Nø (talk) 13:16, 1 July 2024 (UTC)
 * one thing about dithering on wikipedia is that it's never mentioned how much impact the color difference formula might have on the output image, i would add examples of the differences but i have yet to implement all of them haha Marbelynrye (talk) 17:08, 1 July 2024 (UTC)
 * The black and white pictures are far more instructive, don't add this Spitzak (talk) 20:32, 1 July 2024 (UTC)
 * The black and white pictures are far more instructive, don't add this Spitzak (talk) 20:32, 1 July 2024 (UTC)

Frequency domain
I deleted the sentence about the ear being more sensitive in the frequency domain. I'm an electrical engineer and this statement makes no sense. Frequency and time domain are two ways of representing the SAME signal. — (unsigned comment by 195.243.189.189, 2005-12-21 01:41:21)

Sound files need explanation
The two sample sound files are an excellent addition but need more explanatory text. Has dithering been added to the second sample? If so, what kind of dithering? It would be ideal if there were three samples: 16 bit original, 6 bit without dithering, 6 bit with dithering. Ross Fraser (talk) 21:32, 21 July 2010 (UTC)


 * These sound files are not particularly illustrative. It sounds like the dithered version has more than 1 LSB of noise. It is hard to hear the difference between 16-bit and 6-bit truncated. Perhaps we should redo with 3 or 4 bit truncation and best practice for level and shape for the dithered version. ~Kvng (talk) 19:01, 22 December 2022 (UTC)

Audio Spectra wrong
Sorry, but the Audio spectrum is wrong, if the 500 Hz sine would be correctly dithered, no harmonics will be seen. Nothing. Only the added noise will remain. — Preceding unsigned comment added by 91.51.96.47 (talk) 16:51, 21 July 2012 (UTC)


 * I agree. There seems to be issues with these 6-bit examples. See my comments above. ~Kvng (talk) 19:04, 22 December 2022 (UTC)