Docstoc

Digital Color Coding

Document Sample
Digital Color Coding Powered By Docstoc
					     Digital Color Coding
Using the YUV model to reduce pixel depth
                    The Big Picture
                                      YUV in between for
RGB at end
                                      transmission, editing, storage
points
                                                            HD-
                                                     SDI or HD-SDI link
                                        CbCr
                                       YCbCr
        24-
        24-bit
     “true color”
      RGB                                   4:2:2



    HD-
    HD-DVD or Blu-Ray
              Blu-                                              4:2:0
         4:2:0          Signal Processing   4:2:0
                            (decode)

                                                    H.264/AVC
                                                      (NAL)



         RGB
           12-
           12-bit                                                           Signal
          “lossy”
                                                                          Processing
         standard
           color                                                        (edit / encode)


                                                                                   2
                        Digital TV Camera
          RGB input                                                           YUV output
                               filters   sensors       encoder         video
          mirror
                                                                       signal
                                                   R                   combiner    Lightly
   lens
                                                                                   Compressed
                                                                                    CbCr
                                                                                   YCbCr
light                                          G
rays                                                                               4:2:2
        semimirrors
                                                                                   (D1 format)
                                                           chrominance
                      mirror                  B                    (Cb,
                                                           signals (Cb, Cr)

                                                                                  270 Mbps
                                                                                  SDI link –
                                                       luminance signal (Y)
                                                                                  goes to tape
                                               luminance                          (88 GB/hour)
                                               matrix                             or broadcast


                                                                                                 3
            YUV Color Model
• Used worldwide by color TV broadcasts
  – Lots of variations: YCbCr, YPbPr, YDbDr, YIQ
• Breaks RGB representation into 4 parts
  – 1 luminance (grayscale) component (Y)
  – 3 chrominance (color) components (Cr, Cg, Cb)
     • Sum to a constant, so only need Cr, Cb (calculate Cg)
     • Calculate YCbCr from RGB and RGB from YCbCr

           RGB to YCbCr                 YCbCr to RGB
               R        G        B
      Y = 0.299R + 0.587G + 0.114B R = Y + 1.402Cr
                B
     Cb = 0.564(B – Y)             B = Y + 1.772Cb
                R
     Cr = 0.713(R – Y)             G = Y – 0.344Cb – 0.714Cr
           YUV Advantages
• Color signals compatible with black & white
  – Just use Y (256 shade grayscale, ignore Cb, Cr)
• Allows pixel depth compression
  – For HVS, luminance (Y) more important than
    chrominance (Cr, Cb)
  – Don’t need full Cb, Cr information for good color
    fidelity as long as keep Y value for each pixel
   YUV Compression Strategy
• Each pixel keeps its Y value, but some
  borrow Cr, Cb from a neighboring pixel
  – Number of pixels that borrow determine amount
    of compression (no borrowing = YUV24 or 4:4:4)
     • YUV16: 1 of 2 pixels borrow = lossy high quality 4:4:2
        – 24 + (1 x 8) = 32 / 2 = 16bpp
        – Used for source, editing
     • YUV12: 3 of 4 pixels borrow = lossy standard 4:2:0
        – 24 + (3 x 8) = 48 / 4 = 12bpp
        – Distribution format used in broadcasts, by DVDs, etc.
     • YUV10: 7 of 8 pixels borrow = noticeable color loss
        – 24 + (7 x 8) = 80 / 8 = 10bpp
     • YUV9: 15 of 16 pixels borrow = “packed color”
        – 24 + (15 x 8) = 144 / 16 = 9bpp
     • YUV8: black & white (luminance only)
                                                                  6
       YUV Compression Schemes
Adjacent pixels are usually similar in color.         4:2:2
                                                Lossy high quality
In YUV compression, every pixel keeps its
own luminance value, but some borrow            Y CbCr        Y
                                                                     Convert YUV24
chrominance from an adjacent pixel.             8 88          8      to YUV16
                              4:4:4                                  Half of pixels
    TrueColor              No compression                            borrow
                                                Y CbCr        Y
                                                8 88          8      chrominance
   RGB      RGB           Y CbCr   Y CbCr
   888      888           8 8 8    8 8 8
                                                      4:2:0
                                                 Lossy standard
   RGB      RGB           Y CbCr   Y CbCr
   888      888           8 8 8    8 8 8                             Convert YUV24
                                                Y CbCr        Y
                                                8 88          8      to YUV12
        Convert RGB24 to YUV24                                       3 of 4 pixels
   Uses same number of bits (no loss of           Y           Y      borrow
   information) but YUV24 scheme divides          8           8      chrominance
   color information by its importance to
   Human Visual System (HVS).
            YUV Compression Levels
   Additional compression      Eliminate 4 bits                Eliminate 12 bits
    gains minor even with
           loss of all color                          YUV12 achieves most of the
          YUV8 – B & W                                possible reduction (short of black
        256 level grayscale                           & white) with good quality color
       YUV9 packed color

        YUV10 reduced color
                                                  Add 4 bits    YUV16 costs 33%
                         YUV12 4:4:0                            more bits for little
                                                                noticeable difference
                                          YUV16 4:4:2

                                                                     True Color 4:4:4
 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
“Lossy” YUV compression: eliminate half the bits but keep good color quality

				
DOCUMENT INFO
Shared By:
Tags:
Stats:
views:44
posted:8/17/2011
language:English
pages:8
Description: YUV is used in European TV systems as a color-coded method (of PAL), the PAL and SECAM analog color television standard used in color space. In the modern color television system, usually used three color camera or color CCD camera to take images, and then the color image signal obtained by color separation, respectively amplified been corrected RGB, and then get through the matrix transformation circuit luminance signal Y and two a color difference signals R-Y (ie U), B-Y (ie V), finally sending the brightness and color difference signals are encoded using the same channel to send out. This color representation is the so-called YUV color space representation. The importance of using YUV color space is its luminance signal Y and chrominance signals U, V are separate.