We purpose to carry out here a graphical user interface allowing to visualize and process images of standard format (bmp, png, gif, jpeg...). This gui has been coded in C++ with Qt framework. The image processing makes firstly reduce noise, detects vertical, horizontal gradients and edges. This chain is called "Canny Edge Detector". Thereafter, we will present another functionality whose goal is to apply this chain to video streaming with OpenCV library.
"Canny_Edge" application is available for Linux and MacOS :
For each step of processing chain, we apply a filter on 2D array which represents image. This linear filtering is performed with a discrete convolution operation on every pixel $X_{i,j}$ of original image :
with output image and filter (of size $n\,\text{x}\,n$) respectively represented by $Y$ and $H$ matrices. We can see in below parts the filters used like the blur mask and the horizontal/vertical gradient mask.
Before the gradients and edges detection by Sobel operators, we must first establish a procedure for Gaussian filtering with a "blur" mask (see Canny edge detector) size "5x5" which allows to remove disparities on image and reduce noise. Here's this filter :
At this step, we implement edges detection with Sobel operators. Firstly, on uses $H_{x}$ filter for horizontal gradients and $H_{y}$ for vertical gradients :
Then, one combines the result of these 2 filtering to compute the gradient norm; for each pixel $X_{i,j}$ computed with $H_{x}$ and $Y_{i,j}$ with $H_{y}$, the output value $Z_{i,j}$ for pixel $(i,j)$ is equal to :