/color_reducer

A small utility to reduce an image to a certain number of colors using a user provided palette

Primary LanguageC++

color_reducer

A small utility to reduce an image to a certain number of colors using a user provided palette

Usage: color_reducer input_file_name palette_image_file maximum_color_number output_file_name

For example: color_reducer main_menu.png sms_palette.png 16 main_menu_16.png

This call takes main_menu.png file and creates a new file (main_menu_16.png) where each pixel color is replaced by the closest color from the set extracted from sms_palette.png file and using at most 16 colors of this set.

It uses lodepng to load png files: http://lodev.org/lodepng/

Color Reducer license:

MIT License

Copyright (c) 2017

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.