debugged filter added gaussian weighting