# Revision history [back]

This is a new overloaded member function since OpenCV 3.2. It means that you can provide an arbitrary gradient image such as the Scharr gradient to the Canny edge detector using the dx and dy function parameters (initially it was only Sobel).

It doesn't even have to be a standard edge detector. For instance: if you only wanted to detect horizontal edges you could provide dy as a set of zeros and just provide dx by running a gradient filter over the image.

 2 No.2 Revision sturkmen 6772 ●3 ●48 ●79 https://github.com/stu...

This is a new overloaded member function since OpenCV 3.2. It means that you can provide an arbitrary gradient image such as the Scharr gradient to the Canny edge detector using the dx and dy function parameters (initially it was only Sobel).

It doesn't even have to be a standard edge detector. For instance: if you only wanted to detect horizontal edges you could provide dy as a set of zeros and just provide dx by running a gradient filter over the image.

This is a new overloaded member function since OpenCV 3.2. It means that you can provide an arbitrary gradient image such as the Scharr gradient to the Canny edge detector using the dx and dy function parameters (initially it was only Sobel).
It doesn't even have to be a standard edge detector. For instance: if you only wanted to detect horizontal edges you could provide dy as a set of zeros and just provide dx by running a the appropriate gradient filter over the image.