tried use imfilter rather than filter2. not work quite well