我想实现Retinx理论以改善照明,在这个问题中,我找到了实施的步骤:
我为Android编写代码,但在该部分中,我标有“?”编译器给我一个错误,当我通过“Mat retinex”PLZ帮助我,伙计。
Mat mRgba,imgGray,imgCanny,imgYuv;
Mat gaussianFtr;
Mat retinx;
Mat retinxTotal;
mRgba=new Mat(height,width, CvType.CV_8UC4);
imgGray=new Mat(height,width, CvType.CV_8UC1);
imgCanny=new Mat(height,width, CvType.CV_8UC1);
imgYuv=new Mat(height,width, CvType.CV_8UC3);
gaussianFtr=new Mat();
retinx=new Mat();
retinxTotal=new Mat();
public Mat onCameraFrame(CameraBridgeViewBase.CvCameraViewFrame inputFrame) {
mRgba=inputFrame.rgba();
Imgproc.cvtColor(mRgba,imgYuv,Imgproc.COLOR_RGB2YUV);
Imgproc.GaussianBlur(imgYuv, gaussianFtr,new Size(45,45),0);
retinxTotal=255*(Math.log10(?))+127.5;
return gaussianFtr;
}
}