• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/ap/gpl/minidlna/ffmpeg-2.3.4/libavcodec/

Lines Matching refs:vlc

105 static int alloc_table(VLC *vlc, int size, int use_static)
107 int index = vlc->table_size;
109 vlc->table_size += size;
110 if (vlc->table_size > vlc->table_allocated) {
113 vlc->table_allocated += (1 << vlc->bits);
114 vlc->table = av_realloc_f(vlc->table, vlc->table_allocated, sizeof(VLC_TYPE) * 2);
115 if (!vlc->table) {
116 vlc->table_allocated = 0;
117 vlc->table_size = 0;
120 memset(vlc->table + vlc->table_allocated - (1 << vlc->bits), 0, sizeof(VLC_TYPE) * 2 << vlc->bits);
149 * @param vlc the context to be initted
151 * @param table_nb_bits max length of vlc codes to store directly in this table
156 * @param codes descriptions of the vlc codes
160 static int build_table(VLC *vlc, int table_nb_bits, int nb_codes,
171 table_index = alloc_table(vlc, table_size, flags & INIT_VLC_USE_NEW_STATIC);
175 table = (volatile VLC_TYPE (*)[2])&vlc->table[table_index];
226 index = build_table(vlc, subtable_bits, k-i, codes+i, flags);
230 table = (volatile VLC_TYPE (*)[2])&vlc->table[table_index];
253 'bits' : table which gives the size (in bits) of each vlc code.
255 'codes' : table which gives the bit pattern of of each vlc code.
280 VLC localvlc, *vlc;
282 vlc = vlc_arg;
283 vlc->bits = nb_bits;
288 vlc = &localvlc;
289 vlc->table_size = 0;
291 vlc->table = NULL;
292 vlc->table_allocated = 0;
293 vlc->table_size = 0;
337 ret = build_table(vlc, nb_bits, nb_codes, buf, flags);
340 if(vlc->table_size != vlc->table_allocated)
341 av_log(NULL, AV_LOG_ERROR, "needed %d had %d\n", vlc->table_size, vlc->table_allocated);
344 *vlc_arg = *vlc;
348 av_freep(&vlc->table);
356 void ff_free_vlc(VLC *vlc)
358 av_freep(&vlc->table);