I want to create a matrice in opencv for my project of raytracing. This is the code I have come up:
#include "Windows.h"
#include "core/mat.hpp"
#include "core/core.hpp"
#include "core/types_c.h"
using namespace cv;
Mat createImage()
{
Mat b(480, 640, CV_8UC3);
return b;
}
And I have problem with the two Mat. It says variable has incomplete type "cv::Mat"
. I can't understand what it means. I always wrote only Mat nothing else.
Can someone help me please?
Just include "opencv2/core/core.hpp".
You can use below example code.
#include "opencv2/core/core.hpp"
using namespace cv;
Mat createImage()
{
Mat b(480, 640, CV_8UC3);
return b;
}
int main()
{
createImage();
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With