I found this issue when app try to capture a jpeg. By the way, the issue was only reported from MI-series devices.

  • Version : CameraX-1.1.0
  • UseCase : Preview + ImageCapture + ImageAnalysis
  • Device : MI 8 Lite,MI 8,MI 8 SE,MI 6, MI 6X, Redmi 7
  • Os Version:Android 9 and Android 10, Android 11, Android 13
  • Crash:
java.lang.UnsupportedOperationException: The producer output buffer format 0x7fa30c04 doesn't match the ImageReader's configured buffer format 0x21.
    at android.media.ImageReader.nativeImageSetup(ImageReader.java)
    at android.media.ImageReader.acquireNextSurfaceImage(ImageReader.java:450)
    at android.media.ImageReader.acquireNextImage(ImageReader.java:504)
    at androidx.camera.core.AndroidImageReaderProxy.acquireNextImage(AndroidImageReaderProxy.java:85)
    at androidx.camera.core.MetadataImageReader.imageIncoming(MetadataImageReader.java:322)
    at androidx.camera.core.MetadataImageReader.lambda$new$0(MetadataImageReader.java:65)
    at androidx.camera.core.MetadataImageReader.lambda$_aNz13xlU5iBPojO1SQHWFZF1Ls(MetadataImageReader.java:0)
    at androidx.camera.core.-$$Lambda$MetadataImageReader$_aNz13xlU5iBPojO1SQHWFZF1Ls.onImageAvailable(-.java:2)
    at androidx.camera.core.AndroidImageReaderProxy.lambda$setOnImageAvailableListener$0(AndroidImageReaderProxy.java:159)
    at androidx.camera.core.AndroidImageReaderProxy.lambda$n30CAvpHeuX_Ufv8vLc2WxwfHUM(AndroidImageReaderProxy.java:0)
    at androidx.camera.core.-$$Lambda$AndroidImageReaderProxy$n30CAvpHeuX_Ufv8vLc2WxwfHUM.run(-.java:4)
    at android.os.Handler.handleCallback(Handler.java:883)
    at android.os.Handler.dispatchMessage(Handler.java:100)
    at android.os.Looper.loop(Looper.java:224)
    at android.app.ActivityThread.main(ActivityThread.java:7562)
    at java.lang.reflect.Method.invoke(Method.java)
    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:539)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:950)

If you have any suggestions to fix this problem please share it with meļ¼Œthank you!

0

There are 0 answers