Week1/MathOperationsOnImages/DataTypeConversion/Utiliies.cpp
// Add the offset for increasing brightness
Add the offset for increasing brightness
Add the offset for increasing brightness
const cv::Mat Utilities::BruteforceBrightness(const cv::Mat mat, const int brightnessOffset) {
    cv::Mat brightHigh = mat.clone();
    cv::Mat brightHighChannels[3];
    split(brightHigh, brightHighChannels);
    for (int i = 0; i < 3; i++) {
        add(brightHighChannels[i], brightnessOffset, brightHighChannels[i]);
    }
    merge(brightHighChannels, 3, brightHigh);
    return brightHigh;
}
const cv :: Mat Utilities :: BruteforceBrightness ( const cv :: Mat mat , const int brightnessOffset ) { cv :: Mat brightHigh = mat . clone ( ) ; cv :: Mat brightHighChannels [ 3 ] ; split ( brightHigh , brightHighChannels ) ; for ( int i = 0 ; i < 3 ; i ++ ) { add ( brightHighChannels [ i ] , brightnessOffset , brightHighChannels [ i ] ) ; } merge ( brightHighChannels , 3 , brightHigh ) ; return brightHigh ; }
Add the offset for increasing brightness
Add the offset for increasing brightness