Real-time video processing
显示 更早的评论
Hi, I have just made a GUI of artificial vision. I have managed to do several operations but only in "fixed" images and I have three questions. I want to know what would be the best option to perform in "real time"? 1.- The timer function (a clear example of how it could be used?) 2.- The while function in infinite loop (How do you disable a while in infinite loop?) 3.- Any other function that you know? (I need to apply filters, masks and generate RGB / BW histograms) Thanks in advance
TIMER FUNCTION
https://www.mathworks.com/help/matlab/matlab_external/timerfcn.html?searchHighlight=timerfcn&s_tid=doc_srchtitle
I want to apply filters, masks and make histograms in "real time"
回答(2 个)
John D'Errico
2017-6-23
I have no idea what you want in terms of an example for a timer. I'd start by reading
doc timer
You will find examples there.
A while is trivial though.
iter = 0;
while 1
iter = iter + 1;
if rand(1) < 0.00001
break
end
end
iter
iter =
230491
Or use a condition in the while statement itself.
iter = 0;
while rand(1) > 0.00001
iter = iter + 1;
end
iter
iter =
19420
1 个评论
Guillermo Gutiérrez
2017-6-23
编辑:Guillermo Gutiérrez
2017-6-23
Image Analyst
2017-6-28
0 个投票
My example of using a while loop to do stuff until you press a pushbutton is attached.
类别
在 帮助中心 和 File Exchange 中查找有关 Computer Vision Toolbox 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!