SVG filter comes with a set of fast operators to detect edge on map layers.
Filter:
The Laplacian operator uses a single 3×3 kernel to detect edges.
-1 -1 -1 -1 8 -1 -1 -1 -1or
0 -1 0 -1 4 -1 0 -1 0
the operator uses two 3×3 kernels which are convolved with the original image to calculate approximations of the derivatives - one for horizontal changes, and one for vertical.
+1 0 -1 +1 0 -1 +1 0 -1&
+1 +1 +1 0 0 0 -1 -1 -1
the operator the following two kernels.
+1 0 0 0 0 0 0 0 -1&
0 0 +1 0 0 0 -1 0 0
The operator uses two 3×3 kernels which are convolved with the original image to calculate approximations of the derivatives – one for horizontal changes, and one for vertical
+1 0 -1 +2 0 -2 +1 0 -1&
+1 +2 +1 0 0 0 -1 -2 -1