1 | initial version |
you should apply filter2D to a single channel float image, and the result will be in the same format, so you'll have to convert it back to CV_8U (maybe using scale & offset values) before putting it back into a bitmap, also Bitmap.Config.ARGB_8888
might be the wrong flag there (single channel).
also, i'm afraid, this won't give you a "better Canny" edge detection, but it will select only very specific edges by angle and size given in the getGaborFilter() params.