Skip to content
Snippets Groups Projects
Commit 1169e178 authored by Kipp Cannon's avatar Kipp Cannon
Browse files

future-proofing

I have opened a PR to add these macros to gstreamer itself, so this patch
adds #ifdef protection to the declarations here incase the patch is
accepted upstream.
parent 39b02b8e
No related branches found
No related tags found
No related merge requests found
......@@ -80,12 +80,15 @@ LALUnit gstlal_lalUnitSquaredPerHertz(LALUnit);
* Debugging helpers
*/
#ifndef GST_TIME_SECONDS_FORMAT
#define GST_TIME_SECONDS_FORMAT G_GUINT64_FORMAT ".%09" G_GUINT64_FORMAT " s"
#define GST_TIME_SECONDS_ARGS(t) ((t) / GST_SECOND), ((t) % GST_SECOND)
#endif /* GST_TIME_SECONDS_FORMAT */
#define GST_BUFFER_BOUNDARIES_FORMAT ".d[%" GST_TIME_SECONDS_FORMAT ", %" GST_TIME_SECONDS_FORMAT ") = samples [%" G_GUINT64_FORMAT ", %" G_GUINT64_FORMAT ")"
#ifndef GST_BUFFER_BOUNDARIES_FORMAT
#define GST_BUFFER_BOUNDARIES_FORMAT ".d[%" GST_TIME_SECONDS_FORMAT ", %" GST_TIME_SECONDS_FORMAT ") = offsets [%" G_GUINT64_FORMAT ", %" G_GUINT64_FORMAT ")"
#define GST_BUFFER_BOUNDARIES_ARGS(buf) 0, GST_TIME_SECONDS_ARGS(GST_BUFFER_TIMESTAMP(buf)), GST_TIME_SECONDS_ARGS(GST_BUFFER_TIMESTAMP(buf) + GST_BUFFER_DURATION(buf)), GST_BUFFER_OFFSET(buf), GST_BUFFER_OFFSET_END(buf)
#endif /* GST_BUFFER_BOUNDARIES_FORMAT */
G_END_DECLS
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment