![](http://datasheet.mmic.net.cn/370000/TMC2272A_datasheet_16742304/TMC2272A_13.png)
TMC2272A
PRODUCT SPECIFICATION
REV. 1.1.3 10/25/00
13
Since Y = 256, U = V = 0, and G = B = R = 255 for saturated
white output, every Y coefficient will be 255 / 255=1.0. The
full matrix for YUV to GBR conversion is:
G = 1.0 (Y)
-0.3443 (U)
-0.7142 (V)
B = 1.0 (Y)
+1.7727 (U)
R = 1.0 (Y)
+1.3965 (V)
Since the largest element is over 1.0 and the largest permissi-
ble coefficient is 511, multiply all elements of the matrix by
256 to obtain the values to load into the TMC2272A:
G =
256 (Y')
100
- 88 (U')
3A8
- 83 (V')
349
dec.
hex
B =
256 (Y')
100
+ 454 (U')
1C6
dec.
hex
R =
256 (Y')
100
+ 359 (V')
167
dec.
hex
For the YUV to RGB conversion, the TMC2272A input data
alignment for 10-bit Y'U'V' is:
0
Y9 Y8 Y7 Y6 Y5 Y4 Y3 Y2 Y1 Y0 0
U9 U9 U8 U7 U6 U4 U4 U3 U2 U1 U0 0
V9 V9 V8 V7 V6 V5 V4 V3 V2 V1 V0 0
where the doubled U9 and V9 sign bits denote two’s comple-
ment sign extensions. The TMC2272A output data align-
ment for 8-bit GBR is then:
0
0
0
0
G7 G6 G5 G4 G3 G2 G1 G0
0
0
0
0
B7 B6 B5 B4 B3 B2 B1 B0
0
0
0
0
R7 R6 R5 R4 R3 R2 R1 R0
Note that the inputs have to be doubled because the coeffi-
cient gain is 256, whereas the internal gain is 1 / 512, for a
net gain of 1/2.
Table 5. Summary of Colorspace Conversion Coef
fi
cients
Table 6. Conversion Port Assignments and Alignments
Where X
Y-0
denotes right-justified, (e) denotes sign extension, and X
Y-1
denotes shifted one bit leftward from a right-justified
position.
Conversion
RGB to YUV
RGB to YC
B
C
R
YUV to RGB
YC
B
C
R
to RGB
KAX
099
083
100
149
KAY
3AA
3B4
100
149
KAZ
100
0E1
100
149
KBX
12D
102
000
000
KBY
356
36B
3A8
3CE
KBZ
32A
344
1C6
102
KCX
03A
032
167
0CC
KCY
100
0E1
349
398
KCZ
3D6
3DB
000
000
Port
RGB to YUV
RGB to YC
B
C
R
YUV to RGB
YC
B
C
R
to RGB
AIN
R
7-0
R
7-0
Y
8-1
(e)
Y
9-0
BIN
G
7-0
G
7-0
U
8-1
(e)
C
B9-0
(e)
CIN
B
7-0
B
7-0
V
8-1
(e)
C
R9-0
(e)
XOUT
Y
7-0
Y
9-0
R
7-0
R
7-0
YOUT
U
7-0
(e)
U
9-0
(e)
G
7-0
G
7-0
ZOUT
V
7-0
(e)
V
9-0
(e)
B
7-0
B
7-0
HSV (HSI) Format Conversions
HSV (or HSI) refers to Hue (color), Saturation (vividness),
and Value (intensity or brightness), quantities which are
directly related to the human perception of light and color.
The V (or I) levels are simply the Y (or luminance) levels.
Hue and Saturation are derived from the R-Y and B-Y color
difference values of a signal.
HSV Calculations:
Value (V) = Intensity (I) = Y
Hue (H) = Arctan (B-Y/R-Y)
Saturation (S) =
R-Y = S*cos(H)
B-Y = S*sin(H)
One may use two 64Kx8 ROM look-up-tables to calculate
Hue and Saturation from R-Y and B-Y in an 8-bit system.
However, the finite size of this LUT may limit performance,
especially if the TMC2272A’s full precision is used. The
TMC2330A, developed to translate between rectangular and
polar coordinates, can perform the trigonometric transforma-
tions to 16 bit precision at 50MHz. These calculations are
the same as required in HSV calculations. A 4 Gigabyte x 32
bit LUT can achieve the same accuracy and precision as the
TMC2330A, if it is programmed correctly.
R
Y
–
(
)
2
B
Y
–
(
)
2
+