200 size = strlen(
"CS=ITU601")+3;
303 int align= (-(size_t)(buf))&3;
309 for(i=0; i<size && i<align; i++){
310 if(buf[i]==0xFF) ff_count++;
312 for(; i<size-15; i+=16){
315 v= *(uint32_t*)(&buf[i]);
316 acc= (((v & (v>>4))&0x0F0F0F0F)+0x01010101)&0x10101010;
317 v= *(uint32_t*)(&buf[i+4]);
318 acc+=(((v & (v>>4))&0x0F0F0F0F)+0x01010101)&0x10101010;
319 v= *(uint32_t*)(&buf[i+8]);
320 acc+=(((v & (v>>4))&0x0F0F0F0F)+0x01010101)&0x10101010;
321 v= *(uint32_t*)(&buf[i+12]);
322 acc+=(((v & (v>>4))&0x0F0F0F0F)+0x01010101)&0x10101010;
330 if(buf[i]==0xFF) ff_count++;
333 if(ff_count==0)
return;
338 for(i=size-1; ff_count; i--){
356 if(length)
put_bits(pbc, length, (1<<length)-1);
379 uint8_t *huff_size, uint16_t *huff_code)
394 put_bits(&s->
pb, huff_size[nbits], huff_code[nbits]);
402 int mant, nbits, code, i, j;
406 uint16_t *huff_code_ac;
409 component = (n <= 3 ? 0 : (n&1) + 1);
411 val = dc - s->
last_dc[component];
427 for(i=1;i<=last_index;i++) {
434 put_bits(&s->
pb, huff_size_ac[0xf0], huff_code_ac[0xf0]);
444 code = (run << 4) | nbits;
446 put_bits(&s->
pb, huff_size_ac[code], huff_code_ac[code]);
454 if (last_index < 63 || run != 0)
455 put_bits(&s->
pb, huff_size_ac[0], huff_code_ac[0]);
496 const AVFrame *pic_arg,
int *got_packet)
508 for(i=0; i < 3; i++) {
515 #if CONFIG_MJPEG_ENCODER
531 #if CONFIG_AMV_ENCODER