Video Writer for cycle detection
3 ビュー (過去 30 日間)
古いコメントを表示
Amir Azadeh Ranjbar
2022 年 8 月 12 日
コメント済み: Amir Azadeh Ranjbar
2022 年 8 月 13 日
clc;clear all;close all
v = VideoWriter('cycles1','MPEG-4');
open(v);
Web=webcam;
k=1;
while k<200
frame=Web.snapshot;
[centers,radii] = imfindcircles(rgb2gray(frame),...
[8,30],"ObjectPolarity","dark",...
"Sensitivity",0.8,...
"Method","TwoStage");
imshow(frame)
h = viscircles(centers,radii,"Color",[0.2 0.3 0.5]);
writeVideo(v,frame);
k=k+1;
end
close(v)
clear Web
% I Wanr Write Video With Cycle that detected
1 件のコメント
Benjamin Thompson
2022 年 8 月 12 日
Do you mean cycle detection or circle detection?
Is there an error or some problem with your sample code that you can post here?
採用された回答
Benjamin Thompson
2022 年 8 月 12 日
You can use frame2im(getframe(gcf)) to get an image that has the result of imshow and viscircles together.
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Convert Image Type についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!