After the camera variable is defined and used as below;
camera = webcam;
picture = camera.snapshot;
I use;
clear camera
However deleting the structure of course doesn't disconnect the webcam.
How can I officially stop image acquisition and disconnect the webcam?

답변 (1개)

Star Strider
Star Strider 2018년 5월 15일

0 개 추천

Try the function version:
clear('camera')
That is in the documentation as step 8 in: Acquire Webcam Images (link).

댓글 수: 8

Beril Sirmacek
Beril Sirmacek 2018년 5월 16일
I tried using clear('camera');
Unfortunately, the webcam light is still on and not possible to disconnect unless I close MatLab.
Star Strider
Star Strider 2018년 5월 16일
Contact MathWorks. Use the Contact Us link in the upper right corner of this page.
Beril Sirmacek
Beril Sirmacek 2018년 5월 22일
I am contacting to for support. Thank you for your suggestion.
Star Strider
Star Strider 2018년 5월 22일
My pleasure.
I never experienced that problem, and couldn’t reproduce it when I used my webcam.
Beril Sirmacek
Beril Sirmacek 2018년 5월 22일
I wonder if it is because camera drivers or another setting on pc. Maybe not a MatLab issue at all.
Star Strider
Star Strider 2018년 5월 22일
I have no idea.
Can you turn it on and off outside of MATLAB? That may be one way of isolating the problem.
Beril Sirmacek
Beril Sirmacek 2018년 5월 23일
Yes, I can turn it on and off with other software which reaches to webcam.
Star Strider
Star Strider 2018년 5월 23일
Then request help from MathWorks. Use the Contact Us link in the upper right corner of this page.
Run the ver command from your Command Window first. Then copy and paste the results to the appropriate window.

댓글을 달려면 로그인하십시오.

카테고리

도움말 센터File Exchange에서 MATLAB Support Package for IP Cameras에 대해 자세히 알아보기

태그

질문:

2018년 5월 15일

댓글:

2018년 5월 23일

Community Treasure Hunt

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

Start Hunting!

Translated by