OpenCvSharp.Cv2.IlluminationChange C# (CSharp) Method

IlluminationChange() public static method

Applying an appropriate non-linear transformation to the gradient field inside the selection and then integrating back with a Poisson solver, modifies locally the apparent illumination of an image.
This is useful to highlight under-exposed foreground objects or to reduce specular reflections.
public static IlluminationChange ( InputArray src, InputArray mask, OutputArray dst, float alpha = 0.2f, float beta = 0.4f ) : void
src InputArray Input 8-bit 3-channel image.
mask InputArray Input 8-bit 1 or 3-channel image.
dst OutputArray Output image with the same size and type as src.
alpha float Value ranges between 0-2.
beta float Value ranges between 0-2.
return void
        public static void IlluminationChange(
            InputArray src, InputArray mask, OutputArray dst,
            float alpha = 0.2f, float beta = 0.4f)
        {
            if (src == null)
                throw new ArgumentNullException(nameof(src));
            if (dst == null)
                throw new ArgumentNullException(nameof(dst));

            src.ThrowIfDisposed();
            dst.ThrowIfNotReady();
            if (mask != null)
                mask.ThrowIfDisposed();

            NativeMethods.photo_illuminationChange(
                src.CvPtr, ToPtr(mask), dst.CvPtr, alpha, beta);

            GC.KeepAlive(src);
            GC.KeepAlive(mask);
            dst.Fix();
        }
Cv2