How to edit hue saturation and luminance by using GPUImageFilters in android Java?

354 views Asked by At

I want to ajust the hue, saturation and luminace of an image for specific color shades using OpenGLES or GPUImageFilter.

It should basically like this enter image description here

1

There are 1 answers

1
Konstantin Raspopov On

Seems like there's no built-in functionality for it in this library. So, you can implement it yourself by extending GPUImageFilter and writing a corresponding shader.

You can reuse existing Hue, Saturation, and Luminance filters. The idea is simple - you're passing an additional parameter (color) to the shader. Based on this color and the color of the current pixel, you can choose if the current pixel should be affected by the shader or not.