Details
-
Bug
-
Resolution: Fixed
-
P2: Important
-
6.5.1
-
None
-
-
954053c17 (dev), 0fbcfe64f (6.5.1), faf93aa16 (6.5)
-
2023wk18FOQtforAndroid, 2023wk20FOQtforAndroid
Description
Case with different pixelFormat chosen and different received is know issue on Android side. But documentation is missing:
It is happening when using ffmpeg backend - on Android.
In Multimedia, when we are using camera, we can request a YUV420P pixelFormat which will be translated in Android to ImageFormat.YUV_420_888. Then the camera2 api will return YUV_420_888 Images as frames.
The issue is the ImageFormat.YUV_420_888 is
"This format is a generic YCbCr format, capable of describing any 4:2:0 chroma-subsampled planar or semiplanar buffer (but not fully interleaved), with 8 bits per color sample."
Being a generic format, we can receive either a fully planar 4:2:0 - YUV420P or a semiplanar NV12/NV21. That will depend on the codec implemented in the device, so device-dependent.
So at the end:
When someone request YUV420P format - he can receive YUV420P or NV12/NV21 on Android with ffmpeg backend
Information about this known issue should be added to:
https://doc.qt.io/qt-6/qcameraformat.html
or
https://doc.qt.io/qt-6/qcamera.html#setCameraFormat
FFmpeg was not included in installer for Android 6.5.0 version, so the documentation need to be updated for 6.5.1.