status=MagickFalse;
}
image_view=DestroyCacheView(image_view);
- image->type=image->alpha_trait == UndefinedPixelTrait ? ColorSeparationType :
- ColorSeparationAlphaType;
+ image->type=image->alpha_trait == UndefinedPixelTrait ?
+ ColorSeparationType : ColorSeparationAlphaType;
if (SetImageColorspace(image,colorspace,exception) == MagickFalse)
return(MagickFalse);
return(status);
assert(exception->signature == MagickCoreSignature);
if (image->colorspace == colorspace)
return(MagickTrue);
- image->colorspace=colorspace;
image->rendering_intent=UndefinedIntent;
image->gamma=1.000/2.200;
(void) ResetMagickMemory(&image->chromaticity,0,sizeof(image->chromaticity));
type=image->type;
if (IsGrayColorspace(colorspace) != MagickFalse)
{
- if ((image->intensity == Rec601LuminancePixelIntensityMethod) ||
+ if ((IsRGBColorspace(image->colorspace) != MagickFalse) ||
+ (image->intensity == Rec601LuminancePixelIntensityMethod) ||
(image->intensity == Rec709LuminancePixelIntensityMethod))
image->gamma=1.000;
type=GrayscaleType;
image->chromaticity.white_point.y=0.3290;
image->chromaticity.white_point.z=0.3583;
}
+ image->colorspace=colorspace;
status=SyncImagePixelCache(image,exception);
image->type=type;
return(status);
if ((image->colorspace == GRAYColorspace) && (image->gamma != 1.0) &&
(colorspace == sRGBColorspace))
return(SetImageColorspace(image,colorspace,exception));
+ if ((image->colorspace == RGBColorspace) && (image->gamma != 1.0) &&
+ (colorspace == RGBColorspace))
+ return(SetImageColorspace(image,colorspace,exception));
+ if ((image->colorspace == RGBColorspace) && (image->gamma == 1.0) &&
+ (colorspace == GRAYColorspace))
+ return(SetImageColorspace(image,colorspace,exception));
if (colorspace == UndefinedColorspace)
return(SetImageColorspace(image,colorspace,exception));
/*