v4l2: object: Fix bogus debug objects pointers

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4525>
This commit is contained in:
Nicolas Dufresne 2023-04-14 23:38:34 -04:00 committed by GStreamer Marge Bot
parent f01e71d4ad
commit d4a428e61f

View file

@ -1987,17 +1987,17 @@ gst_v4l2_object_get_caps_info (GstV4l2Object * v4l2object, GstCaps * caps,
/* ERRORS */ /* ERRORS */
invalid_format: invalid_format:
{ {
GST_DEBUG_OBJECT (v4l2object, "invalid format"); GST_DEBUG_OBJECT (v4l2object->dbg_obj, "invalid format");
return FALSE; return FALSE;
} }
unhandled_format: unhandled_format:
{ {
GST_DEBUG_OBJECT (v4l2object, "unhandled format"); GST_DEBUG_OBJECT (v4l2object->dbg_obj, "unhandled format");
return FALSE; return FALSE;
} }
unsupported_format: unsupported_format:
{ {
GST_DEBUG_OBJECT (v4l2object, "unsupported format"); GST_DEBUG_OBJECT (v4l2object->dbg_obj, "unsupported format");
return FALSE; return FALSE;
} }
} }
@ -2366,7 +2366,8 @@ gst_v4l2_object_add_interlace_mode (GstV4l2Object * v4l2object,
|| gst_value_list_get_size (&interlace_formats) > 0) || gst_value_list_get_size (&interlace_formats) > 0)
gst_structure_take_value (s, "interlace-mode", &interlace_formats); gst_structure_take_value (s, "interlace-mode", &interlace_formats);
else else
GST_WARNING_OBJECT (v4l2object, "Failed to determine interlace mode"); GST_WARNING_OBJECT (v4l2object->dbg_obj,
"Failed to determine interlace mode");
return; return;
} }
@ -3338,7 +3339,7 @@ gst_v4l2_object_save_format (GstV4l2Object * v4l2object,
padded_width = stride / pstride; padded_width = stride / pstride;
} else { } else {
/* pstride can be 0 for complex formats */ /* pstride can be 0 for complex formats */
GST_WARNING_OBJECT (v4l2object->element, GST_WARNING_OBJECT (v4l2object->dbg_obj,
"format %s has a pstride of 0, cannot compute padded with", "format %s has a pstride of 0, cannot compute padded with",
gst_video_format_to_string (GST_VIDEO_INFO_FORMAT (info))); gst_video_format_to_string (GST_VIDEO_INFO_FORMAT (info)));
padded_width = stride; padded_width = stride;
@ -3611,9 +3612,9 @@ gst_v4l2_object_set_format_full (GstV4l2Object * v4l2object, GstCaps * caps,
field = get_v4l2_field_for_info (&info); field = get_v4l2_field_for_info (&info);
if (field != V4L2_FIELD_NONE) if (field != V4L2_FIELD_NONE)
GST_DEBUG_OBJECT (v4l2object->element, "interlaced video"); GST_DEBUG_OBJECT (v4l2object->dbg_obj, "interlaced video");
else else
GST_DEBUG_OBJECT (v4l2object->element, "progressive video"); GST_DEBUG_OBJECT (v4l2object->dbg_obj, "progressive video");
/* We first pick the main colorspace from the primaries */ /* We first pick the main colorspace from the primaries */
switch (info.colorimetry.primaries) { switch (info.colorimetry.primaries) {