If you're really keen to write a filter, Panflute is the most developed now and you might look at its documentation. But shouldn't John's suggestion work with Cygwin?