1 | initial version |
Basically this first hit from google explains what the functions do, and how they should be implemented.
It is in fact a simple mapping of values, which can be implemented by writing a pixel value conversion function for each color channel. Keep in mind with this that the color channels are BGR in OpenCV and not RGB.