]> granicus.if.org Git - libvpx/commitdiff
Only build multithreaded functions on mt builds.
authorJohann <johannkoenig@google.com>
Tue, 1 Sep 2015 21:54:52 +0000 (14:54 -0700)
committerJohann <johannkoenig@google.com>
Wed, 2 Sep 2015 00:05:05 +0000 (17:05 -0700)
Change-Id: I2e0cc72a0543bfea1d2d3499b9906519d5cb3f15

vp8/encoder/bitstream.c
vp8/encoder/encodeframe.c

index ea279b321819d81c38d3b3b6b7d707e3ebd5e983..f3d91b5528bc18be11cff361e1c73551ba25e0ea 100644 (file)
@@ -407,6 +407,7 @@ static void pack_tokens_into_partitions(VP8_COMP *cpi, unsigned char *cx_data,
 }
 
 
+#if CONFIG_MULTITHREAD
 static void pack_mb_row_tokens(VP8_COMP *cpi, vp8_writer *w)
 {
     int mb_row;
@@ -421,6 +422,7 @@ static void pack_mb_row_tokens(VP8_COMP *cpi, vp8_writer *w)
     }
 
 }
+#endif  // CONFIG_MULTITHREAD
 
 static void write_mv_ref
 (
@@ -1675,7 +1677,7 @@ void vp8_pack_bitstream(VP8_COMP *cpi, unsigned char *dest, unsigned char * dest
         if (cpi->b_multi_threaded)
             pack_mb_row_tokens(cpi, &cpi->bc[1]);
         else
-#endif
+#endif  // CONFIG_MULTITHREAD
             vp8_pack_tokens(&cpi->bc[1], cpi->tok, cpi->tok_count);
 
         vp8_stop_encode(&cpi->bc[1]);
index d381d8ddf452d5d9592d499d74b5632a83feef84..b0aaa2f0bf0cf7ff8c339353692c0a9055306909 100644 (file)
@@ -700,6 +700,7 @@ static void init_encode_frame_mb_context(VP8_COMP *cpi)
     vp8_zero(x->count_mb_ref_frame_usage);
 }
 
+#if CONFIG_MULTITHREAD
 static void sum_coef_counts(MACROBLOCK *x, MACROBLOCK *x_thread)
 {
     int i = 0;
@@ -729,6 +730,7 @@ static void sum_coef_counts(MACROBLOCK *x, MACROBLOCK *x_thread)
     }
     while (++i < BLOCK_TYPES);
 }
+#endif  // CONFIG_MULTITHREAD
 
 void vp8_encode_frame(VP8_COMP *cpi)
 {
@@ -927,7 +929,7 @@ void vp8_encode_frame(VP8_COMP *cpi)
 
         }
         else
-#endif
+#endif  // CONFIG_MULTITHREAD
         {
 
             /* for each macroblock row in image */