saki4510t / UVCCamera

library and sample to access to UVC web camera on non-rooted Android device
2.99k stars 1.2k forks source link

NDK version higher than 16.1.4479499 could not open camera #541

Open liuwei3612 opened 4 years ago

liuwei3612 commented 4 years ago

With 16.1.4479499 is is working. but with 18.1.5063045,There's a problem of "Process 'command 'D:\SDK\ndk-bundle/ndk-build.cmd'' finished with non-zero exit value 2".I modified it according to the following prompt, and the compilation was successful. " So if you want to use NDK17, remove entries in libuvccamera\src\main\jni\Application.mk Change: APP_ABI := armeabi armeabi-v7a x86 mips to APP_ABI := armeabi-v7a x86 Close Android Studio. Then you need to delete the content of the lib directories in libuvccamera\src\main\libs**.so. If not you get probably an additional compiler error. Open Android Studio an rebuild your project-/s. At least it works for me." But this error will appear when running: I/libusb/core: [6954core.c:2085:libusb_init2]:libusb v1.0.19.10903 I/libusb/usbfs: [6954android_usbfs.c:504:op_init2]:start up hotplug event handler [6954android_usbfs.c:512:op_init2]:call android_scan_devices E/UVCCamera: [6954UVCCamera.cpp:172:connect]:could not open camera:err=-1 W/System.err: java.lang.UnsupportedOperationException: open failed:result=-1

please help me

jumpy88 commented 3 years ago

@liuwei3612 take a look in this https://github.com/saki4510t/UVCCamera/issues/588 Notice I used https://github.com/komakai/UVCCamera/tree/komakai-fixes source code