问题
I am working on stagefright to decode and display mp4 file in android 4.0.4 with hardware codec.
Currently I am testing in Motorola Xoom device with android 4.0.4. I was able to decode and display the files for all resolutions fast enough for my requirement
but at the end of the decoding i.e for the last frame it crashes with the following error
08-27 12:24:53.500: A/OMXCodec(2677):
frameworks/base/media/libstagefright/OMXCodec.cpp:2037
CHECK_EQ( (int)bufInfo->mStatus,(int)OWNED_BY_NATIVE_WINDOW) failed: 0 vs. 2
08-27 12:24:53.500: A/libc(2677): Fatal signal 11 (SIGSEGV) at 0xdeadbaad (code=1)
When I checked the code of omxcodec this happens when the codec tries to dequeue native window buffer on release of the mediabuffer object which in turn calls the signalBufferReturned() function of omxcodec. But not getting how to solve this...
I have tried it in karbonnA9+ also where it is working fine currently..
Can someone give a solution or a suggestion.....
来源:https://stackoverflow.com/questions/25522999/android-nativewndowbuffer-ownership-issue-in-omxcodec-for-hardware-h-264-decodi