MATLAB爱好者论坛-LabFans.com

MATLAB爱好者论坛-LabFans.com (https://www.labfans.com/bbs/index.php)
-   计算机视觉/图像处理 (https://www.labfans.com/bbs/forumdisplay.php?f=67)
-   -   [资料] 一个边界跟踪的小程序 (https://www.labfans.com/bbs/showthread.php?t=11328)

yfl 2010-04-15 11:17

一个边界跟踪的小程序
 
clc,clear
close all
BW1=imread('text.png');
%figure,imshow(BW1)
c =find(BW1(:,15),1)
r =find(BW1(c,:),1)
%BW2 = bwselect(BW1,c,r,4);
B=bwboundaries(BW1,'holes');
figure, imshow(BW1)
hold on
for k=1:length(B)
counter=B{k}
plot(counter(:,2),counter(:,1),'r','LineWidth',1)
end


所有时间均为北京时间。现在的时间是 21:22

Powered by vBulletin
版权所有 ©2000 - 2025,Jelsoft Enterprises Ltd.