I want to do a bilateral filter and my image has to be type CV_8UC1/C3 for this.
To convert it would appear I have to use convertTo, but this is simply not working.
This is what I am doing:
Mat Temp= Mat(CurrentMat.size(),CV_8U); CurrentMat.convertTo(Temp,CV_8UC3); Mat Result=Temp.clone(); qDebug()<<cv_8uc1<<cv_8uc3; qdebug()<<"type"<<temp.type()<<result.type()<<currentmat.type();="" qdebug()<<"data"<<result.data<<currentmat.data;<="" p="">
bilateralFilter ( CurrentMat, Result, 5, 15, 15 );
Via the output I can clearly see that the type of Temp is 24 and not 0 or 16 which it should become.
Appreciated.