showcorners.m

来自「machine vision 工具箱」· M 代码 · 共 36 行

M
36
字号
%SHOWCORNERS	Overlay corner features on image%%	[X,Y] = SHOWCORNERS(c, n)%	SHOWCORNERS(c, n)%%	Returns the coordinates of the N strongest corners in the corner%	image C.%	The second form overlays a white square at the location of the N %	strongest corners.  %% SEE ALSO:	iharris%%	Copyright (c) Peter Corke, 1999  Machine Vision Toolbox for Matlabfunction [x,y] = showcorners(cp, n)	if nargin == 1,		n = 10;	end	[nrows,ncols] = size(cp);	[z,i] = sort(cp(:));	i = head(i, n);	c=floor(i/nrows)+1;	r=rem(i,nrows)+1; 	if nargout == 2,		x = c;		y = r;	else		hold on		plot(c, r, 'sw')		hold off	end

⌨️ 快捷键说明

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