http://www.tcl.tk/man/tcl8.6/TclCmd/transchan.htm
Attach a transform to a channel. The transform can be removed with chan pop.
For an example, see TclOO Channels or Add a time stamp to each line of output.