From 5a79150aa3da2fdd06946faf6a0b499cc01dfb14 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20Dr=C3=B6ge?= Date: Fri, 20 Aug 2021 13:48:04 +0300 Subject: [PATCH] Output per-frame debug logs only at TRACE level --- gstajacommon.cpp | 6 +++--- gstajasrc.cpp | 6 ++++-- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/gstajacommon.cpp b/gstajacommon.cpp index 8b9efff32a..1584060819 100644 --- a/gstajacommon.cpp +++ b/gstajacommon.cpp @@ -412,7 +412,7 @@ static gboolean gst_aja_audio_meta_transform(GstBuffer *dest, GstMeta *meta, if (GST_META_TRANSFORM_IS_COPY(type)) { smeta = (GstAjaAudioMeta *)meta; - GST_DEBUG("copy AJA audio metadata"); + GST_TRACE("copy AJA audio metadata"); dmeta = gst_buffer_add_aja_audio_meta(dest, smeta->buffer); if (!dmeta) return FALSE; } else { @@ -506,7 +506,7 @@ static GstAjaMemory *_aja_memory_new_block(GstAjaAllocator *alloc, mem = (GstAjaMemory *)g_slice_alloc(sizeof(GstAjaMemory)); data = (guint8 *)AJAMemory::AllocateAligned(maxsize, 4096); - GST_DEBUG_OBJECT(alloc, "Allocated %" G_GSIZE_FORMAT " at %p", maxsize, data); + GST_TRACE_OBJECT(alloc, "Allocated %" G_GSIZE_FORMAT " at %p", maxsize, data); if (!alloc->device->device->DMABufferLock((ULWord *)data, maxsize, true)) { GST_WARNING_OBJECT(alloc, "Failed to pre-lock memory"); } @@ -575,7 +575,7 @@ static void gst_aja_allocator_free(GstAllocator *alloc, GstMemory *mem) { if (!mem->parent) { GstAjaAllocator *aja_alloc = GST_AJA_ALLOCATOR(alloc); - GST_DEBUG_OBJECT(alloc, "Freeing memory at %p", dmem->data); + GST_TRACE_OBJECT(alloc, "Freeing memory at %p", dmem->data); aja_alloc->device->device->DMABufferUnlock((ULWord *)dmem->data, mem->maxsize); AJAMemory::FreeAligned(dmem->data); diff --git a/gstajasrc.cpp b/gstajasrc.cpp index 94de5af981..a23757c053 100644 --- a/gstajasrc.cpp +++ b/gstajasrc.cpp @@ -1442,7 +1442,7 @@ static GstFlowReturn gst_aja_src_create(GstPushSrc *psrc, GstBuffer **buffer) { { std::stringstream os; os << rp188; - GST_DEBUG_OBJECT(self, "Adding timecode %s", os.str().c_str()); + GST_TRACE_OBJECT(self, "Adding timecode %s", os.str().c_str()); } guint hours, minutes, seconds, frames; @@ -1654,6 +1654,8 @@ static GstFlowReturn gst_aja_src_create(GstPushSrc *psrc, GstBuffer **buffer) { gst_caps_unref(caps); } + GST_TRACE_OBJECT(self, "Outputting buffer %" GST_PTR_FORMAT, *buffer); + return flow_ret; } @@ -1759,7 +1761,7 @@ restart: ULWord vpid_b = 0; self->device->device->ReadSDIInVPID(self->channel, vpid_a, vpid_b); - GST_DEBUG_OBJECT(self, + GST_TRACE_OBJECT(self, "Detected input video format %u with VPID %08x / %08x", current_video_format, vpid_a, vpid_b);