%A为给定图像,归一化到[0,1]的矩阵 %W为双边滤波器(核)的边长/2 function B = bfilter2(A,w,sigma)% Pre-process input and select appropriate filter. % Verify that the input image exists and is valid. if~exist('A','var') || isempty(A)