| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
package org.tukaani.xz.rangecoder; |
| 7 |
|
| 8 |
import java.util.Arrays; |
| 9 |
|
| 10 |
public abstract class RangeCoder { |
| 11 |
static final int SHIFT_BITS = 8; |
| 12 |
static final int TOP_MASK = 0xFF000000; |
| 13 |
static final int BIT_MODEL_TOTAL_BITS = 11; |
| 14 |
static final int BIT_MODEL_TOTAL = 1 << BIT_MODEL_TOTAL_BITS; |
| 15 |
static final short PROB_INIT = (short)(BIT_MODEL_TOTAL / 2); |
| 16 |
static final int MOVE_BITS = 5; |
| 17 |
|
| 18 |
public static final void initProbs(short[] probs) { |
| 19 |
Arrays.fill(probs, PROB_INIT); |
| 20 |
} |
| 21 |
} |