~ubuntu-branches/ubuntu/lucid/x264/lucid

« back to all changes in this revision

Viewing changes to common/macroblock.c

  • Committer: Bazaar Package Importer
  • Author(s): Reinhard Tartler
  • Date: 2010-02-18 07:39:51 UTC
  • mfrom: (1.1.12 upstream)
  • Revision ID: james.westby@ubuntu.com-20100218073951-z8wi0usfkm3ix2rr
Tags: 2:0.85.1442.1+git781d30-1
* use proper upstream version
  (NB: the first number (85) is the API version,
       the second the number of git commits so far)
* New upstream version should fix: LP: #315697, #463516
* Many ARM Neon Optimisations, LP: #388388
* this package is properly maintained in ubuntu. Indicate this by using
  "-N" as versioning scheme.
* change versioning scheme as discussed with upstream. Requires bumping
  epoch, though.
* ensure that MP4 output support is enabled, LP: #464797

Show diffs side-by-side

added added

removed removed

Lines of Context:
190
190
        const int x8 = i8%2;
191
191
        const int y8 = i8/2;
192
192
        const int i_part_8x8 = i_mb_8x8 + x8 + y8 * h->mb.i_b8_stride;
193
 
        const int i_ref = map_col_to_list0(h->fref1[0]->ref[0][i_part_8x8]);
 
193
        const int i_ref1_ref = h->fref1[0]->ref[0][i_part_8x8];
 
194
        const int i_ref = (map_col_to_list0(i_ref1_ref>>h->sh.b_mbaff) << h->sh.b_mbaff) + (i_ref1_ref&h->sh.b_mbaff);
194
195
 
195
196
        if( i_ref >= 0 )
196
197
        {
271
272
    x264_macroblock_cache_mv_ptr( h, 0, 0, 4, 4, 0, mv[0] );
272
273
    x264_macroblock_cache_mv_ptr( h, 0, 0, 4, 4, 1, mv[1] );
273
274
 
 
275
    if( !M64( mv ) )
 
276
        return 1;
 
277
 
274
278
    if( h->param.i_threads > 1
275
279
        && ( mv[0][1] > h->mb.mv_max_spel[1]
276
280
          || mv[1][1] > h->mb.mv_max_spel[1] ) )
1238
1242
        if( h->sh.i_type == SLICE_TYPE_B )
1239
1243
        {
1240
1244
            h->mb.bipred_weight = h->mb.bipred_weight_buf[h->mb.b_interlaced&(i_mb_y&1)];
 
1245
            h->mb.dist_scale_factor = h->mb.dist_scale_factor_buf[h->mb.b_interlaced&(i_mb_y&1)];
1241
1246
            if( h->param.b_cabac )
1242
1247
            {
1243
1248
                uint8_t skipbp;
1477
1482
                    dist_scale_factor = x264_clip3( (tb * tx + 32) >> 6, -1024, 1023 );
1478
1483
                }
1479
1484
 
1480
 
                // FIXME: will need this if we ever do temporal MV pred with interlaced
1481
 
                if( !h->sh.b_mbaff )
1482
 
                    h->mb.dist_scale_factor[i_ref0][i_ref1] = dist_scale_factor;
 
1485
                h->mb.dist_scale_factor_buf[field][i_ref0][i_ref1] = dist_scale_factor;
1483
1486
 
1484
1487
                dist_scale_factor >>= 2;
1485
1488
                if( h->param.analyse.b_weighted_bipred