public void IccIsNullWithInvalidData() { var data = CreateTestData(); using var icc = SKColorSpaceIccProfile.Create(data); Assert.Null(icc); }
public void IccToXyzIsCorrect() { var path = Path.Combine(PathToImages, "AdobeRGB1998.icc"); using var data = SKData.Create(path); using var icc = SKColorSpaceIccProfile.Create(data); var xyz = icc.ToColorSpaceXyz(); Assert.Equal(SKColorSpaceXyz.AdobeRgb, xyz); }
public void IccCanBeConstructedFromData() { var path = Path.Combine(PathToImages, "AdobeRGB1998.icc"); using var data = SKData.Create(path); using var icc = SKColorSpaceIccProfile.Create(data); Assert.NotNull(icc); Assert.NotEqual(IntPtr.Zero, icc.Buffer); Assert.Equal(data.Size, icc.Size); }
public void USWebCoatedSWOPIsUnsupportedCMYK() { var path = Path.Combine(PathToImages, "USWebCoatedSWOP.icc"); var data = File.ReadAllBytes(path); var icc = SKColorSpaceIccProfile.Create(data); Assert.NotNull(icc); var colorspace = SKColorSpace.CreateIcc(icc); Assert.Null(colorspace); }