summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJosep Torra <n770galaxy@gmail.com>2014-05-12 12:33:32 +0200
committerJosep Torra <n770galaxy@gmail.com>2014-05-12 12:33:32 +0200
commite08540d969c170a37425b07b8e5b97b2bfbf880a (patch)
treeef0835e2bc98ceecc08bc73cf3a8d87ac16a2f80
parent527af797d2a3336be60a76bc8d525ba77396010e (diff)
omxaudiosink: implement _delay only in the RaspberryPI
Make code implementation conditionally built for RaspberryPI because OMX_IndexConfigAudioRenderingLatency seems to be a Broadcom extension. On other targets the query position might not be accurate without implementing _delay appropriatelly.
-rw-r--r--omx/gstomxaudiosink.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/omx/gstomxaudiosink.c b/omx/gstomxaudiosink.c
index e28d23e..6f1daeb 100644
--- a/omx/gstomxaudiosink.c
+++ b/omx/gstomxaudiosink.c
@@ -886,6 +886,7 @@ release_error:
static guint
gst_omx_audio_sink_delay (GstAudioSink * audiosink)
{
+#if defined (USE_OMX_TARGET_RPI)
GstOMXAudioSink *self = GST_OMX_AUDIO_SINK (audiosink);
OMX_PARAM_U32TYPE param;
OMX_ERRORTYPE err;
@@ -903,6 +904,9 @@ gst_omx_audio_sink_delay (GstAudioSink * audiosink)
GST_DEBUG_OBJECT (self, "reported delay %u samples", (guint) param.nU32);
return param.nU32;
+#else
+ return 0;
+#endif
}
static void