updated capfilter.cpp and README