I was trying to write an image to a folder using OpenCV imwrite function. The code compiles and runs successfully but the image is not saving in the folder/path.I am getting output from 'imshow' and my image is in CV_8UC1 format.
find the code below
Mat reflection = function which computes image
imshow("output image", reflection);
imwrite("E:/New folder/img.bmp", reflection);
so I checked current folder writing and modified code like this
bool check = imwrite("./img.bmp", reflection);
this 'bool check' status is 'false' and not writing the image.
I've also checked folder permission with guidelines from microsoft help my "E/New Folder/" is permitted to write. still, the image is not saving. I am okay with any image format .jpg, .png and .bmp. I am using windows 7, OpenCV 3.0, visual studio 2017.
Please help me and thanks for reading it
imwrite("E:/New folder/img.png", reflection);
instead? – Micka