Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

11
  • 1
    \$\begingroup\$ Is there any reason to limit file formats to JPG and requiring I/O to be through files, other than punishing/eliminating languages without image and file system manipulation libraries? Why not allow any true-colour raster format (so that one could use PPM for instance), and I/O as byte streams through STDIN/STDOUT? \$\endgroup\$ Commented May 17, 2015 at 0:04
  • \$\begingroup\$ @MartinBüttner: Is that better? \$\endgroup\$ Commented May 17, 2015 at 0:05
  • 2
    \$\begingroup\$ Yeah much better, although you still require I/O to be through files. \$\endgroup\$ Commented May 17, 2015 at 0:06
  • \$\begingroup\$ Per-pixel, it's supposed to use the nearest color in the list by the euclidean metric on RGB values. \$\endgroup\$ Commented May 17, 2015 at 0:09
  • 1
    \$\begingroup\$ Note that this is called posterization or color quantization. \$\endgroup\$ Commented May 17, 2015 at 1:05