Files
buildroot/board/miyoo/patches/gst-omx/0004-patch-for-omx-drop-frames.patch
tiopex c336dad699 Add HW video engine support (#179)
* Add Cedar HW video decoder support

* Add sunxifbsink gstreamer plugin

* sunxifbsink: remove warning log
gst-omx: remove resolution check after crop

* Add gstreamer scripts

* review comments fixes

* ffmpeg: enable h264_omx encoder

* add missing hashes and use defined git commit for libcedar

* mv miyoo specific patches to board

* make `gst-omx.mk` less platform specfic

* Add header python interpreter to gst-raw.py

* Add videoscale with nearest-neighbour to play video with higher resolutions fluently

* Use HW scaler

* libcedarc: fix crash when playing 640x480 video

* kernel: Add patch to increase VRAM

* Add fast gstreamer player

* fix gst-play hangs

* Add matroska plugin

* remove target

---------

Co-authored-by: Apaczer <94932128+Apaczer@users.noreply.github.com>
2025-07-21 13:11:52 +02:00

34 lines
1.1 KiB
Diff
Executable File

>From 6b2c45cc5c93bd3d19467ffc22195d8dad32545f Mon Sep 17 00:00:00 2001
From: xiebin <xiebin@allwinnertech.com>
Date: Wed, 31 Jan 2018 13:38:08 +0800
Subject: [PATCH 5/5] patch for omx drop frames
---
omx/gstomxvideodec.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/omx/gstomxvideodec.c b/omx/gstomxvideodec.c
index 79b4daa..a88bdba 100644
--- a/omx/gstomxvideodec.c
+++ b/omx/gstomxvideodec.c
@@ -2171,6 +2171,7 @@ gst_omx_video_dec_handle_frame (GstVideoDecoder * decoder,
guint offset = 0, size;
GstClockTime timestamp, duration;
OMX_ERRORTYPE err;
+ static int drop_num = 0;
self = GST_OMX_VIDEO_DEC (decoder);
klass = GST_OMX_VIDEO_DEC_GET_CLASS (self);
@@ -2178,7 +2179,7 @@ gst_omx_video_dec_handle_frame (GstVideoDecoder * decoder,
GST_DEBUG_OBJECT (self, "Handling frame");
if (!self->started) {
- if (!GST_VIDEO_CODEC_FRAME_IS_SYNC_POINT (frame)) {
+ if (!GST_VIDEO_CODEC_FRAME_IS_SYNC_POINT (frame) && drop_num++ < 20) {
gst_video_decoder_drop_frame (GST_VIDEO_DECODER (self), frame);
return GST_FLOW_OK;
}
--
2.7.4