mirror of
https://github.com/greenshot/greenshot
synced 2025-07-16 10:03:44 -07:00
Fixed color count, the initially supplied code was only returning the amount of colors that was inputted which == width*height
git-svn-id: http://svn.code.sf.net/p/greenshot/code/trunk@1713 7dccd23d-a4a3-4e1f-8c07-b4c1b4018ab4
This commit is contained in:
parent
b464480bf6
commit
519e5b8ab2
2 changed files with 11 additions and 4 deletions
|
@ -106,8 +106,8 @@ namespace Greenshot.Helpers {
|
|||
LOG.InfoFormat("Image with format {0} has {1} colors", imageToSave.PixelFormat, colorCount);
|
||||
if (reduceColors || colorCount < 256) {
|
||||
try {
|
||||
LOG.Debug("Reducing colors on bitmap.");
|
||||
imageToSave = ImageHelper.Quantize((Bitmap)imageToSave, quantizer);
|
||||
LOG.Info("Reducing colors on bitmap to 255.");
|
||||
imageToSave = ImageHelper.Quantize((Bitmap)imageToSave, quantizer, 255);
|
||||
// Make sure the "new" image is disposed
|
||||
disposeImage = true;
|
||||
} catch(Exception e) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue