Cleanup sources and prepare for multiple filters.

Also, remove signed/unsigned warning.