Last active
September 22, 2018 16:45
-
-
Save nanoxd/a6aa222a2a1afa0cd38f96472e811e27 to your computer and use it in GitHub Desktop.
[UIImage+RenderMode] Easily use a different rendering mode on an UIImage #uikit #swift
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public extension UIImage { | |
public var original: UIImage { return withRenderingMode(.alwaysOriginal) } | |
public var template: UIImage { return withRenderingMode(.alwaysTemplate) } | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment