Go to the documentation of this file.
   23 #ifndef AVCODEC_FFV1_H 
   24 #define AVCODEC_FFV1_H 
   39 #ifdef __INTEL_COMPILER 
   45 #define CONTEXT_SIZE 32 
   47 #define MAX_QUANT_TABLES 8 
   48 #define MAX_CONTEXT_INPUTS 5 
   50 #define AC_GOLOMB_RICE          0 
   51 #define AC_RANGE_DEFAULT_TAB    1 
   52 #define AC_RANGE_CUSTOM_TAB     2 
   53 #define AC_RANGE_DEFAULT_TAB_FORCE -2 
   71 #define MAX_SLICES 1024 
  159     int drift = 
state->drift;
 
  160     int count = 
state->count;
 
  167         state->error_sum >>= 1;
 
  171     if (drift <= -count) {
 
  174         drift = 
FFMAX(drift + count, -count + 1);
 
  175     } 
else if (drift > 0) {
 
  178         drift = 
FFMIN(drift - count, 0);
 
  181     state->drift = drift;
 
  182     state->count = count;
 
  
static void update_vlc_state(VlcState *const state, const int v)
int context_count[MAX_QUANT_TABLES]
This structure describes decoded (raw) audio or video data.
uint8_t(* state)[CONTEXT_SIZE]
struct FFV1Context * slice_context[MAX_SLICES]
int32_t * sample_buffer32
int ff_ffv1_common_init(AVCodecContext *avctx)
int16_t quant_tables[MAX_QUANT_TABLES][MAX_CONTEXT_INPUTS][256]
int ff_ffv1_init_slice_state(const FFV1Context *f, FFV1Context *fs)
void ff_ffv1_clear_slice_state(const FFV1Context *f, FFV1Context *fs)
int ac_byte_count
number of bytes used for AC coding
PlaneContext plane[MAX_PLANES]
int16_t quant_table[MAX_CONTEXT_INPUTS][256]
struct FFV1Context * fsrc
static av_always_inline int fold(int diff, int bits)
int ac
1=range coder <-> 0=golomb rice
uint8_t interlace_bit_state[2]
#define FFABS(a)
Absolute value, Note, INT_MIN / INT64_MIN result in undefined behavior as they are not representable ...
Describe the class of an AVClass context structure.
#define fs(width, name, subs,...)
uint8_t state_transition[256]
static av_always_inline int diff(const struct color_info *a, const struct color_info *b, const int trans_thresh)
int ff_ffv1_init_slices_state(FFV1Context *f)
uint8_t(*[MAX_QUANT_TABLES] initial_states)[32]
int ff_ffv1_allocate_initial_states(FFV1Context *f)
#define MAX_CONTEXT_INPUTS
int ff_ffv1_close(AVCodecContext *avctx)
uint64_t(*[MAX_QUANT_TABLES] rc_stat2)[32][2]
main external API structure.
static av_const int sign_extend(int val, unsigned bits)
int ff_ffv1_init_slice_contexts(FFV1Context *f)
const AVFrame * cur_enc_frame
int16_t quant_table[MAX_CONTEXT_INPUTS][256]