How do I feed images from a folder into MATLAB periodically?

1 回表示 (過去 30 日間)
Usamath Pallikkachalil
Usamath Pallikkachalil 2016 年 10 月 5 日
回答済み: Walter Roberson 2016 年 10 月 5 日
I'm trying to create a program that will process a sequence of images captured by a usb webcam and display the count of objects in it.
I've programmed the webcam to save a picture in a specific folder and replace it periodically with the subsequent pictures (with the same name). I need to attach a code that will fetch the images periodically into a function that will do the processing.

採用された回答

Robert
Robert 2016 年 10 月 5 日
編集済み: Robert 2016 年 10 月 5 日
I think a timer and imread would do what you want.

その他の回答 (1 件)

Walter Roberson
Walter Roberson 2016 年 10 月 5 日
Robert's suggestion of timer() is a good one that might be quite enough for what you need.
In some situations, you might want to receive notification if files or a directory have changed. See http://www.mathworks.com/help/matlab/matlab_external/using-a-net-object.html for the MS Windows solution, and http://www.mathworks.com/help/matlab/matlab_external/using-a-net-object.html for a timer-based directory check.

カテゴリ

Help Center および File ExchangeStartup and Shutdown についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by