height and width keep changing for different sizes
Mat image = Mat::zeros(height, width, CV_8UC4);
image.data = framePtr;//data of height*width *4
cv::blur(image,image,cv::Size(image.cols,image.rows));
error -
terminate called after throwing an instance of ‘cv::Exception’
what(): OpenCV(4.5.0-dev) /root/Sudarshan/openCV/opencv/modules/imgproc/src/filter.simd.hpp:100: error: (-215:Assertion failed) this_.roi.x >= 0 && this_.roi.y >= 0 && this_.roi.width >= 0 && this_.roi.height >= 0 && this_.roi.x + this_.roi.width <= this_.wholeSize.width && this_.roi.y + this_.roi.height <= this_.wholeSize.height in function ‘FilterEngine__start’