I am working on Video
based Application
in Swift iOS
. Where I am using AVPlayer
to play the Video
and setting
It seems like the CITemperatureAndTint filter is what you are looking for. I frankly don't know exactly how the parameters work, but maybe you can check out this or this related question.
Thanks @Frank Schlegel for direct me to CITemperatureAndTint
Filter with inputNeutral
and inputTargetNeutral
. Please see the below Core Image Filter Parameter to get Warm and Cold tone effect :
filter = CIFilter(name: "CITemperatureAndTint")!
//cold
filter.setValue(CIVector(x: 16000, y: 1000), forKey: "inputNeutral")
filter.setValue(CIVector(x: 1000, y: 500), forKey: "inputTargetNeutral")
//warm
filter.setValue(CIVector(x: 6500, y: 500), forKey: "inputNeutral")
filter.setValue(CIVector(x: 1000, y: 630), forKey: "inputTargetNeutral")