public class PCDYCbCrConversion extends java.lang.Object implements RGBIndex, YCbCrIndex
Modifier and Type | Field and Description |
---|---|
private static float |
c11 |
private static float |
c12 |
private static float |
c13 |
private static float |
c21 |
private static float |
c22 |
private static float |
c23 |
private static float |
c31 |
private static float |
c32 |
private static float |
c33 |
INDEX_BLUE, INDEX_GREEN, INDEX_RED
INDEX_CB, INDEX_CR, INDEX_Y
Modifier | Constructor and Description |
---|---|
private |
PCDYCbCrConversion() |
Modifier and Type | Method and Description |
---|---|
private static void |
checkArray(byte[] data,
int offset,
int num) |
static void |
convertYccToRgb(byte[] y,
byte[] cb,
byte[] cr,
int yccOffset,
byte[] r,
byte[] g,
byte[] b,
int rgbOffset,
int num)
Converts pixels from YCbCr to RGB color space.
|
private static byte |
floatToByte(float f) |
private static final float c11
private static final float c12
private static final float c13
private static final float c21
private static final float c22
private static final float c23
private static final float c31
private static final float c32
private static final float c33
private static byte floatToByte(float f)
private static void checkArray(byte[] data, int offset, int num) throws java.lang.IllegalArgumentException
java.lang.IllegalArgumentException
public static void convertYccToRgb(byte[] y, byte[] cb, byte[] cr, int yccOffset, byte[] r, byte[] g, byte[] b, int rgbOffset, int num) throws java.lang.IllegalArgumentException
y
- the array of gray source samplescb
- the array of chroma blue source samplescr
- the array of chroma red source samplesyccOffset
- offset value into the arrays y, cb and cr; color
conversion will be started at the yccOffset'th value of each arrayr
- the array of red destination samplesg
- the array of green destination samplesb
- the array of blue destination samplesrgbOffset
- offset value into the arrays r, g and b; destination samples
will be written to the three arrays starting at the rgbOffset'th value of each arraynum
- the number of pixels to be convertedjava.lang.IllegalArgumentException
- if one of the int values is negative or one
of the arrays is null or too small