I have a 8-bit image and I want to filter it with a matrix for edge detection. My kernel matrix is
0 1 0 1 -4 1 0 1 0
For some indic
Out of range values are extremely common in JPEG. One handles them by clamping.
If X < 0 then X := 0 ; If X > 255 then X := 255 ;