]> granicus.if.org Git - libvpx/commitdiff
Add vp10_ prefix to full_to_model_counts and fill_token_costs
authorhui su <huisu@google.com>
Tue, 12 Apr 2016 17:18:12 +0000 (10:18 -0700)
committerhui su <huisu@google.com>
Tue, 12 Apr 2016 18:06:47 +0000 (11:06 -0700)
Change-Id: I5e6c644fb09f7a80c88142dfdfa05cf5be260241

vp10/encoder/bitstream.c
vp10/encoder/encodeframe.c
vp10/encoder/encoder.c
vp10/encoder/encoder.h
vp10/encoder/rd.c
vp10/encoder/rd.h

index da1885d3ef6a00c889e57954bc2c42c33b3e7b86..7f3b6a2d668b9f9cb68df9966a0016208f217dca 100644 (file)
@@ -2313,8 +2313,8 @@ static void update_coef_probs(VP10_COMP *cpi, vp10_writer* w) {
     vp10_copy(eob_counts_copy, cm->counts.eob_branch);
     for (i = 1; i <= cpi->common.coef_probs_update_idx; ++i) {
       for (tx_size = TX_4X4; tx_size <= max_tx_size; ++tx_size)
-        full_to_model_counts(cm->counts.coef[tx_size],
-                             subframe_stats->coef_counts_buf[i][tx_size]);
+        vp10_full_to_model_counts(cm->counts.coef[tx_size],
+                                  subframe_stats->coef_counts_buf[i][tx_size]);
       vp10_copy(cm->counts.eob_branch, subframe_stats->eob_counts_buf[i]);
       vp10_partial_adapt_probs(cm, 0, 0);
       vp10_copy(subframe_stats->coef_probs_buf[i], cm->fc->coef_probs);
index 88e94867e0d17f30c070018071f326a9628aafca..e6e0b4643675a31eec3cc5f4886459f4b76d2ce9 100644 (file)
@@ -4318,8 +4318,8 @@ static void encode_rd_sb_row(VP10_COMP *cpi,
       SUBFRAME_STATS *subframe_stats = &cpi->subframe_stats;
 
       for (t = TX_4X4; t <= TX_32X32; ++t)
-        full_to_model_counts(cpi->td.counts->coef[t],
-                             cpi->td.rd_counts.coef_counts[t]);
+        vp10_full_to_model_counts(cpi->td.counts->coef[t],
+                                  cpi->td.rd_counts.coef_counts[t]);
       vp10_partial_adapt_probs(cm, mi_row, mi_col);
       ++cm->coef_probs_update_idx;
       vp10_copy(subframe_stats->coef_probs_buf[cm->coef_probs_update_idx],
@@ -4328,7 +4328,7 @@ static void encode_rd_sb_row(VP10_COMP *cpi,
                 cpi->td.rd_counts.coef_counts);
       vp10_copy(subframe_stats->eob_counts_buf[cm->coef_probs_update_idx],
                 cm->counts.eob_branch);
-      fill_token_costs(x->token_costs, cm->fc->coef_probs);
+      vp10_fill_token_costs(x->token_costs, cm->fc->coef_probs);
     }
   }
 #endif  // CONFIG_ENTROPY
index a39575b7738c4cb371f349ea4b3e276cfe5400f3..f412ac0f2d43668a5689a66b4b7974267c8516ea 100644 (file)
@@ -3406,13 +3406,9 @@ static void full_to_model_count(unsigned int *model_count,
   model_count[EOB_MODEL_TOKEN] = full_count[EOB_TOKEN];
 }
 
-#if CONFIG_ENTROPY
-void full_to_model_counts(vp10_coeff_count_model *model_count,
-                                 vp10_coeff_count *full_count) {
-#else
-static void full_to_model_counts(vp10_coeff_count_model *model_count,
-                                 vp10_coeff_count *full_count) {
-#endif  // CONFIG_ENTROPY
+
+void vp10_full_to_model_counts(vp10_coeff_count_model *model_count,
+                               vp10_coeff_count *full_count) {
   int i, j, k, l;
 
   for (i = 0; i < PLANE_TYPES; ++i)
@@ -4403,8 +4399,8 @@ static void encode_frame_to_data_rate(VP10_COMP *cpi,
   vp10_update_reference_frames(cpi);
 
   for (t = TX_4X4; t <= TX_32X32; t++)
-    full_to_model_counts(cpi->td.counts->coef[t],
-                         cpi->td.rd_counts.coef_counts[t]);
+    vp10_full_to_model_counts(cpi->td.counts->coef[t],
+                              cpi->td.rd_counts.coef_counts[t]);
 
   if (cm->refresh_frame_context == REFRESH_FRAME_CONTEXT_BACKWARD) {
 #if CONFIG_ENTROPY
index bf7815f480b12a9219bea7a3a2d319a74aa78a5a..b9847ef9a575361d3134e0bccb9ddc524a1dbdcb 100644 (file)
@@ -630,10 +630,8 @@ int vp10_set_size_literal(VP10_COMP *cpi, unsigned int width,
 
 int vp10_get_quantizer(struct VP10_COMP *cpi);
 
-#if CONFIG_ENTROPY
-void full_to_model_counts(vp10_coeff_count_model *model_count,
-                          vp10_coeff_count *full_count);
-#endif  // CONFIG_ENTROPY
+void vp10_full_to_model_counts(vp10_coeff_count_model *model_count,
+                               vp10_coeff_count *full_count);
 
 static INLINE int frame_is_kf_gf_arf(const VP10_COMP *cpi) {
   return frame_is_intra_only(&cpi->common) ||
index ce9fad73d5c39e6f773f5c8f908b4b929909eb54..dc34f1f54851d6131e632c95047c8f1f21eb9fc4 100644 (file)
@@ -152,13 +152,8 @@ static void fill_mode_costs(VP10_COMP *cpi) {
 #endif  // CONFIG_EXT_INTRA
 }
 
-#if CONFIG_ENTROPY
-void fill_token_costs(vp10_coeff_cost *c,
-                      vp10_coeff_probs_model (*p)[PLANE_TYPES]) {
-#else
-static void fill_token_costs(vp10_coeff_cost *c,
-                             vp10_coeff_probs_model (*p)[PLANE_TYPES]) {
-#endif  // CONFIG_ENTROPY
+void vp10_fill_token_costs(vp10_coeff_cost *c,
+                           vp10_coeff_probs_model (*p)[PLANE_TYPES]) {
   int i, j, k, l;
   TX_SIZE t;
   for (t = TX_4X4; t <= TX_32X32; ++t)
@@ -397,7 +392,7 @@ void vp10_initialize_rd_consts(VP10_COMP *cpi) {
 #endif
   }
   if (cpi->oxcf.pass != 1) {
-    fill_token_costs(x->token_costs, cm->fc->coef_probs);
+    vp10_fill_token_costs(x->token_costs, cm->fc->coef_probs);
 
     if (cpi->sf.partition_search_type != VAR_BASED_PARTITION ||
         cm->frame_type == KEY_FRAME) {
index 80749dcce6996c1c6184a65f2f7022cc5be4c72e..7aad9ebf07eef4f2248b8ac2341b0723541cc934 100644 (file)
@@ -341,10 +341,8 @@ void vp10_update_rd_thresh_fact(const VP10_COMMON *const cm,
                                 int (*fact)[MAX_MODES], int rd_thresh,
                                 int bsize, int best_mode_index);
 
-#if CONFIG_ENTROPY
-void fill_token_costs(vp10_coeff_cost *c,
-                      vp10_coeff_probs_model (*p)[PLANE_TYPES]);
-#endif  // CONFIG_ENTROPY
+void vp10_fill_token_costs(vp10_coeff_cost *c,
+                           vp10_coeff_probs_model (*p)[PLANE_TYPES]);
 
 static INLINE int rd_less_than_thresh(int64_t best_rd, int thresh,
                                       int thresh_fact) {