1 function G=doog2(sig,r,th,N);
3 % Make difference of offset gaussians kernel
5 % (see Malik & Perona, J. Opt. Soc. Amer., 1990)
8 % >> imagesc(doog2(1,12,0,64,1))
14 no_pts=N; % no. of points in x,y grid
16 [x,y]=meshgrid(-(N/2)+1/2:(N/2)-1/2,-(N/2)+1/2:(N/2)-1/2);
21 R=[cos(phi) -sin(phi); sin(phi) cos(phi)];
22 C=R*diag([sigx,sigy])*R';
26 Gb=gaussian(X,[0 0]',C);
38 G = a*Ga + b*Gb + c*Gc;