[v5,03/18] libcamera: Unify Doxygen file directive prefix for formats.h
diff mbox series

Message ID 20240805143654.20870-4-laurent.pinchart@ideasonboard.com
State Accepted
Headers show
Series
  • Split libcamera documentation in public and internal APIs
Related show

Commit Message

Laurent Pinchart Aug. 5, 2024, 2:36 p.m. UTC
libcamera has two formats.h headers, an internal one in
include/libcamera/internal/, and a public one generated at build time.
The convention is to prefix the internal header name with
libcamera/internal/ in the Doxygen file directive, but formats.cpp only
uses internal/ as a prefix. Unify it with the rest of the code base.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
---
 src/libcamera/formats.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Dan Scally Aug. 6, 2024, 1:48 p.m. UTC | #1
Hi Laurent

On 05/08/2024 15:36, Laurent Pinchart wrote:
> libcamera has two formats.h headers, an internal one in
> include/libcamera/internal/, and a public one generated at build time.
> The convention is to prefix the internal header name with
> libcamera/internal/ in the Doxygen file directive, but formats.cpp only
> uses internal/ as a prefix. Unify it with the rest of the code base.
>
> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> ---


Reviewed-by: Daniel Scally <dan.scally@ideasonboard.com>

>   src/libcamera/formats.cpp | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/libcamera/formats.cpp b/src/libcamera/formats.cpp
> index cf41f2c261ed..72fade7cd41c 100644
> --- a/src/libcamera/formats.cpp
> +++ b/src/libcamera/formats.cpp
> @@ -16,7 +16,7 @@
>   #include <libcamera/formats.h>
>   
>   /**
> - * \file internal/formats.h
> + * \file libcamera/internal/formats.h
>    * \brief Types and helper functions to handle libcamera image formats
>    */
>
Kieran Bingham Aug. 7, 2024, 5:05 a.m. UTC | #2
Quoting Laurent Pinchart (2024-08-05 15:36:39)
> libcamera has two formats.h headers, an internal one in
> include/libcamera/internal/, and a public one generated at build time.
> The convention is to prefix the internal header name with
> libcamera/internal/ in the Doxygen file directive, but formats.cpp only
> uses internal/ as a prefix. Unify it with the rest of the code base.

kbingham@Monstersaurus:~/iob/libcamera/libcamera-clean$ gg "\\\\file " | grep internal
src/libcamera/camera_manager.cpp: * \file libcamera/internal/camera_manager.h
src/libcamera/converter.cpp: * \file internal/converter.h
src/libcamera/converter/converter_v4l2_m2m.cpp: * \file internal/converter/converter_v4l2_m2m.h
src/libcamera/formats.cpp: * \file internal/formats.h
src/libcamera/framebuffer.cpp: * \file libcamera/internal/framebuffer.h
src/libcamera/mapped_framebuffer.cpp: * \file libcamera/internal/mapped_framebuffer.h
src/libcamera/yaml_parser.cpp: * \file libcamera/internal/yaml_parser.h

What about converter.cpp, and converter_v4l2_m2m.cpp ? Or do you prefer
not to change those if they don't have public headers?

Either with those two also updated in here or handled separately:


Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>

> 
> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> ---
>  src/libcamera/formats.cpp | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/src/libcamera/formats.cpp b/src/libcamera/formats.cpp
> index cf41f2c261ed..72fade7cd41c 100644
> --- a/src/libcamera/formats.cpp
> +++ b/src/libcamera/formats.cpp
> @@ -16,7 +16,7 @@
>  #include <libcamera/formats.h>
>  
>  /**
> - * \file internal/formats.h
> + * \file libcamera/internal/formats.h
>   * \brief Types and helper functions to handle libcamera image formats
>   */
>  
> -- 
> Regards,
> 
> Laurent Pinchart
>
Laurent Pinchart Aug. 7, 2024, 12:59 p.m. UTC | #3
On Wed, Aug 07, 2024 at 06:05:20AM +0100, Kieran Bingham wrote:
> Quoting Laurent Pinchart (2024-08-05 15:36:39)
> > libcamera has two formats.h headers, an internal one in
> > include/libcamera/internal/, and a public one generated at build time.
> > The convention is to prefix the internal header name with
> > libcamera/internal/ in the Doxygen file directive, but formats.cpp only
> > uses internal/ as a prefix. Unify it with the rest of the code base.
> 
> kbingham@Monstersaurus:~/iob/libcamera/libcamera-clean$ gg "\\\\file " | grep internal
> src/libcamera/camera_manager.cpp: * \file libcamera/internal/camera_manager.h
> src/libcamera/converter.cpp: * \file internal/converter.h
> src/libcamera/converter/converter_v4l2_m2m.cpp: * \file internal/converter/converter_v4l2_m2m.h
> src/libcamera/formats.cpp: * \file internal/formats.h
> src/libcamera/framebuffer.cpp: * \file libcamera/internal/framebuffer.h
> src/libcamera/mapped_framebuffer.cpp: * \file libcamera/internal/mapped_framebuffer.h
> src/libcamera/yaml_parser.cpp: * \file libcamera/internal/yaml_parser.h
> 
> What about converter.cpp, and converter_v4l2_m2m.cpp ? Or do you prefer
> not to change those if they don't have public headers?

That was the idea, only specifying the full prefix for files that have
both internal and external headers.

> Either with those two also updated in here or handled separately:
> 
> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
> 
> > Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> > ---
> >  src/libcamera/formats.cpp | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> > diff --git a/src/libcamera/formats.cpp b/src/libcamera/formats.cpp
> > index cf41f2c261ed..72fade7cd41c 100644
> > --- a/src/libcamera/formats.cpp
> > +++ b/src/libcamera/formats.cpp
> > @@ -16,7 +16,7 @@
> >  #include <libcamera/formats.h>
> >  
> >  /**
> > - * \file internal/formats.h
> > + * \file libcamera/internal/formats.h
> >   * \brief Types and helper functions to handle libcamera image formats
> >   */
> >

Patch
diff mbox series

diff --git a/src/libcamera/formats.cpp b/src/libcamera/formats.cpp
index cf41f2c261ed..72fade7cd41c 100644
--- a/src/libcamera/formats.cpp
+++ b/src/libcamera/formats.cpp
@@ -16,7 +16,7 @@ 
 #include <libcamera/formats.h>
 
 /**
- * \file internal/formats.h
+ * \file libcamera/internal/formats.h
  * \brief Types and helper functions to handle libcamera image formats
  */