diff options
author | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2024-05-08 19:28:06 +0300 |
---|---|---|
committer | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2024-05-08 22:39:50 +0300 |
commit | 626172a16bba9a601c7652569ce9410631c1e6c0 (patch) | |
tree | f337079cde5d77b81b39023576c6ee5e91725f1e /src/android/jpeg | |
parent | fdcd5d04ec6a3b3c98a46041762cdaf4bdb76190 (diff) |
libcamera: Drop file name from header comment blocks
Source files in libcamera start by a comment block header, which
includes the file name and a one-line description of the file contents.
While the latter is useful to get a quick overview of the file contents
at a glance, the former is mostly a source of inconvenience. The name in
the comments can easily get out of sync with the file name when files
are renamed, and copy & paste during development have often lead to
incorrect names being used to start with.
Readers of the source code are expected to know which file they're
looking it. Drop the file name from the header comment block.
The change was generated with the following script:
----------------------------------------
dirs="include/libcamera src test utils"
declare -rA patterns=(
['c']=' \* '
['cpp']=' \* '
['h']=' \* '
['py']='# '
['sh']='# '
)
for ext in ${!patterns[@]} ; do
files=$(for dir in $dirs ; do find $dir -name "*.${ext}" ; done)
pattern=${patterns[${ext}]}
for file in $files ; do
name=$(basename ${file})
sed -i "s/^\(${pattern}\)${name} - /\1/" "$file"
done
done
----------------------------------------
This misses several files that are out of sync with the comment block
header. Those will be addressed separately and manually.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Daniel Scally <dan.scally@ideasonboard.com>
Diffstat (limited to 'src/android/jpeg')
-rw-r--r-- | src/android/jpeg/encoder.h | 2 | ||||
-rw-r--r-- | src/android/jpeg/encoder_jea.cpp | 2 | ||||
-rw-r--r-- | src/android/jpeg/encoder_jea.h | 2 | ||||
-rw-r--r-- | src/android/jpeg/encoder_libjpeg.cpp | 2 | ||||
-rw-r--r-- | src/android/jpeg/encoder_libjpeg.h | 2 | ||||
-rw-r--r-- | src/android/jpeg/exif.cpp | 2 | ||||
-rw-r--r-- | src/android/jpeg/exif.h | 2 | ||||
-rw-r--r-- | src/android/jpeg/post_processor_jpeg.cpp | 2 | ||||
-rw-r--r-- | src/android/jpeg/post_processor_jpeg.h | 2 | ||||
-rw-r--r-- | src/android/jpeg/thumbnailer.cpp | 2 | ||||
-rw-r--r-- | src/android/jpeg/thumbnailer.h | 2 |
11 files changed, 11 insertions, 11 deletions
diff --git a/src/android/jpeg/encoder.h b/src/android/jpeg/encoder.h index 31f26895..ed033c19 100644 --- a/src/android/jpeg/encoder.h +++ b/src/android/jpeg/encoder.h @@ -2,7 +2,7 @@ /* * Copyright (C) 2020, Google Inc. * - * encoder.h - Image encoding interface + * Image encoding interface */ #pragma once diff --git a/src/android/jpeg/encoder_jea.cpp b/src/android/jpeg/encoder_jea.cpp index 7880a6bd..25dc4317 100644 --- a/src/android/jpeg/encoder_jea.cpp +++ b/src/android/jpeg/encoder_jea.cpp @@ -2,7 +2,7 @@ /* * Copyright (C) 2022, Google Inc. * - * encoder_jea.cpp - JPEG encoding using CrOS JEA + * JPEG encoding using CrOS JEA */ #include "encoder_jea.h" diff --git a/src/android/jpeg/encoder_jea.h b/src/android/jpeg/encoder_jea.h index ffe9df27..91115d2e 100644 --- a/src/android/jpeg/encoder_jea.h +++ b/src/android/jpeg/encoder_jea.h @@ -2,7 +2,7 @@ /* * Copyright (C) 2022, Google Inc. * - * encoder_jea.h - JPEG encoding using CrOS JEA + * JPEG encoding using CrOS JEA */ #pragma once diff --git a/src/android/jpeg/encoder_libjpeg.cpp b/src/android/jpeg/encoder_libjpeg.cpp index f4e8dfad..7fc6287e 100644 --- a/src/android/jpeg/encoder_libjpeg.cpp +++ b/src/android/jpeg/encoder_libjpeg.cpp @@ -2,7 +2,7 @@ /* * Copyright (C) 2020, Google Inc. * - * encoder_libjpeg.cpp - JPEG encoding using libjpeg native API + * JPEG encoding using libjpeg native API */ #include "encoder_libjpeg.h" diff --git a/src/android/jpeg/encoder_libjpeg.h b/src/android/jpeg/encoder_libjpeg.h index 146a6a72..4ac85c22 100644 --- a/src/android/jpeg/encoder_libjpeg.h +++ b/src/android/jpeg/encoder_libjpeg.h @@ -2,7 +2,7 @@ /* * Copyright (C) 2020, Google Inc. * - * encoder_libjpeg.h - JPEG encoding using libjpeg + * JPEG encoding using libjpeg */ #pragma once diff --git a/src/android/jpeg/exif.cpp b/src/android/jpeg/exif.cpp index 6b1d0f1f..b8c871df 100644 --- a/src/android/jpeg/exif.cpp +++ b/src/android/jpeg/exif.cpp @@ -2,7 +2,7 @@ /* * Copyright (C) 2020, Google Inc. * - * exif.cpp - EXIF tag creation using libexif + * EXIF tag creation using libexif */ #include "exif.h" diff --git a/src/android/jpeg/exif.h b/src/android/jpeg/exif.h index e68716f3..446d53f3 100644 --- a/src/android/jpeg/exif.h +++ b/src/android/jpeg/exif.h @@ -2,7 +2,7 @@ /* * Copyright (C) 2020, Google Inc. * - * exif.h - EXIF tag creator using libexif + * EXIF tag creator using libexif */ #pragma once diff --git a/src/android/jpeg/post_processor_jpeg.cpp b/src/android/jpeg/post_processor_jpeg.cpp index 40261652..89b8a401 100644 --- a/src/android/jpeg/post_processor_jpeg.cpp +++ b/src/android/jpeg/post_processor_jpeg.cpp @@ -2,7 +2,7 @@ /* * Copyright (C) 2020, Google Inc. * - * post_processor_jpeg.cpp - JPEG Post Processor + * JPEG Post Processor */ #include "post_processor_jpeg.h" diff --git a/src/android/jpeg/post_processor_jpeg.h b/src/android/jpeg/post_processor_jpeg.h index 98309b01..6fe21457 100644 --- a/src/android/jpeg/post_processor_jpeg.h +++ b/src/android/jpeg/post_processor_jpeg.h @@ -2,7 +2,7 @@ /* * Copyright (C) 2020, Google Inc. * - * post_processor_jpeg.h - JPEG Post Processor + * JPEG Post Processor */ #pragma once diff --git a/src/android/jpeg/thumbnailer.cpp b/src/android/jpeg/thumbnailer.cpp index 41c71c76..adafc468 100644 --- a/src/android/jpeg/thumbnailer.cpp +++ b/src/android/jpeg/thumbnailer.cpp @@ -2,7 +2,7 @@ /* * Copyright (C) 2020, Google Inc. * - * thumbnailer.cpp - Simple image thumbnailer + * Simple image thumbnailer */ #include "thumbnailer.h" diff --git a/src/android/jpeg/thumbnailer.h b/src/android/jpeg/thumbnailer.h index d933cf0e..1b836e59 100644 --- a/src/android/jpeg/thumbnailer.h +++ b/src/android/jpeg/thumbnailer.h @@ -2,7 +2,7 @@ /* * Copyright (C) 2020, Google Inc. * - * thumbnailer.h - Simple image thumbnailer + * Simple image thumbnailer */ #pragma once |