comparison motion_est_template.c @ 4326:9af83350d4fd libavcodec

test DIRECT{0,0} too if flag mv0 is used slight PSNR/bitrate increase
author michael
date Fri, 22 Dec 2006 23:30:57 +0000
parents 13c897abcab3
children e511820c4a97
comparison
equal deleted inserted replaced
4325:e2621acf32f1 4326:9af83350d4fd
1023 dmin= cmp(s, 0, 0, 0, 0, size, h, ref_index, src_index, cmpf, chroma_cmpf, flags); 1023 dmin= cmp(s, 0, 0, 0, 0, size, h, ref_index, src_index, cmpf, chroma_cmpf, flags);
1024 map[0]= map_generation; 1024 map[0]= map_generation;
1025 score_map[0]= dmin; 1025 score_map[0]= dmin;
1026 1026
1027 //FIXME precalc first term below? 1027 //FIXME precalc first term below?
1028 if((s->pict_type == B_TYPE || s->flags&CODEC_FLAG_MV0) && !(c->flags & FLAG_DIRECT)) 1028 if((s->pict_type == B_TYPE && !(c->flags & FLAG_DIRECT)) || s->flags&CODEC_FLAG_MV0)
1029 dmin += (mv_penalty[pred_x] + mv_penalty[pred_y])*penalty_factor; 1029 dmin += (mv_penalty[pred_x] + mv_penalty[pred_y])*penalty_factor;
1030 1030
1031 /* first line */ 1031 /* first line */
1032 if (s->first_slice_line) { 1032 if (s->first_slice_line) {
1033 CHECK_MV(P_LEFT[0]>>shift, P_LEFT[1]>>shift) 1033 CHECK_MV(P_LEFT[0]>>shift, P_LEFT[1]>>shift)