
[pyr,pind] = buildWpyr(im, 'auto', filt, edges);
showWpyr(pyr,pind,'auto2');

res = reconWpyr(pyr, pind, filt, edges);
clf; 
showIm(im + i*res);
imStats(im,res);

res = reconWpyr(pyr, pind, filt, edges, 'all', [2]);  %vertical only
clf; 
showIm(res);

%% Steerable pyramid:
%[pyr,pind] = buildSpyr(im,4-imSubSample,'sp3Filters');  
[pyr,pind] = buildSpyr(im,'auto','sp3Filters');  
showSpyr(pyr,pind);

%% Steerable pyramid, constructed in frequency domain:
%[pyr,pind] = buildSFpyr(im,5-imSubSample,4);  %5 ori