mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-22 17:52:42 +00:00
Merge branch 'master' into NSImageReps_branch
This commit is contained in:
commit
95dbcd2b40
2 changed files with 9 additions and 2 deletions
|
@ -1,3 +1,8 @@
|
|||
2019-12-02 Fred Kiefer <FredKiefer@gmx.de>
|
||||
|
||||
* Source/NSBitmapImageRep.m (-_convertToFormatBitsPerSample:...):
|
||||
Correct division by zero bug in image conversion.
|
||||
|
||||
2019-11-03 Riccardo Mottola <rm@gnu.org>
|
||||
|
||||
* Headers/AppKit/NSWorkspace.h
|
||||
|
|
|
@ -2429,7 +2429,8 @@ _set_bit_value(unsigned char *base, long msb_off, int bit_width,
|
|||
}
|
||||
fa = ia / _scale;
|
||||
|
||||
if ((_format & NSAlphaNonpremultipliedBitmapFormat) !=
|
||||
if ((ia != 0 && fa < 1.0) &&
|
||||
(_format & NSAlphaNonpremultipliedBitmapFormat) !=
|
||||
(bitmapFormat & NSAlphaNonpremultipliedBitmapFormat))
|
||||
{
|
||||
if (_format & NSAlphaNonpremultipliedBitmapFormat)
|
||||
|
@ -2568,7 +2569,8 @@ _set_bit_value(unsigned char *base, long msb_off, int bit_width,
|
|||
fv = iv / _scale;
|
||||
fa = ia / _scale;
|
||||
|
||||
if ((_format & NSAlphaNonpremultipliedBitmapFormat) !=
|
||||
if ((ia != 0 && fa < 1.0) &&
|
||||
(_format & NSAlphaNonpremultipliedBitmapFormat) !=
|
||||
(bitmapFormat & NSAlphaNonpremultipliedBitmapFormat))
|
||||
{
|
||||
if (_format & NSAlphaNonpremultipliedBitmapFormat)
|
||||
|
|
Loading…
Reference in a new issue