Is it possible to run videoobject on backside like parfeval?

조회 수: 2 (최근 30일)
Ahmet Gökhan POYRAZ
Ahmet Gökhan POYRAZ 2022년 3월 18일
답변: Akshat Dalal 2023년 11월 20일
I am trying to get images and processing from 2 cameras at different times. But it must be fast. So ı wonder that is it possible to run all capturing and processing operations can be done on worker? Sample code is like that
if triggercomes ==1
parfeval(@process,0,vidobject1,vidobject2)
end
Process function
function process(vidobject)
pause(1) % it waits for exact timing
im1 = getsnapshot(vidobject)
pause(1)
im2 = getsnapshot(vidobject)
end
But vid object is not working on parfeval how to solve this problem?
Thanks

답변 (1개)

Akshat Dalal
Akshat Dalal 2023년 11월 20일
Hi Ahmet,
I understand that you want to work with 2 cameras parallelly and are facing some issues. There is an example by MathWorks which demonstrates how to do this. The example and its explanation are present in the following MATLAB Answer: https://www.mathworks.com/matlabcentral/answers/388286
The solution uses the ‘spmd’ function from the Parallel Computing Toolbox to execute code in parallel on a pool of workers. You could refer the following documentation to learn more: https://www.mathworks.com/help/parallel-computing/spmd.html
I hope this helps.

카테고리

Help CenterFile Exchange에서 MATLAB Support Package for IP Cameras에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by