From patchwork Fri Oct 10 14:18:24 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Umang Jain X-Patchwork-Id: 24582 Return-Path: X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id BD5BDC3264 for ; Fri, 10 Oct 2025 14:18:19 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 4EA0B6B61A; Fri, 10 Oct 2025 16:18:17 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=igalia.com header.i=@igalia.com header.b="IT4L+Hjw"; dkim-atps=neutral Received: from fanzine2.igalia.com (fanzine2.igalia.com [213.97.179.56]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 9A7946B599 for ; Fri, 10 Oct 2025 16:18:13 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=igalia.com; s=20170329; h=Content-Transfer-Encoding:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:Cc:To:From:Sender:Reply-To:Content-Type:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=lQCB/mFJNjsE+FX8VE5OPZLqLNj33oVg34Lks0OQBvw=; b=IT4L+Hjw4gLgrtm7bvqsnz9ZUx giKquNS+ixR64rBl+WD2i5+MnORmUD1/JUVkRehkI1w6o/dwOH9nrstqpz3jB0iZau3Htc9Xxq0aR B5OxtOINGLCDSDB5tt6h4wRGFxDMAf4dAYNpbf0qABAziRozTFZ8yS2zQWLrbdR+kSBXhpdzXCo0c I27uFLylGrzQ6lcEsJs9n09WAQ+yJ9jPfgMbhFeaH1+h1FTZsr+/SXN3Ne7zKFOtzMvPHeXGYlxux zRBtyG9gGhD3UHCPTgPVGIOdqSfM4vl8MmUOPWSOCxaKzhU5euhcjuH9nhmeGsOvtuYaG087ur8OK qnGgUExA==; Received: from [49.36.127.56] (helo=uajain) by fanzine2.igalia.com with esmtpsa (Cipher TLS1.3:ECDHE_X25519__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim) id 1v7Dwi-007uJd-Jp; Fri, 10 Oct 2025 16:18:12 +0200 From: Umang Jain To: libcamera-devel@lists.libcamera.org Cc: Nicolas Dufresne , Umang Jain Subject: [PATCH 1/3] gstreamer: Shorten function name Date: Fri, 10 Oct 2025 19:48:24 +0530 Message-ID: <20251010141826.42995-2-uajain@igalia.com> X-Mailer: git-send-email 2.50.1 In-Reply-To: <20251010141826.42995-1-uajain@igalia.com> References: <20251010141826.42995-1-uajain@igalia.com> MIME-Version: 1.0 X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" Shorten the following utility function name: gst_libcamera_stream_configuration_to_caps() to gst_libcamera_stream_cfg_to_caps() Comestic fix only for slight readability enhancement. Signed-off-by: Umang Jain Reviewed-by: Nicolas Dufresne Reviewed-by: Barnabás Pőcze --- src/gstreamer/gstlibcamera-utils.cpp | 4 ++-- src/gstreamer/gstlibcamera-utils.h | 4 ++-- src/gstreamer/gstlibcamerasrc.cpp | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/gstreamer/gstlibcamera-utils.cpp b/src/gstreamer/gstlibcamera-utils.cpp index bfb094c9..09f274b5 100644 --- a/src/gstreamer/gstlibcamera-utils.cpp +++ b/src/gstreamer/gstlibcamera-utils.cpp @@ -408,8 +408,8 @@ gst_libcamera_stream_formats_to_caps(const StreamFormats &formats) } GstCaps * -gst_libcamera_stream_configuration_to_caps(const StreamConfiguration &stream_cfg, - GstVideoTransferFunction transfer) +gst_libcamera_stream_cfg_to_caps(const StreamConfiguration &stream_cfg, + GstVideoTransferFunction transfer) { GstCaps *caps = gst_caps_new_empty(); GstStructure *s = bare_structure_from_format(stream_cfg.pixelFormat); diff --git a/src/gstreamer/gstlibcamera-utils.h b/src/gstreamer/gstlibcamera-utils.h index 35df56fb..06ea9289 100644 --- a/src/gstreamer/gstlibcamera-utils.h +++ b/src/gstreamer/gstlibcamera-utils.h @@ -16,8 +16,8 @@ #include GstCaps *gst_libcamera_stream_formats_to_caps(const libcamera::StreamFormats &formats); -GstCaps *gst_libcamera_stream_configuration_to_caps(const libcamera::StreamConfiguration &stream_cfg, - GstVideoTransferFunction transfer); +GstCaps *gst_libcamera_stream_cfg_to_caps(const libcamera::StreamConfiguration &stream_cfg, + GstVideoTransferFunction transfer); void gst_libcamera_configure_stream_from_caps(libcamera::StreamConfiguration &stream_cfg, GstCaps *caps, GstVideoTransferFunction *transfer); void gst_libcamera_get_framerate_from_caps(GstCaps *caps, GstStructure *element_caps); diff --git a/src/gstreamer/gstlibcamerasrc.cpp b/src/gstreamer/gstlibcamerasrc.cpp index 79a025a5..9ff90d9a 100644 --- a/src/gstreamer/gstlibcamerasrc.cpp +++ b/src/gstreamer/gstlibcamerasrc.cpp @@ -645,7 +645,7 @@ gst_libcamera_src_negotiate(GstLibcameraSrc *self) GstPad *srcpad = state->srcpads_[i]; const StreamConfiguration &stream_cfg = state->config_->at(i); - g_autoptr(GstCaps) caps = gst_libcamera_stream_configuration_to_caps(stream_cfg, transfer[i]); + g_autoptr(GstCaps) caps = gst_libcamera_stream_cfg_to_caps(stream_cfg, transfer[i]); gst_libcamera_framerate_to_caps(caps, element_caps); if (status == CameraConfiguration::Adjusted && @@ -673,7 +673,7 @@ gst_libcamera_src_negotiate(GstLibcameraSrc *self) GstBufferPool *video_pool = nullptr; GstVideoInfo info; - g_autoptr(GstCaps) caps = gst_libcamera_stream_configuration_to_caps(stream_cfg, transfer[i]); + g_autoptr(GstCaps) caps = gst_libcamera_stream_cfg_to_caps(stream_cfg, transfer[i]); gst_video_info_from_caps(&info, caps); gst_libcamera_pad_set_video_info(srcpad, &info);