[libcamera-devel,v6,1/3] android: camera_device: Introduce Camera3StreamConfig
diff mbox series

Message ID 20201211060315.2637333-1-hiroh@chromium.org
State Superseded
Delegated to: Jacopo Mondi
Headers show
Series
  • [libcamera-devel,v6,1/3] android: camera_device: Introduce Camera3StreamConfig
Related show

Commit Message

Hirokazu Honda Dec. 11, 2020, 6:03 a.m. UTC
Camera3StreamConfig is a new class to store camera3_stream and
types with associated StreamConfiguration.

Signed-off-by: Hirokazu Honda <hiroh@chromium.org>
Reviewed-by: Jacopo Mondi <jacopo@jmondi.org>
Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Umang Jain <email@uajain.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
---
 src/android/camera_device.cpp | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

--
2.29.2.576.ga3fc446d84-goog

Comments

Jacopo Mondi Dec. 11, 2020, 8:47 a.m. UTC | #1
Hello,

On Fri, Dec 11, 2020 at 06:03:13AM +0000, Hirokazu Honda wrote:
> Camera3StreamConfig is a new class to store camera3_stream and
> types with associated StreamConfiguration.
>
> Signed-off-by: Hirokazu Honda <hiroh@chromium.org>
> Reviewed-by: Jacopo Mondi <jacopo@jmondi.org>
> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
> Reviewed-by: Umang Jain <email@uajain.com>
> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> ---
>  src/android/camera_device.cpp | 16 ++++++++++++++++
>  1 file changed, 16 insertions(+)
>
> diff --git a/src/android/camera_device.cpp b/src/android/camera_device.cpp
> index 872c7b18..58ff329c 100644
> --- a/src/android/camera_device.cpp
> +++ b/src/android/camera_device.cpp
> @@ -128,6 +128,22 @@ const std::map<int, const Camera3Format> camera3FormatsMap = {
>  	},
>  };
>
> +/*
> + * \struct Camera3StreamConfig
> + * \brief Data to store StreamConfiguration associated with camera3_stream(s).
> + * \var streams List of the pairs of a stream requested by Android HAL client
> + * and associated CameraStream::Type associated with the stream.

One of the two 'associated' should be removed when applying.

> + * \var config StreamConfiguration for streams.
> + */
> +struct Camera3StreamConfig {
> +	struct Camera3Stream {
> +		camera3_stream_t* stream;
> +		CameraStream::Type type;
> +	};
> +
> +	std::vector<Camera3Stream> streams;
> +	StreamConfiguration config;
> +};
>  } /* namespace */
>
>  LOG_DECLARE_CATEGORY(HAL)
> --
> 2.29.2.576.ga3fc446d84-goog
Hirokazu Honda Dec. 11, 2020, 9:36 a.m. UTC | #2
Hello, Jacopo,

On Fri, Dec 11, 2020 at 5:47 PM Jacopo Mondi <jacopo@jmondi.org> wrote:
>
> Hello,
>
> On Fri, Dec 11, 2020 at 06:03:13AM +0000, Hirokazu Honda wrote:
> > Camera3StreamConfig is a new class to store camera3_stream and
> > types with associated StreamConfiguration.
> >
> > Signed-off-by: Hirokazu Honda <hiroh@chromium.org>
> > Reviewed-by: Jacopo Mondi <jacopo@jmondi.org>
> > Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
> > Reviewed-by: Umang Jain <email@uajain.com>
> > Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> > ---
> >  src/android/camera_device.cpp | 16 ++++++++++++++++
> >  1 file changed, 16 insertions(+)
> >
> > diff --git a/src/android/camera_device.cpp b/src/android/camera_device.cpp
> > index 872c7b18..58ff329c 100644
> > --- a/src/android/camera_device.cpp
> > +++ b/src/android/camera_device.cpp
> > @@ -128,6 +128,22 @@ const std::map<int, const Camera3Format> camera3FormatsMap = {
> >       },
> >  };
> >
> > +/*
> > + * \struct Camera3StreamConfig
> > + * \brief Data to store StreamConfiguration associated with camera3_stream(s).
> > + * \var streams List of the pairs of a stream requested by Android HAL client
> > + * and associated CameraStream::Type associated with the stream.
>
> One of the two 'associated' should be removed when applying.
>

Oops, thanks for applying in advance.

> > + * \var config StreamConfiguration for streams.
> > + */
> > +struct Camera3StreamConfig {
> > +     struct Camera3Stream {
> > +             camera3_stream_t* stream;
> > +             CameraStream::Type type;
> > +     };
> > +
> > +     std::vector<Camera3Stream> streams;
> > +     StreamConfiguration config;
> > +};
> >  } /* namespace */
> >
> >  LOG_DECLARE_CATEGORY(HAL)
> > --
> > 2.29.2.576.ga3fc446d84-goog

Patch
diff mbox series

diff --git a/src/android/camera_device.cpp b/src/android/camera_device.cpp
index 872c7b18..58ff329c 100644
--- a/src/android/camera_device.cpp
+++ b/src/android/camera_device.cpp
@@ -128,6 +128,22 @@  const std::map<int, const Camera3Format> camera3FormatsMap = {
 	},
 };

+/*
+ * \struct Camera3StreamConfig
+ * \brief Data to store StreamConfiguration associated with camera3_stream(s).
+ * \var streams List of the pairs of a stream requested by Android HAL client
+ * and associated CameraStream::Type associated with the stream.
+ * \var config StreamConfiguration for streams.
+ */
+struct Camera3StreamConfig {
+	struct Camera3Stream {
+		camera3_stream_t* stream;
+		CameraStream::Type type;
+	};
+
+	std::vector<Camera3Stream> streams;
+	StreamConfiguration config;
+};
 } /* namespace */

 LOG_DECLARE_CATEGORY(HAL)