Hi all,
In my case, function "void OmxCodecObserver::onMessage(const omx_message &message) " will get two messages of same timestamp(The first frame).
And after this, a message (the third or the forth one) who has the timestamp of one input frame , message.u.extended_buffer_data.range_length will be 0.
And all the frame after this frame will be decoded badly.
Here is the log.
sendInputData(478): in 0x404206d1 //Input bitstream
sendInputData(478): in 0x40421757
onOmxObserverFillBufferDone(1019): Add info:timestamp 0x0,size:0,Islast:0 //output yuv
onOmxObserverFillBufferDone(1019): Add info:timestamp 0x0,size:0,Islast:0
callOutputCallbackFunction(441): bufferSize=0
DataOutputThread(1063): Dequeue info:timestamp 0x0,mFrameSize:0
callOutputCallbackFunction(441): bufferSize=0
DataOutputThread(1063): Dequeue info:timestamp 0x0,mFrameSize:0
onOmxObserverFillBufferDone(1019): Add info:timestamp 0x0,size:0,Islast:0
callOutputCallbackFunction(441): bufferSize=0
DataOutputThread(1063): Dequeue info:timestamp 0x0,mFrameSize:0
onOmxObserverFillBufferDone(1019): Add info:timestamp 0x0,size:0,Islast:0
onOmxObserverFillBufferDone(1019): Add info:timestamp 0x0,size:0,Islast:0
callOutputCallbackFunction(441): bufferSize=0
DataOutputThread(1063): Dequeue info:timestamp 0x0,mFrameSize:0
callOutputCallbackFunction(441): bufferSize=0
DataOutputThread(1063): Dequeue info:timestamp 0x0,mFrameSize:0
sendInputData(478): in 0x40422459
sendInputData(478): in 0x40422f99
onOmxObserverFillBufferDone(1019): Add info:timestamp 0x404206d1,size:170432,Islast:0
callOutputCallbackFunction(441): bufferSize=170432
DataOutputThread(1063): Dequeue info:timestamp 0x404206d1,mFrameSize:170432
onOmxObserverFillBufferDone(1019): Add info:timestamp 0x0,size:0,Islast:0
onOmxObserverFillBufferDone(1019): Add info:timestamp 0x0,size:0,Islast:0
onOmxObserverFillBufferDone(1019): Add info:timestamp 0x0,size:0,Islast:0
onOmxObserverFillBufferDone(1019): Add info:timestamp 0x0,size:0,Islast:0
onOmxObserverFillBufferDone(1019): Add info:timestamp 0x404206d1,size:170432,Islast:0 //two frames have the same timestamp
callOutputCallbackFunction(441): bufferSize=170432
DataOutputThread(1063): Dequeue info:timestamp 0x404206d1,mFrameSize:170432
onOmxObserverFillBufferDone(1019): Add info:timestamp 0x40421757,size:170432,Islast:0
onOmxObserverFillBufferDone(1019): Add info:timestamp 0x40422459,size:0,Islast:0 //The size of this frame is 0.
onOmxObserverFillBufferDone(1019): Add info:timestamp 0x0,size:0,Islast:0
onOmxObserverFillBufferDone(1019): Add info:timestamp 0x0,size:0,Islast:0
sendInputData(478): in 0x40426941
onOmxObserverFillBufferDone(1019): Add info:timestamp 0x40422f99,size:170432,Islast:0
callOutputCallbackFunction(441): bufferSize=170432
DataOutputThread(1063): Dequeue info:timestamp 0x40422f99,mFrameSize:170432
All the above is based android 4.0 and omap 4460.