Mercurial > libavcodec.hg
comparison cabac.c @ 6171:1c0477262c72 libavcodec
Fix test program compilation: Add missing #include and update the call
of ff_init_cabac_states() to account for API changes.
author | diego |
---|---|
date | Wed, 23 Jan 2008 10:23:24 +0000 |
parents | ecaf5226e9b0 |
children | f7cbb7733146 |
comparison
equal
deleted
inserted
replaced
6170:8cbfc9d75833 | 6171:1c0477262c72 |
---|---|
181 #ifdef TEST | 181 #ifdef TEST |
182 #undef random | 182 #undef random |
183 #define SIZE 10240 | 183 #define SIZE 10240 |
184 | 184 |
185 #include "avcodec.h" | 185 #include "avcodec.h" |
186 #include "cabac.h" | |
186 | 187 |
187 int main(void){ | 188 int main(void){ |
188 CABACContext c; | 189 CABACContext c; |
189 uint8_t b[9*SIZE]; | 190 uint8_t b[9*SIZE]; |
190 uint8_t r[9*SIZE]; | 191 uint8_t r[9*SIZE]; |
191 int i; | 192 int i; |
192 uint8_t state[10]= {0}; | 193 uint8_t state[10]= {0}; |
193 | 194 |
194 ff_init_cabac_encoder(&c, b, SIZE); | 195 ff_init_cabac_encoder(&c, b, SIZE); |
195 ff_init_cabac_states(&c, ff_h264_lps_range, ff_h264_mps_state, ff_h264_lps_state, 64); | 196 ff_init_cabac_states(&c); |
196 | 197 |
197 for(i=0; i<SIZE; i++){ | 198 for(i=0; i<SIZE; i++){ |
198 r[i]= random()%7; | 199 r[i]= random()%7; |
199 } | 200 } |
200 | 201 |