如何增加/减lessUIImage的亮度,我需要保存最终的图像?

我有一个图像,我想改变它的亮度,我需要保存从实际图像获得的结果图像,我该怎么做。 我想使用UIslider增加亮度?

UIImage 这里获取Github的UIImage类别的代码。

要使图像变亮,请编写如下代码:

 //brighten value can be obtained from slider change event from -255 to 255. UIImage* brightImage = [originalImage brightenWithValue:sliderValue]; //Convert image into data NSData *brightImageData = UIImagePNGRepresentation(brightImage); //Get the path of Documents directory and store the data object to proper file 

以下是使用OpenGL ES1.1实现简单image processing滤镜(亮度,对比度,饱和度,色相旋转,锐度)的示例代码和说明。 我推荐你这个苹果的官方链接在这里