org.jcodec.codecs.vp8
Class VP8Util
java.lang.Object
org.jcodec.codecs.vp8.VP8Util
public class VP8Util
- extends Object
|
Method Summary |
static int |
avg2(int x,
int y)
|
static int |
avg3(int x,
int y,
int z)
|
static int |
delta(BooleanArithmeticDecoder bc)
delta() is the process to read 5 bits from the bitstream to determine a signed delta value:
+-------+--------------------------------------------------+
| Index | Description |
+-------+--------------------------------------------------+
| L(4) | Magnitude of delta |
| L(1) | Sign of delta, 0 for positive and 1 for negative |
+-------+--------------------------------------------------+ |
static int |
getBitInBytes(byte[] bs,
int i)
|
static int |
getBitsInBytes(byte[] bytes,
int idx,
int len)
|
static int[][][][] |
getDefaultCoefProbs()
|
static int |
getMacroblockCount(int dimention)
|
static int[] |
pickDefaultPrediction(int intra_bmode)
|
static int |
planeToType(VP8Util.PLANE plane,
Boolean withY2)
|
static int[] |
predictDC(int[] above,
int[] left)
|
static int[] |
predictHD(int[] above,
int[] left,
int aboveLeft)
|
static int[] |
predictHE(int[] left,
int aboveLeft)
|
static int[] |
predictHU(int[] left)
|
static int[] |
predictLD(int[] above,
int[] aboveRight)
|
static int[] |
predictRD(int[] above,
int[] left,
int aboveLeft)
E4|E5|E6|E7|E8|
__|__|__|__|__|
E3|
__|
E2|
__|
E1|
__|
E0|
__| |
static int[] |
predictTM(int[] above,
int[] left,
int aboveLeft)
|
static int[] |
predictVE(int[] above,
int aboveLeft,
int[] aboveRight)
avg3(Pixel x, Pixel y, Pixel z) { avg2(Pixel x, Pixel y) { return (x + y + 1) >> 1;} |
static int[] |
predictVL(int[] above,
int[] aboveRight)
|
static int[] |
predictVR(int[] above,
int[] left,
int aboveLeft)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BLOCK_TYPES
public static int BLOCK_TYPES
COEF_BANDS
public static int COEF_BANDS
PREV_COEF_CONTEXTS
public static int PREV_COEF_CONTEXTS
MAX_ENTROPY_TOKENS
public static int MAX_ENTROPY_TOKENS
MAX_MODE_LF_DELTAS
public static int MAX_MODE_LF_DELTAS
MAX_REF_LF_DELTAS
public static int MAX_REF_LF_DELTAS
MB_FEATURE_TREE_PROBS
public static final int MB_FEATURE_TREE_PROBS
- See Also:
- Constant Field Values
vp8KeyFrameUVModeProb
public static int[] vp8KeyFrameUVModeProb
vp8UVModeTree
public static int[] vp8UVModeTree
+-----------------------------+
| root |
| / \ |
| -DC_PRED 2 |
| / \ |
| -V_PRED 4 |
| / \ |
| -H_PRED -TM_PRED |
+-----------------------------+
keyFrameYModeProb
public static int[] keyFrameYModeProb
keyFrameYModeTree
public static int[] keyFrameYModeTree
- Left branch is picked if 0 is decoded, right branch is picked
if 1 is decoded. Positive value of the node tells the index
of the left-most child. Negative value implies leaf node (no
children), with corresponding absolute value.
0 implies B_PRED is returned.
100 implies DC_PRED is returned.
101 implies V_PRED is returned
110 - H_PRED
111 - TM_PRED
+------------------------------------------+
| root |
| / \ |
| -B_PRED 2------------ |
| / \ |
| 4 6---- |
| / \ / \ |
| -DC_PRED -V_PRED -H_PRED -TM_PRED |
+------------------------------------------+
PRED_BLOCK_127
public static final int[] PRED_BLOCK_127
PRED_BLOCK_129
public static final int[] PRED_BLOCK_129
VP8Util
public VP8Util()
delta
public static int delta(BooleanArithmeticDecoder bc)
- delta() is the process to read 5 bits from the bitstream to determine a signed delta value:
+-------+--------------------------------------------------+
| Index | Description |
+-------+--------------------------------------------------+
| L(4) | Magnitude of delta |
| L(1) | Sign of delta, 0 for positive and 1 for negative |
+-------+--------------------------------------------------+
- Parameters:
bc -
- Returns:
-
- Throws:
IOException
getDefaultCoefProbs
public static int[][][][] getDefaultCoefProbs()
getBitInBytes
public static int getBitInBytes(byte[] bs,
int i)
getBitsInBytes
public static int getBitsInBytes(byte[] bytes,
int idx,
int len)
getMacroblockCount
public static int getMacroblockCount(int dimention)
pickDefaultPrediction
public static int[] pickDefaultPrediction(int intra_bmode)
predictHU
public static int[] predictHU(int[] left)
predictHD
public static int[] predictHD(int[] above,
int[] left,
int aboveLeft)
predictVL
public static int[] predictVL(int[] above,
int[] aboveRight)
predictVR
public static int[] predictVR(int[] above,
int[] left,
int aboveLeft)
predictRD
public static int[] predictRD(int[] above,
int[] left,
int aboveLeft)
E4|E5|E6|E7|E8|
__|__|__|__|__|
E3|
__|
E2|
__|
E1|
__|
E0|
__|
- Parameters:
above - left - aboveLeft -
- Returns:
predictLD
public static int[] predictLD(int[] above,
int[] aboveRight)
predictHE
public static int[] predictHE(int[] left,
int aboveLeft)
predictVE
public static int[] predictVE(int[] above,
int aboveLeft,
int[] aboveRight)
- avg3(Pixel x, Pixel y, Pixel z) { avg2(Pixel x, Pixel y) { return (x + y + 1) >> 1;}
- Parameters:
above - aboveLeft - aboveRight -
- Returns:
avg2
public static int avg2(int x,
int y)
avg3
public static int avg3(int x,
int y,
int z)
predictTM
public static int[] predictTM(int[] above,
int[] left,
int aboveLeft)
predictDC
public static int[] predictDC(int[] above,
int[] left)
planeToType
public static int planeToType(VP8Util.PLANE plane,
Boolean withY2)
Copyright © 2013. All Rights Reserved.