Orange Pi5 kernel

Deprecated Linux kernel 5.10.110 for OrangePi 5/5B/5+ boards

3 Commits   0 Branches   0 Tags
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   1) .. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   2) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   3) .. _v4l2-meta-fmt-vsp1-hgt:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   4) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   5) *******************************
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   6) V4L2_META_FMT_VSP1_HGT ('VSPT')
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   7) *******************************
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   8) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300   9) Renesas R-Car VSP1 2-D Histogram Data
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  10) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  11) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  12) Description
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  13) ===========
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  14) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  15) This format describes histogram data generated by the Renesas R-Car VSP1
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  16) 2-D Histogram (HGT) engine.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  17) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  18) The VSP1 HGT is a histogram computation engine that operates on HSV
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  19) data. It operates on a possibly cropped and subsampled input image and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  20) computes the sum, maximum and minimum of the S component as well as a
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  21) weighted frequency histogram based on the H and S components.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  22) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  23) The histogram is a matrix of 6 Hue and 32 Saturation buckets, 192 in
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  24) total. Each HSV value is added to one or more buckets with a weight
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  25) between 1 and 16 depending on the Hue areas configuration. Finding the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  26) corresponding buckets is done by inspecting the H and S value independently.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  27) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  28) The Saturation position **n** (0 - 31) of the bucket in the matrix is
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  29) found by the expression:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  30) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  31)     n = S / 8
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  32) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  33) The Hue position **m** (0 - 5) of the bucket in the matrix depends on
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  34) how the HGT Hue areas are configured. There are 6 user configurable Hue
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  35) Areas which can be configured to cover overlapping Hue values:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  36) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  37) .. raw:: latex
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  38) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  39)     \small
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  40) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  41) ::
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  42) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  43)          Area 0       Area 1       Area 2       Area 3       Area 4       Area 5
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  44)         ________     ________     ________     ________     ________     ________
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  45)    \   /|      |\   /|      |\   /|      |\   /|      |\   /|      |\   /|      |\   /
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  46)     \ / |      | \ / |      | \ / |      | \ / |      | \ / |      | \ / |      | \ /
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  47)      X  |      |  X  |      |  X  |      |  X  |      |  X  |      |  X  |      |  X
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  48)     / \ |      | / \ |      | / \ |      | / \ |      | / \ |      | / \ |      | / \
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  49)    /   \|      |/   \|      |/   \|      |/   \|      |/   \|      |/   \|      |/   \
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  50)   5U   0L      0U   1L      1U   2L      2U   3L      3U   4L      4U   5L      5U   0L
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  51)         <0..............................Hue Value............................255>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  52) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  53) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  54) .. raw:: latex
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  55) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  56)     \normalsize
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  57) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  58) When two consecutive areas don't overlap (n+1L is equal to nU) the boundary
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  59) value is considered as part of the lower area.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  60) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  61) Pixels with a hue value included in the centre of an area (between nL and nU
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  62) included) are attributed to that single area and given a weight of 16. Pixels
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  63) with a hue value included in the overlapping region between two areas (between
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  64) n+1L and nU excluded) are attributed to both areas and given a weight for each
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  65) of these areas proportional to their position along the diagonal lines
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  66) (rounded down).
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  67) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  68) The Hue area setup must match one of the following constrains:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  69) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  70) ::
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  71) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  72)     0L <= 0U <= 1L <= 1U <= 2L <= 2U <= 3L <= 3U <= 4L <= 4U <= 5L <= 5U
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  73) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  74) ::
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  75) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  76)     0U <= 1L <= 1U <= 2L <= 2U <= 3L <= 3U <= 4L <= 4U <= 5L <= 5U <= 0L
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  77) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  78) **Byte Order.**
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  79) All data is stored in memory in little endian format. Each cell in the tables
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  80) contains one byte.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  81) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  82) .. flat-table:: VSP1 HGT Data - (776 bytes)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  83)     :header-rows:  2
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  84)     :stub-columns: 0
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  85) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  86)     * - Offset
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  87)       - :cspan:`4` Memory
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  88)     * -
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  89)       - [31:24]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  90)       - [23:16]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  91)       - [15:8]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  92)       - [7:0]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  93)     * - 0
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  94)       - -
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  95)       - S max [7:0]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  96)       - -
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  97)       - S min [7:0]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  98)     * - 4
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  99)       - :cspan:`4` S sum [31:0]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 100)     * - 8
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 101)       - :cspan:`4` Histogram bucket (m=0, n=0) [31:0]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 102)     * - 12
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 103)       - :cspan:`4` Histogram bucket (m=0, n=1) [31:0]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 104)     * -
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 105)       - :cspan:`4` ...
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 106)     * - 132
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 107)       - :cspan:`4` Histogram bucket (m=0, n=31) [31:0]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 108)     * - 136
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 109)       - :cspan:`4` Histogram bucket (m=1, n=0) [31:0]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 110)     * -
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 111)       - :cspan:`4` ...
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 112)     * - 264
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 113)       - :cspan:`4` Histogram bucket (m=2, n=0) [31:0]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 114)     * -
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 115)       - :cspan:`4` ...
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 116)     * - 392
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 117)       - :cspan:`4` Histogram bucket (m=3, n=0) [31:0]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 118)     * -
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 119)       - :cspan:`4` ...
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 120)     * - 520
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 121)       - :cspan:`4` Histogram bucket (m=4, n=0) [31:0]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 122)     * -
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 123)       - :cspan:`4` ...
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 124)     * - 648
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 125)       - :cspan:`4` Histogram bucket (m=5, n=0) [31:0]
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 126)     * -
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 127)       - :cspan:`4` ...
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 128)     * - 772
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 129)       - :cspan:`4` Histogram bucket (m=5, n=31) [31:0]