MCPcopy Create free account
hub / github.com/FFmpeg/FFmpeg / encode_blocks

Function encode_blocks

libavcodec/snow.c:3360–3380  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3358}
3359
3360static void encode_blocks(SnowContext *s, int search){
3361 int x, y;
3362 int w= s->b_width;
3363 int h= s->b_height;
3364
3365 if(s->avctx->me_method == ME_ITER && !s->keyframe && search)
3366 iterative_me(s);
3367
3368 for(y=0; y<h; y++){
3369 if(s->c.bytestream_end - s->c.bytestream < w*MB_SIZE*MB_SIZE*3){ //FIXME nicer limit
3370 av_log(s->avctx, AV_LOG_ERROR, "encoded frame too large\n");
3371 return;
3372 }
3373 for(x=0; x<w; x++){
3374 if(s->avctx->me_method == ME_ITER || !search)
3375 encode_q_branch2(s, 0, x, y);
3376 else
3377 encode_q_branch (s, 0, x, y);
3378 }
3379 }
3380}
3381
3382static void quantize(SnowContext *s, SubBand *b, IDWTELEM *dst, DWTELEM *src, int stride, int bias){
3383 const int w= b->width;

Callers 1

encode_frameFunction · 0.85

Calls 4

iterative_meFunction · 0.85
av_logFunction · 0.85
encode_q_branch2Function · 0.85
encode_q_branchFunction · 0.85

Tested by

no test coverage detected