Slightly crude, but functional Input Filter.