Odd problem with camera HAL on Android 11

393 views
Skip to first unread message

Michael Goffioul

unread,
Oct 29, 2020, 10:30:34 AM10/29/20
to Android-x86
While testing Android 11, I encountered an odd issue whereby the webcam wasn't working with most apps (browser, skype, linphone), and the logs were filled with errors about "Too large face count: 0". It turns out the root cause is this change:


Now this is odd, because if I understand correctly this change, the camera HAL _has_ to provide a number of faces > 0. This doesn't seem to consider the case where the camera doesn't support face detection. It's easy enough to change the condition into 'number_of_faces < 0' to make it work. Still, I'm not sure what are the expectations here.

fguy

unread,
Oct 30, 2020, 7:10:19 AM10/30/20
to Android-x86
I am building android 11 from intel celadon repository. I have not encountered such a problem there. The camera works - at least I can see the preview. There is another problem - the graphics driver does not always start. There is no stability with both kernel 4.19 and 5.4. But if the system has booted, then 4.19 does not work stably with graphics - the android can reboot itself - at 5.4 it works stably and even shows a live video from a camera in my city on the weather Yandex page in the browser test. At least there is active work on the project and there is hope to get another stable build. As far as I understand, Intel's priorities in terms of android have shifted from running on a PC to working on a QEMU virtual machine for Linux.

четверг, 29 октября 2020 г., 17:30:34 UTC+3 пользователь Michael Goffioul написал:

Michael Goffioul

unread,
Oct 30, 2020, 4:22:05 PM10/30/20
to Android-x86
Thanks for the feedback. If celadon is using a different camera HAL than android-x86, I don't expect the problem to appear. Also the problem does not occur during displaying preview on screen, it's when an app is trying to access the preview frames for other processing.

--
You received this message because you are subscribed to the Google Groups "Android-x86" group.
To unsubscribe from this group and stop receiving emails from it, send an email to android-x86...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/android-x86/0b2589e8-c638-4c22-909b-64f88ffae009o%40googlegroups.com.

Jon West

unread,
Oct 31, 2020, 5:57:36 PM10/31/20
to Android-x86
If I recall, the celadon camera hal is generic, so it might work for our Android-x86 builds as well. 

Michael Goffioul

unread,
Nov 2, 2020, 11:36:15 AM11/2/20
to Android-x86
Yes, there are generic V4L2 HALs in AOSP, e.g.:
- hardware/libhardware/modules/camera/3_4
- hardware/interfaces/camera/device/3.4/default

The README in the former recommends to use the latter, starting with Android P. I gave the latter a try, but it fails to open the camera on my hardware, due to buffer size:

11-02 11:27:01.482  1551  1688 E ExtCamDevSsn@3.4: configureV4l2StreamLocked: V4L2 buffer size: 921600 looks invalid. Expected maximum size: 614400


AOSP seems to expect not more than 2 bytes per pixel for the buffer, but on my device, the buffer size reported corresponds to 3 bytes.

fguy

unread,
Nov 2, 2020, 12:19:44 PM11/2/20
to Android-x86
https://github.com/projectceladon/vendor-intel-utils/pull/863/commits/d23d8c24e828f6adab9ab3f0cdb8ad0f1f791eb6

понедельник, 2 ноября 2020 г., 19:36:15 UTC+3 пользователь Michael Goffioul написал:

Michael Goffioul

unread,
Nov 2, 2020, 12:34:08 PM11/2/20
to Android-x86
Thanks. I had checked the repo already, but didn't think about checking the pending pull requests.

--
You received this message because you are subscribed to the Google Groups "Android-x86" group.
To unsubscribe from this group and stop receiving emails from it, send an email to android-x86...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages