1 .. -*- coding: utf-8; mode: rst -*-
3 .. _V4L2-PIX-FMT-SRGGB12P:
4 .. _v4l2-pix-fmt-sbggr12p:
5 .. _v4l2-pix-fmt-sgbrg12p:
6 .. _v4l2-pix-fmt-sgrbg12p:
8 *******************************************************************************************************************************
9 V4L2_PIX_FMT_SRGGB12P ('pRAA'), V4L2_PIX_FMT_SGRBG12P ('pgAA'), V4L2_PIX_FMT_SGBRG12P ('pGAA'), V4L2_PIX_FMT_SBGGR12P ('pBAA'),
10 *******************************************************************************************************************************
13 12-bit packed Bayer formats
19 These four pixel formats are packed raw sRGB / Bayer formats with 12
20 bits per colour. Every two consecutive samples are packed into three
21 bytes. Each of the first two bytes contain the 8 high order bits of
22 the pixels, and the third byte contains the four least significants
23 bits of each pixel, in the same order.
25 Each n-pixel row contains n/2 green samples and n/2 blue or red
26 samples, with alternating green-red and green-blue rows. They are
27 conventionally described as GRGR... BGBG..., RGRG... GBGB..., etc.
28 Below is an example of a small V4L2_PIX_FMT_SBGGR12P image:
31 Each cell is one byte.
33 .. tabularcolumns:: |p{2.0cm}|p{1.0cm}|p{1.0cm}|p{2.7cm}|p{1.0cm}|p{1.0cm}|p{2.7cm}|
39 :widths: 2 1 1 1 1 1 1
45 - G\ :sub:`01low`\ (bits 7--4)
47 B\ :sub:`00low`\ (bits 3--0)
50 - G\ :sub:`03low`\ (bits 7--4)
52 B\ :sub:`02low`\ (bits 3--0)
57 - R\ :sub:`11low`\ (bits 7--4)
59 G\ :sub:`10low`\ (bits 3--0)
62 - R\ :sub:`13low`\ (bits 3--2)
64 G\ :sub:`12low`\ (bits 3--0)
68 - G\ :sub:`21low`\ (bits 7--4)
70 B\ :sub:`20low`\ (bits 3--0)
73 - G\ :sub:`23low`\ (bits 7--4)
75 B\ :sub:`22low`\ (bits 3--0)
79 - R\ :sub:`31low`\ (bits 7--4)
81 G\ :sub:`30low`\ (bits 3--0)
84 - R\ :sub:`33low`\ (bits 3--2)
86 G\ :sub:`32low`\ (bits 3--0)