summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorUmang Jain <umang.jain@ideasonboard.com>2021-05-24 14:50:18 +0530
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2021-05-24 14:13:01 +0300
commitff9276cc626dce468d0f2aa63a908a836a7a33d5 (patch)
tree5fe050d58dc93c5d200033210e0b98b4c160d9a0 /src
parentb9d55fe69ebb6bf146cf8696771faf61fa366762 (diff)
ipa: Move core IPA interface documentation to a .cpp file
Moving the core.mojom documentation to its corresponding .cpp file (core_ipa_interface.cpp). This will allow Doxygen to generate the documentation for IPABuffer, IPASettings and IPAStream structures. Since the .mojom files are placed in include/ directory, the .cpp file will live in $sourcedir/src/libcamera/ipa/ - which can also contain documentation for other mojom generated IPA interfaces in subsequent commit. Also hide the constructors in generated IPA interface from doxygen, via #ifndef __DOXYGEN__. These constructors provide no major value in documenting them, instead will spew out doxygen warnings during the build. Signed-off-by: Umang Jain <umang.jain@ideasonboard.com> Acked-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Paul Elder <paul.elder@ideasonboard.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Diffstat (limited to 'src')
-rw-r--r--src/libcamera/ipa/core_ipa_interface.cpp89
-rw-r--r--src/libcamera/ipa/meson.build5
-rw-r--r--src/libcamera/meson.build1
3 files changed, 95 insertions, 0 deletions
diff --git a/src/libcamera/ipa/core_ipa_interface.cpp b/src/libcamera/ipa/core_ipa_interface.cpp
new file mode 100644
index 00000000..a6711e0e
--- /dev/null
+++ b/src/libcamera/ipa/core_ipa_interface.cpp
@@ -0,0 +1,89 @@
+/* SPDX-License-Identifier: LGPL-2.1-or-later */
+/*
+ * Copyright (C) 2021, Google Inc.
+ *
+ * core_ipa_interface.cpp - Docs file for core.mojom generated header
+ */
+
+namespace libcamera {
+
+/**
+ * \file core_ipa_interface.h
+ * \brief Core IPA inteface
+ */
+
+/**
+ * \struct IPABuffer
+ * \brief Buffer information for the IPA interface
+ *
+ * The IPABuffer structure associates buffer memory with a unique ID. It is
+ * used to map buffers to the IPA with IPAInterface::mapBuffers(), after which
+ * buffers will be identified by their ID in the IPA interface.
+ */
+
+/**
+ * \var IPABuffer::id
+ * \brief The buffer unique ID
+ *
+ * Buffers mapped to the IPA are identified by numerical unique IDs. The IDs
+ * are chosen by the pipeline handler to fulfil the following constraints:
+ *
+ * - IDs shall be positive integers different than zero
+ * - IDs shall be unique among all mapped buffers
+ *
+ * When buffers are unmapped with IPAInterface::unmapBuffers() their IDs are
+ * freed and may be reused for new buffer mappings.
+ */
+
+/**
+ * \var IPABuffer::planes
+ * \brief The buffer planes description
+ *
+ * Stores the dmabuf handle and length for each plane of the buffer.
+ */
+
+/**
+ * \struct IPASettings
+ * \brief IPA interface initialization settings
+ *
+ * The IPASettings structure stores data passed to the IPAInterface::init()
+ * function. The data contains settings that don't depend on a particular camera
+ * or pipeline configuration and are valid for the whole life time of the IPA
+ * interface.
+ */
+
+/**
+ * \var IPASettings::configurationFile
+ * \brief The name of the IPA configuration file
+ *
+ * This field may be an empty string if the IPA doesn't require a configuration
+ * file.
+ */
+
+/**
+ * \var IPASettings::sensorModel
+ * \brief The sensor model name
+ *
+ * Provides the sensor model name to the IPA.
+ */
+
+/**
+ * \struct IPAStream
+ * \brief Stream configuration for the IPA interface
+ *
+ * The IPAStream structure stores stream configuration parameters needed by the
+ * IPAInterface::configure() method. It mirrors the StreamConfiguration class
+ * that is not suitable for this purpose due to not being serializable.
+ */
+
+/**
+ * \var IPAStream::pixelFormat
+ * \brief The stream pixel format
+ */
+
+/**
+ * \var IPAStream::size
+ * \brief The stream size in pixels
+ */
+
+} /* namespace libcamera */
diff --git a/src/libcamera/ipa/meson.build b/src/libcamera/ipa/meson.build
new file mode 100644
index 00000000..560b2fdd
--- /dev/null
+++ b/src/libcamera/ipa/meson.build
@@ -0,0 +1,5 @@
+# SPDX-License-Identifier: CC0-1.0
+
+libcamera_ipa_interfaces = files([
+ 'core_ipa_interface.cpp',
+])
diff --git a/src/libcamera/meson.build b/src/libcamera/meson.build
index 5a41816e..cc2b8669 100644
--- a/src/libcamera/meson.build
+++ b/src/libcamera/meson.build
@@ -66,6 +66,7 @@ includes = [
libcamera_includes,
]
+subdir('ipa')
subdir('pipeline')
subdir('proxy')