imread not reading in BMP [closed]
Hello all,
I'm trying to read in a .bmp file using the following code:
cv::Mat image1 = cv::imread("SmallDog.bmp", CV_LOAD_IMAGE_COLOR);
And it is failing everytime. I can read in .jpg files just fine, but I need to load in a bmp file, as the noise library and texture generator I have writes to .bmp files and I plan to stitch generated bmp textures together. I can't get past this though -_- Any suggestions you may have are greatly appreciated
And yes, the directory location in Visual Studio is fine. I tested it with a few different file formats, and .bmp is the only one giving me issues (of course the one I need haha)
If you have check pass( mean in same folder you can read SmallDog.jpg and not SmallDog.bmp). Can you read with paint? I can read bmp image on windows 10 wit vs 2013 and opencv 3.0 using flag cv::IMREAD_UNCHANGED. But I don't think changing flag will change results.
bmp decoder is in file opencv\modules\imgcodecs\src\grfmt_bmp.cpp
I'm running opencv 2.4.9 Could this be an issue?
Also yeah for some reason even if I open up the bmp in paint, save it out as a jpg and try and load it it still won't work. I can load an image that was originally a jpg that I downloaded online just fine though
About opencv 2.4.9 my level is before beginner I cannot help you.
Which is your platform windows or linux?
What is the error mesage? Maybe it is not a 8-bit image