mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-10 03:19:40 +00:00
decoder: assume current frame is complete at end-of-stream.
Assume we got a complete frame when the end-of-stream is reached and that the current codec frame contains at least one slice data unit.
This commit is contained in:
parent
0c99f351fc
commit
aee91a31ba
1 changed files with 8 additions and 1 deletions
|
@ -167,8 +167,15 @@ do_parse(GstVaapiDecoder *decoder,
|
|||
ps->current_frame = base_frame;
|
||||
status = GST_VAAPI_DECODER_GET_CLASS(decoder)->parse(decoder,
|
||||
adapter, at_eos, unit);
|
||||
if (status != GST_VAAPI_DECODER_STATUS_SUCCESS)
|
||||
if (status != GST_VAAPI_DECODER_STATUS_SUCCESS) {
|
||||
if (at_eos && frame->units->len > 0 &&
|
||||
status == GST_VAAPI_DECODER_STATUS_ERROR_NO_DATA) {
|
||||
/* XXX: assume the frame is complete at <EOS> */
|
||||
*got_frame_ptr = TRUE;
|
||||
return GST_VAAPI_DECODER_STATUS_SUCCESS;
|
||||
}
|
||||
return status;
|
||||
}
|
||||
|
||||
if (GST_VAAPI_DECODER_UNIT_IS_FRAME_START(unit) && frame->units->len > 0) {
|
||||
ps->next_unit_pending = TRUE;
|
||||
|
|
Loading…
Reference in a new issue