How to fix "The camera did not return a frame for this resolution" error when creating second webcam object?
10 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Shawn Saini
el 1 de Feb. de 2017
Comentada: Nisa tankutay
el 5 de Jun. de 2021
Background: I am using a Surface Pro 3 with an i3 and 4GB of RAM running WINDOWS 10. It has one USB port which I used to connect a USB 3.0 hub to it with 4 ports. I connect two (MicroSoft) LifeCam Cinema webcam devices to the USB hub. I am running Matlab 2016B with Image Acquisition, Image Processing, and webcam support package and many more toolboxes that I can list at request.
Code (which produces the error):
>> webcamlist
ans =
2×1 cell array
'Microsoft® LifeCam Cinema(TM)'
'Microsoft® LifeCam Cinema(TM)'
>> cam1=webcam(1)
cam1 =
webcam with properties:
Name: 'Microsoft® LifeCam Cine…'
Resolution: '640x480'
AvailableResolutions: {1×12 cell}
WhiteBalance: 4500
Saturation: 83
ExposureMode: 'auto'
Contrast: 5
Zoom: 0
Pan: 0
Brightness: 143
WhiteBalanceMode: 'auto'
FocusMode: 'manual'
Sharpness: 25
Focus: 14
Tilt: 0
Exposure: -6
BacklightCompensation: 0
>> cam2=webcam(2)
cam2 =
webcam with properties:
Name: 'Microsoft® LifeCam Cine…'
Resolution: '640x480'
AvailableResolutions: {1×12 cell}
WhiteBalance: 4500
Saturation: 83
ExposureMode: 'auto'
Contrast: 5
Zoom: 0
Pan: 0
Brightness: 143
WhiteBalanceMode: 'auto'
FocusMode: 'manual'
Sharpness: 25
Focus: 14
Tilt: 0
Exposure: -6
BacklightCompensation: 0
The camera did not return a frame for this
resolution.
What I've Tried/More Info: -Uninstalling the driversand reinstalling
-Connecting the cameras in a different order (I found out both work, it is always the second webcam object which doesnt work)
-Restarting my computer and matlab
-Downloading the Image Acquisition toolbox and adapters for that toolbox
-This works on my computer at school (don't know every detail about that computer; also it is in another country at the moment)
-Previewed the camera that gets the error and it is always black (no image) whereas the webcam that didn't get the error (always the first cam object) is previewable (displays video in real time).
-Not sure if Windows 10 is the problem since it partially works? I just realized the mathworks page says Windows 7 is the only Windows that is compatible with the USB Webcam Support Package....
Any help would be greatly appreciated! Thank you in advance! And sorry if I have broken any forum rules or haven't provided enough info; this is the first time I'm ever resorting to a forum haha.
Thanks!
3 comentarios
Hassan Mehmood Khan
el 10 de Abr. de 2017
I found the same issue. I am using matlab R2016a. I am using two Logitech Cameras. and one of them was showing: " The camera did not return a frame for this resolution." . It was solved once i exit the default software of webcam, and exit all my applications which might be using Webcam like Skype OR Viber. Then i restart the Matlab.
Then the issue was solved. Both webcam can be read by Matlab for Image Processing.
Respuesta aceptada
Shawn Saini
el 25 de Feb. de 2017
1 comentario
Nisa tankutay
el 5 de Jun. de 2021
sorry but ı dont understand, how can ı fix this problem? How can use 2 cameras on matlab?
Más respuestas (2)
Islam Gaied
el 17 de Nov. de 2019
This is happened to me a 100 times , 1 cam will work and the other no cause you have a logiciel on ur pc connect to one of the cameras , the solution is simple just block acess to ur cams for all ur programs except matlab ( like skype , google chrome safari ...)
For all ur navigators like chrome you need to delete all data on ur browser ( cache , history ....) then block the camera
0 comentarios
Madhura Suresh
el 18 de Abr. de 2017
Can you switch the resolution to a different one, using:
w.Resolution = '<insert value here>';
2 comentarios
machhindra bhamare
el 6 de Jul. de 2018
i have same problem ,i connect three microsoft cameras ,to usb 3.0 hub ,at the time of processing its loses resolution,this is the hardware issue ,i remove the usb 3.0 hub then is ok
Aldo G. Orozco-Lugo
el 22 de Feb. de 2021
Nice, leaving one camera on the hub and the other in another usb port solves the problem in windows 10
Ver también
Categorías
Más información sobre MATLAB Support Package for IP Cameras en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!