summaryrefslogtreecommitdiff
path: root/libavcodec/ffv1.h
diff options
context:
space:
mode:
authorVittorio Giovara <vittorio.giovara@gmail.com>2015-11-15 23:26:07 +0100
committerVittorio Giovara <vittorio.giovara@gmail.com>2015-11-16 12:56:31 +0100
commit4bb1070c154e49d35805fbcdac9c9e92f702ef96 (patch)
tree8feca3a3ab44d19cab72718c24bddb803bd12ce4 /libavcodec/ffv1.h
parent9fd2bf09dbc630484d9e88a1d27f7e8508b70a2c (diff)
ffv1: Explicitly name the coder type
FFv1 uses two types of coders, golomb and range with two different tables. This is exposed this in a rather convoluted way, for example mentioning to set coder type 1 while initializing the variable 'ac' to 2, because encoder does not use range coder with default table. Appropriate internal coder type values have been added and used in any check rather than using raw numbers. Initialization of avctx.coder_type in ffv1dec is removed because this field is encoder only. An unneeded validation check in the encoder is dropped too. Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Diffstat (limited to 'libavcodec/ffv1.h')
-rw-r--r--libavcodec/ffv1.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/libavcodec/ffv1.h b/libavcodec/ffv1.h
index 6e8c798b6a..b44253e94c 100644
--- a/libavcodec/ffv1.h
+++ b/libavcodec/ffv1.h
@@ -36,6 +36,10 @@
#define MAX_QUANT_TABLES 8
#define MAX_CONTEXT_INPUTS 5
+#define AC_GOLOMB_RICE 0
+#define AC_RANGE_DEFAULT_TAB 1
+#define AC_RANGE_CUSTOM_TAB 2
+
extern const uint8_t ff_log2_run[41];
extern const int8_t ffv1_quant5_10bit[256];