/*****************************************************************************
* mc.c: motion compensation
*****************************************************************************
- * Copyright (C) 2003-2013 x264 project
+ * Copyright (C) 2003-2014 x264 project
*
* Authors: Laurent Aimar <fenrir@via.ecp.fr>
* Loren Merritt <lorenm@u.washington.edu>
}
}
+void x264_plane_copy_deinterleave_v210_c( pixel *dsty, intptr_t i_dsty,
+ pixel *dstc, intptr_t i_dstc,
+ uint32_t *src, intptr_t i_src, int w, int h )
+{
+ for( int l = 0; l < h; l++ )
+ {
+ pixel *dsty0 = dsty;
+ pixel *dstc0 = dstc;
+ uint32_t *src0 = src;
+
+ for( int n = 0; n < w; n += 3 )
+ {
+ *(dstc0++) = *src0 & 0x03FF;
+ *(dsty0++) = ( *src0 >> 10 ) & 0x03FF;
+ *(dstc0++) = ( *src0 >> 20 ) & 0x03FF;
+ src0++;
+ *(dsty0++) = *src0 & 0x03FF;
+ *(dstc0++) = ( *src0 >> 10 ) & 0x03FF;
+ *(dsty0++) = ( *src0 >> 20 ) & 0x03FF;
+ src0++;
+ }
+
+ dsty += i_dsty;
+ dstc += i_dstc;
+ src += i_src;
+ }
+}
+
static void store_interleave_chroma( pixel *dst, intptr_t i_dst, pixel *srcu, pixel *srcv, int height )
{
for( int y=0; y<height; y++, dst+=i_dst, srcu+=FDEC_STRIDE, srcv+=FDEC_STRIDE )
}
}
-void x264_mc_init( int cpu, x264_mc_functions_t *pf )
+void x264_mc_init( int cpu, x264_mc_functions_t *pf, int cpu_independent )
{
pf->mc_luma = mc_luma;
pf->get_ref = get_ref;
pf->plane_copy_interleave = x264_plane_copy_interleave_c;
pf->plane_copy_deinterleave = x264_plane_copy_deinterleave_c;
pf->plane_copy_deinterleave_rgb = x264_plane_copy_deinterleave_rgb_c;
+ pf->plane_copy_deinterleave_v210 = x264_plane_copy_deinterleave_v210_c;
pf->hpel_filter = hpel_filter;
#if HAVE_ARMV6
x264_mc_init_arm( cpu, pf );
#endif
+
+ if( cpu_independent )
+ pf->mbtree_propagate_cost = mbtree_propagate_cost;
}
void x264_frame_filter( x264_t *h, x264_frame_t *frame, int mb_y, int b_end )