mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-09 08:55:33 +00:00
jack: remove version guards from the code
We already require >= 1.9.7 in meson and thus we can remove the older codepath. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4348>
This commit is contained in:
parent
06478b79b1
commit
1c301df91a
3 changed files with 1 additions and 50 deletions
|
@ -653,7 +653,6 @@ gst_jack_ring_buffer_stop (GstAudioRingBuffer * buf)
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
#if defined (HAVE_JACK_0_120_1) || defined(HAVE_JACK_1_9_7)
|
||||
static guint
|
||||
gst_jack_ring_buffer_delay (GstAudioRingBuffer * buf)
|
||||
{
|
||||
|
@ -673,29 +672,6 @@ gst_jack_ring_buffer_delay (GstAudioRingBuffer * buf)
|
|||
|
||||
return res;
|
||||
}
|
||||
#else /* !(defined (HAVE_JACK_0_120_1) || defined(HAVE_JACK_1_9_7)) */
|
||||
static guint
|
||||
gst_jack_ring_buffer_delay (GstAudioRingBuffer * buf)
|
||||
{
|
||||
GstJackAudioSink *sink;
|
||||
guint i, res = 0;
|
||||
guint latency;
|
||||
jack_client_t *client;
|
||||
|
||||
sink = GST_JACK_AUDIO_SINK (GST_OBJECT_PARENT (buf));
|
||||
client = gst_jack_audio_client_get_client (sink->client);
|
||||
|
||||
for (i = 0; i < sink->port_count; i++) {
|
||||
latency = jack_port_get_total_latency (client, sink->ports[i]);
|
||||
if (latency > res)
|
||||
res = latency;
|
||||
}
|
||||
|
||||
GST_LOG_OBJECT (sink, "delay %u", res);
|
||||
|
||||
return res;
|
||||
}
|
||||
#endif
|
||||
|
||||
static GstStaticPadTemplate jackaudiosink_sink_factory =
|
||||
GST_STATIC_PAD_TEMPLATE ("sink",
|
||||
|
|
|
@ -661,7 +661,6 @@ gst_jack_ring_buffer_stop (GstAudioRingBuffer * buf)
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
#if defined (HAVE_JACK_0_120_1) || defined(HAVE_JACK_1_9_7)
|
||||
static guint
|
||||
gst_jack_ring_buffer_delay (GstAudioRingBuffer * buf)
|
||||
{
|
||||
|
@ -681,30 +680,6 @@ gst_jack_ring_buffer_delay (GstAudioRingBuffer * buf)
|
|||
|
||||
return res;
|
||||
}
|
||||
#else /* !(defined (HAVE_JACK_0_120_1) || defined(HAVE_JACK_1_9_7)) */
|
||||
static guint
|
||||
gst_jack_ring_buffer_delay (GstAudioRingBuffer * buf)
|
||||
{
|
||||
GstJackAudioSrc *src;
|
||||
guint i, res = 0;
|
||||
guint latency;
|
||||
jack_client_t *client;
|
||||
|
||||
src = GST_JACK_AUDIO_SRC (GST_OBJECT_PARENT (buf));
|
||||
|
||||
client = gst_jack_audio_client_get_client (src->client);
|
||||
|
||||
for (i = 0; i < src->port_count; i++) {
|
||||
latency = jack_port_get_total_latency (client, src->ports[i]);
|
||||
if (latency > res)
|
||||
res = latency;
|
||||
}
|
||||
|
||||
GST_DEBUG_OBJECT (src, "delay %u", res);
|
||||
|
||||
return res;
|
||||
}
|
||||
#endif
|
||||
|
||||
/* Audiosrc signals and args */
|
||||
enum
|
||||
|
|
|
@ -92,7 +92,7 @@ endif
|
|||
|
||||
gstjack = library('gstjack',
|
||||
jack_sources,
|
||||
c_args : gst_plugins_good_args + ['-DHAVE_JACK_1_9_7'],
|
||||
c_args : gst_plugins_good_args,
|
||||
include_directories : jack_incdirs,
|
||||
dependencies : [gst_dep, gstbase_dep, gstaudio_dep, libjack_dep],
|
||||
install : true,
|
||||
|
|
Loading…
Reference in a new issue