Artifact 68200e9adedef9043488d9c7fc437ad3e985aa21:
- File demos/convolve_sobelhg.tcl — part of check-in [f0341e8f0a] at 2010-09-02 00:04:08 on branch ak-experimental — More changes to the convolution. Extended the primitives with an 'offset' argument. Updated the kernel make method with an optional offset, and an auto-offset heuristic which does the right thing for zero-sum kernels like the various edge detectors, i.e. +128 for zero-sum, and 0 else. Removed the 'o'ffset demos. Added more edge/sobel demos operating in greyscale. (user: andreask size: 285) [more...]
def op_convolve_sobelhg { label {Sobel Grey/Horizontical} setup { # http://wiki.tcl.tk/9521 variable K [crimp kernel make { { 1 2 1} { 0 0 0} {-1 -2 -1}}] } setup_image { show_image [crimp filter convolve [crimp convert 2grey8 [base]] $K] } }