When applying this gradient to UIImages: ``` swift image.apply(gradientColors: [UIColor.yellow, UIColor.red], locations: [1.0, 0.0]) ``` I would expect the whole image to be covered by the gradient since the colors are completely opaque. However, it does sometimes seem to apply a strange blend mode, although the blend mode is left to the default value (CGBlendMode.normal). See on the following example: the gradient is wrong on the 1st image, but correct on the 2nd image. <img width="612" alt="screenshot 2016-10-10 16 40 23" src="https://cloud.githubusercontent.com/assets/1684627/19240036/eec4b396-8f08-11e6-8ea6-721958085734.png"> Here is a second example with the following gradient: ``` swift image.apply(gradientColors: [UIColor.black, UIColor.black], locations: [1, 0]) ``` The 1st image is correct but the 2nd seems to be a negative. <img width="513" alt="screenshot 2016-10-10 16 48 04" src="https://cloud.githubusercontent.com/assets/1684627/19240125/5a475ccc-8f09-11e6-9ac8-0bafda094803.png"> I am using `ImageHelper.swift` and `ImageVIewExtension.swift` from `master` (24581b119aa6c847213727b67eced3690171820d)
Activity
carole-lavillonniere commentedon Oct 12, 2016
Not sure what the line 114 of
ImageHelper.swiftis for, but removing it fixes the issue.