[{"id":3684,"web_url":"https://patchwork.libcamera.org/comment/3684/","msgid":"<20200212002346.GR20823@pendragon.ideasonboard.com>","date":"2020-02-12T00:23:46","subject":"Re: [libcamera-devel] [PATCH v1 18/23] gst: libcamerapad: Allow\n\tstoring a pool","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"Hi Nicolas,\n\nThank you for the patch.\n\nOn Tue, Jan 28, 2020 at 10:32:05PM -0500, Nicolas Dufresne wrote:\n> From: Nicolas Dufresne <nicolas.dufresne@collabora.com>\n> \n> This add get/set helper to store a pool on the pad.\n\ns/add/adds/\n\n> \n> Signed-off-by: Nicolas Dufresne <nicolas.dufresne@collabora.com>\n\nReviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n\n> ---\n>  src/gstreamer/gstlibcamerapad.cpp | 18 ++++++++++++++++++\n>  src/gstreamer/gstlibcamerapad.h   |  6 ++++++\n>  2 files changed, 24 insertions(+)\n> \n> diff --git a/src/gstreamer/gstlibcamerapad.cpp b/src/gstreamer/gstlibcamerapad.cpp\n> index b18584c..b9e6dc5 100644\n> --- a/src/gstreamer/gstlibcamerapad.cpp\n> +++ b/src/gstreamer/gstlibcamerapad.cpp\n> @@ -16,6 +16,7 @@ using namespace libcamera;\n>  struct _GstLibcameraPad {\n>  \tGstPad parent;\n>  \tStreamRole role;\n> +\tGstLibcameraPool *pool;\n>  };\n>  \n>  enum {\n> @@ -107,3 +108,20 @@ gst_libcamera_pad_get_role(GstPad *pad)\n>  \tGST_OBJECT_LOCKER(self);\n>  \treturn self->role;\n>  }\n> +\n> +GstLibcameraPool *\n> +gst_libcamera_pad_get_pool(GstPad *pad)\n> +{\n> +\tauto *self = GST_LIBCAMERA_PAD(pad);\n> +\treturn self->pool;\n> +}\n> +\n> +void\n> +gst_libcamera_pad_set_pool(GstPad *pad, GstLibcameraPool *pool)\n> +{\n> +\tauto *self = GST_LIBCAMERA_PAD(pad);\n> +\t\n> +\tif (self->pool)\n> +\t\tg_object_unref(self->pool);\n> +\tself->pool = pool;\n> +}\n> diff --git a/src/gstreamer/gstlibcamerapad.h b/src/gstreamer/gstlibcamerapad.h\n> index 3dea0e7..4570c0c 100644\n> --- a/src/gstreamer/gstlibcamerapad.h\n> +++ b/src/gstreamer/gstlibcamerapad.h\n> @@ -9,6 +9,8 @@\n>  #include <gst/gst.h>\n>  #include <libcamera/stream.h>\n>  \n> +#include \"gstlibcamerapool.h\"\n> +\n>  #ifndef __GST_LIBCAMERA_PAD_H__\n>  #define __GST_LIBCAMERA_PAD_H__\n>  \n> @@ -18,4 +20,8 @@ G_DECLARE_FINAL_TYPE(GstLibcameraPad, gst_libcamera_pad,\n>  \n>  libcamera::StreamRole gst_libcamera_pad_get_role(GstPad *pad);\n>  \n> +GstLibcameraPool *gst_libcamera_pad_get_pool(GstPad *pad);\n> +\n> +void gst_libcamera_pad_set_pool(GstPad *pad, GstLibcameraPool *pool);\n> +\n>  #endif /* __GST_LIBCAMERA_PAD_H__ */","headers":{"Return-Path":"<laurent.pinchart@ideasonboard.com>","Received":["from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 89A0561020\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed, 12 Feb 2020 01:24:01 +0100 (CET)","from pendragon.ideasonboard.com (81-175-216-236.bb.dnainternet.fi\n\t[81.175.216.236])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id EA2E59DA;\n\tWed, 12 Feb 2020 01:24:00 +0100 (CET)"],"DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1581467041;\n\tbh=wlPQkDRi/PLPsQe53iLnBG0o/JYa9z0Lo+DM/emWu/E=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=ej1KffHoGwxrAC1neFvcAsSh5T8fVeHF51i1oFddlkAIW+58iHctAbbff8HImjJJp\n\tzDjhnC6cHW0SqY6aYEcirWKqny/MXCHQ+9ji5UrdUybBdqu6f6CuRhAj34HOAgFyxy\n\t9OtpPEGnMwHaYrrgl2HZNddklZuJPYCLwwEp5NX8=","Date":"Wed, 12 Feb 2020 02:23:46 +0200","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"Nicolas Dufresne <nicolas@ndufresne.ca>","Cc":"libcamera-devel@lists.libcamera.org,\n\tNicolas Dufresne <nicolas.dufresne@collabora.com>","Message-ID":"<20200212002346.GR20823@pendragon.ideasonboard.com>","References":"<20200129033210.278800-1-nicolas@ndufresne.ca>\n\t<20200129033210.278800-19-nicolas@ndufresne.ca>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","In-Reply-To":"<20200129033210.278800-19-nicolas@ndufresne.ca>","User-Agent":"Mutt/1.10.1 (2018-07-13)","Subject":"Re: [libcamera-devel] [PATCH v1 18/23] gst: libcamerapad: Allow\n\tstoring a pool","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","X-List-Received-Date":"Wed, 12 Feb 2020 00:24:01 -0000"}}]