weixin_39878698
weixin_39878698
2020-11-30 05:32

UVC camera library fails with android 7

Hello saki4510t,

I've been testing UVCCamera library with android 7. I tested all the basic samples (usbCameraTest0, usbCameraTest and usbCameraTest2) on a google pixel phone. But unfortunately none of these samples are working. And the error I'm getting is;


java.lang.IllegalArgumentException: Failed to set preview size
at com.serenegiant.usb.UVCCamera.setPreviewSize(UVCCamera.java:306)
at com.serenegiant.usb.UVCCamera.setPreviewSize(UVCCamera.java:277)
at com.serenegiant.usbcameratest2.MainActivity$3$1.run(MainActivity.java:191)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1133)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:607)
at java.lang.Thread.run(Thread.java:761)

in the onConnect() method, I tried with different height-with combinations, but it kept failing to set the previewSize() of the camera successfully. Meantime I also noticed that "supportedSize" of the camera gives, null value.

Could you please have a look at it?

Thanks.

该提问来源于开源项目:saki4510t/UVCCamera

  • 点赞
  • 回答
  • 收藏
  • 复制链接分享

7条回答

为你推荐