Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

oh, you should give a number for ddepth, not a char !

Imgproc.Laplacian(matImageGrey8bit, laplacianImage, CvType.CV_8U);

totally amazing, that feeding '2' into it even worked ;)

('2' evaluates to 50, which is odd, so the least significant bits still evaluate to 0, while '1' evaluates to 49, so .. )

if your image is too dark, you probably need to play with the ksize,scale params


Mat matImageGrey = new Mat();
Imgproc.cvtColor(matImage,matImageGrey, Imgproc.COLOR_BGR2GRAY);
//Mat matImageGrey8bit = new Mat();         
//matImageGrey.convertTo(matImageGrey8bit, l);   // not needed, matImageGrey is already CvType.CV_8UC1