⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 image_unscan.m

📁 英文书《Digital Signal Processing with Examples in MATLAB》附带的MATLAB实例
💻 M
字号:
function x=image_unscan(y,M,N,K)
% x=image_unscan(y,M,N,K)
%
% Reverses the effect of image_scan to produce x.
% If K is not included, K=1 plane is assumed.
% See image_scan for definitions of terms.
y=row_vec(y);
if nargin<4,
    K=1;
end
a=zeros(M,N);
a(:)=1:M*N;
b=a(M:-1:1,:);
s=1;
for i=-(M-2):N-1,
	d=diag(b,i)';
	if(rem(i+M-1,2)==1)
		d=rev(d);
	end
	s=[s d];
end
x=zeros(M*N,K);
for k=1:K,
    x(s,k)=y(1+(k-1)*M*N:k*M*N)';
end
x=reshape(x,M,N,K);

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -