]> granicus.if.org Git - libx264/commitdiff
Enable asm predict_8x8_filter
authorFiona Glaser <fiona@x264.com>
Sat, 18 Apr 2009 06:38:29 +0000 (23:38 -0700)
committerFiona Glaser <fiona@x264.com>
Sat, 18 Apr 2009 06:45:30 +0000 (23:45 -0700)
I'm not entirely sure how this snuck its way out of holger's intra pred patch.

common/predict.c
common/predict.h
encoder/analyse.c
encoder/macroblock.c
encoder/slicetype.c

index 3c6cb1088dabef95a572bad596c402c00c0b6cd7..fd07ae2ede1603882c0345bf6e9bc5715ff74752 100644 (file)
@@ -496,7 +496,7 @@ static void predict_4x4_hu( uint8_t *src )
 #define PT(x) \
     edge[16+x] = F2(SRC(x-1,-1), SRC(x,-1), SRC(x+1,-1));
 
-void x264_predict_8x8_filter( uint8_t *src, uint8_t edge[33], int i_neighbor, int i_filters )
+static void predict_8x8_filter( uint8_t *src, uint8_t edge[33], int i_neighbor, int i_filters )
 {
     /* edge[7..14] = l7..l0
      * edge[15] = lt
@@ -794,7 +794,7 @@ void x264_predict_8x8c_init( int cpu, x264_predict_t pf[7] )
 #endif
 }
 
-void x264_predict_8x8_init( int cpu, x264_predict8x8_t pf[12], x264_predict_8x8_filter_t *predict_8x8_filter )
+void x264_predict_8x8_init( int cpu, x264_predict8x8_t pf[12], x264_predict_8x8_filter_t *predict_filter )
 {
     pf[I_PRED_8x8_V]      = predict_8x8_v;
     pf[I_PRED_8x8_H]      = predict_8x8_h;
@@ -808,10 +808,10 @@ void x264_predict_8x8_init( int cpu, x264_predict8x8_t pf[12], x264_predict_8x8_
     pf[I_PRED_8x8_DC_LEFT]= predict_8x8_dc_left;
     pf[I_PRED_8x8_DC_TOP] = predict_8x8_dc_top;
     pf[I_PRED_8x8_DC_128] = predict_8x8_dc_128;
-    *predict_8x8_filter   = x264_predict_8x8_filter;
+    *predict_filter       = predict_8x8_filter;
 
 #ifdef HAVE_MMX
-    x264_predict_8x8_init_mmx( cpu, pf, predict_8x8_filter );
+    x264_predict_8x8_init_mmx( cpu, pf, predict_filter );
 #endif
 }
 
index 630cadd1b8a0a17fcd0ecbec58ac19fd6e756f2e..d0210abcbff990ba70027d9b1a20b973ec237916 100644 (file)
@@ -106,13 +106,10 @@ enum intra8x8_pred_e
     I_PRED_8x8_DC_128  = 11,
 };
 
-// FIXME enforce edge alignment via uint64_t ?
-void x264_predict_8x8_filter( uint8_t *src, uint8_t edge[33], int i_neighbor, int i_filters );
-
 void x264_predict_16x16_init ( int cpu, x264_predict_t pf[7] );
 void x264_predict_8x8c_init  ( int cpu, x264_predict_t pf[7] );
 void x264_predict_4x4_init   ( int cpu, x264_predict_t pf[12] );
-void x264_predict_8x8_init   ( int cpu, x264_predict8x8_t pf[12], x264_predict_8x8_filter_t *predict_8x8_filter );
+void x264_predict_8x8_init   ( int cpu, x264_predict8x8_t pf[12], x264_predict_8x8_filter_t *predict_filter );
 
 
 #endif
index f7a671ed08e9af57400c00569e267527a076d762..f9958694b6ed22d0a9e5177b0b85c11fa80049b7 100644 (file)
@@ -1005,7 +1005,7 @@ static void x264_intra_rd_refine( x264_t *h, x264_mb_analysis_t *a )
 
             p_dst_by = p_dst + 8*x + 8*y*FDEC_STRIDE;
             predict_4x4_mode_available( h->mb.i_neighbour8[idx], predict_mode, &i_max );
-            x264_predict_8x8_filter( p_dst_by, edge, h->mb.i_neighbour8[idx], ALL_NEIGHBORS );
+            h->predict_8x8_filter( p_dst_by, edge, h->mb.i_neighbour8[idx], ALL_NEIGHBORS );
 
             for( i = 0; i < i_max; i++ )
             {
index 86d452ab265f859deff0aa0f878d0f850839ce13..1aa15b20f96c7fd4b4f83dfd57c98f42741f59a5 100644 (file)
@@ -548,7 +548,7 @@ void x264_macroblock_encode( x264_t *h )
         {
             uint8_t  *p_dst = &h->mb.pic.p_fdec[0][8 * (i&1) + 8 * (i>>1) * FDEC_STRIDE];
             int      i_mode = h->mb.cache.intra4x4_pred_mode[x264_scan8[4*i]];
-            x264_predict_8x8_filter( p_dst, edge, h->mb.i_neighbour8[i], x264_pred_i4x4_neighbors[i_mode] );
+            h->predict_8x8_filter( p_dst, edge, h->mb.i_neighbour8[i], x264_pred_i4x4_neighbors[i_mode] );
 
             if( h->mb.b_lossless )
                 x264_predict_lossless_8x8( h, p_dst, i, i_mode, edge );
index ddc14fa6371ded0f3f68f4dade0ddd4ee44a89e3..d8cb623c2eee96d1b726ec65937c279f0c3290da 100644 (file)
@@ -217,7 +217,7 @@ lowres_intra_mb:
             }
             i_icost = X264_MIN4( satds[0], satds[1], satds[2], satds[3] );
 
-            x264_predict_8x8_filter( pix, edge, ALL_NEIGHBORS, ALL_NEIGHBORS );
+            h->predict_8x8_filter( pix, edge, ALL_NEIGHBORS, ALL_NEIGHBORS );
             for( i=3; i<9; i++ )
             {
                 int satd;