mirror of
https://github.com/gnustep/libs-back.git
synced 2025-05-30 08:51:03 +00:00
Correct test for the need of an image conversion.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/back/trunk@27279 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
8d8d64823a
commit
70ede5cb90
2 changed files with 7 additions and 2 deletions
|
@ -140,7 +140,7 @@
|
|||
bitmap = (NSBitmapImageRep*)imageref;
|
||||
colorSpaceName = [bitmap colorSpaceName];
|
||||
if ([bitmap isPlanar] || ([bitmap bitmapFormat] != 0)
|
||||
|| ([bitmap bitsPerPixel] != 8) ||
|
||||
|| ([bitmap bitsPerSample] != 8) ||
|
||||
(![colorSpaceName isEqualToString: NSDeviceRGBColorSpace] &&
|
||||
![colorSpaceName isEqualToString: NSCalibratedRGBColorSpace]))
|
||||
{
|
||||
|
@ -150,7 +150,7 @@
|
|||
NSString *colorSpaceName = NSCalibratedRGBColorSpace;
|
||||
NSBitmapImageRep *new;
|
||||
|
||||
new = [bitmap _convertToFormatBitsPerSample: bitsPerSample
|
||||
new = [bitmap _convertToFormatBitsPerSample: bitsPerSample
|
||||
samplesPerPixel: samplesPerPixel
|
||||
hasAlpha: [bitmap hasAlpha]
|
||||
isPlanar: isPlanar
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue