omxvideodec: Remove duplicated QoS code
authorNicolas Dufresne <nicolas.dufresne@collabora.com>
Tue, 2 Oct 2018 14:47:06 +0000 (10:47 -0400)
committerOlivier CrĂȘte <olivier.crete@ocrete.ca>
Fri, 25 Jan 2019 00:50:06 +0000 (00:50 +0000)
The 'finish' function do the exact same check / drop, there is no
need to duplicate this here.

omx/gstomxvideodec.c

index 4be7dfc..9ef8576 100644 (file)
@@ -1596,7 +1596,6 @@ gst_omx_video_dec_loop (GstOMXVideoDec * self)
   GstVideoCodecFrame *frame;
   GstFlowReturn flow_ret = GST_FLOW_OK;
   GstOMXAcquireBufferReturn acq_return;
-  GstClockTimeDiff deadline;
   OMX_ERRORTYPE err;
 
 #if defined (USE_OMX_TARGET_RPI) && defined (HAVE_GST_GL)
@@ -1727,15 +1726,7 @@ gst_omx_video_dec_loop (GstOMXVideoDec * self)
   gst_omx_video_dec_clean_older_frames (self, buf,
       gst_video_decoder_get_frames (GST_VIDEO_DECODER (self)));
 
-  if (frame
-      && (deadline = gst_video_decoder_get_max_decode_time
-          (GST_VIDEO_DECODER (self), frame)) < 0) {
-    GST_WARNING_OBJECT (self,
-        "Frame is too late, dropping (deadline %" GST_TIME_FORMAT ")",
-        GST_TIME_ARGS (-deadline));
-    flow_ret = gst_video_decoder_drop_frame (GST_VIDEO_DECODER (self), frame);
-    frame = NULL;
-  } else if (!frame && (buf->omx_buf->nFilledLen > 0 || buf->eglimage)) {
+  if (!frame && (buf->omx_buf->nFilledLen > 0 || buf->eglimage)) {
     GstBuffer *outbuf = NULL;
 
     /* This sometimes happens at EOS or if the input is not properly framed,