blob: eb2730340408c4a12fefa55259a724889f309d5c (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
% [HFILT] = modulateFlipShift(LFILT)
%
% QMF/Wavelet highpass filter construction: modulate by (-1)^n,
% reverse order (and shift by one, which is handled by the convolution
% routines). This is an extension of the original definition of QMF's
% (e.g., see Simoncelli90).
% Eero Simoncelli, 7/96.
function [hfilt] = modulateFlipShift(lfilt)
lfilt = lfilt(:);
sz = size(lfilt,1);
sz2 = ceil(sz/2);
ind = [sz:-1:1]';
hfilt = lfilt(ind) .* (-1).^(ind-sz2);
|