summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--test/test_libvpx.cc16
-rw-r--r--vp8/common/rtcd.c6
-rw-r--r--vp8/vp8_cx_iface.c4
-rw-r--r--vp8/vp8_dx_iface.c4
-rw-r--r--vp9/common/vp9_rtcd.c3
-rw-r--r--vp9/decoder/vp9_decoder.c2
-rw-r--r--vp9/encoder/vp9_encoder.c2
-rw-r--r--vpx_ports/vpx_once.h2
-rw-r--r--vpx_scale/vpx_scale_rtcd.c4
9 files changed, 24 insertions, 19 deletions
diff --git a/test/test_libvpx.cc b/test/test_libvpx.cc
index fc035af8f..dcf5fc52b 100644
--- a/test/test_libvpx.cc
+++ b/test/test_libvpx.cc
@@ -14,11 +14,12 @@
#endif
extern "C" {
#if CONFIG_VP8
-extern void vp8_rtcd();
-#endif
+#include "./vp8_rtcd.h"
+#endif // CONFIG_VP8
#if CONFIG_VP9
-extern void vp9_rtcd();
-#endif
+#include "./vp9_rtcd.h"
+#endif // CONFIG_VP9
+#include "./vpx_scale_rtcd.h"
}
#include "third_party/googletest/src/include/gtest/gtest.h"
@@ -59,11 +60,12 @@ int main(int argc, char **argv) {
#if CONFIG_VP8
vp8_rtcd();
-#endif
+#endif // CONFIG_VP8
#if CONFIG_VP9
vp9_rtcd();
-#endif
-#endif
+#endif // CONFIG_VP9
+ vpx_scale_rtcd();
+#endif // !CONFIG_SHARED
return RUN_ALL_TESTS();
}
diff --git a/vp8/common/rtcd.c b/vp8/common/rtcd.c
index 0b371b094..ab0e9b47f 100644
--- a/vp8/common/rtcd.c
+++ b/vp8/common/rtcd.c
@@ -7,15 +7,13 @@
* in the file PATENTS. All contributing project authors may
* be found in the AUTHORS file in the root of the source tree.
*/
-#include "vpx_config.h"
+#include "./vpx_config.h"
#define RTCD_C
-#include "vp8_rtcd.h"
+#include "./vp8_rtcd.h"
#include "vpx_ports/vpx_once.h"
-extern void vpx_scale_rtcd(void);
void vp8_rtcd()
{
- vpx_scale_rtcd();
once(setup_rtcd_internal);
}
diff --git a/vp8/vp8_cx_iface.c b/vp8/vp8_cx_iface.c
index bf8a8537c..a5dfd07f9 100644
--- a/vp8/vp8_cx_iface.c
+++ b/vp8/vp8_cx_iface.c
@@ -10,7 +10,8 @@
#include "./vpx_config.h"
-#include "vp8_rtcd.h"
+#include "./vp8_rtcd.h"
+#include "./vpx_scale_rtcd.h"
#include "vpx/vpx_codec.h"
#include "vpx/internal/vpx_codec_internal.h"
#include "vpx_version.h"
@@ -649,6 +650,7 @@ static vpx_codec_err_t vp8e_init(vpx_codec_ctx_t *ctx,
vp8_rtcd();
+ vpx_scale_rtcd();
if (!ctx->priv)
{
diff --git a/vp8/vp8_dx_iface.c b/vp8/vp8_dx_iface.c
index 67a0fef64..e0eb30aa5 100644
--- a/vp8/vp8_dx_iface.c
+++ b/vp8/vp8_dx_iface.c
@@ -11,7 +11,8 @@
#include <stdlib.h>
#include <string.h>
-#include "vp8_rtcd.h"
+#include "./vp8_rtcd.h"
+#include "./vpx_scale_rtcd.h"
#include "vpx/vpx_decoder.h"
#include "vpx/vp8dx.h"
#include "vpx/internal/vpx_codec_internal.h"
@@ -106,6 +107,7 @@ static vpx_codec_err_t vp8_init(vpx_codec_ctx_t *ctx,
(void) data;
vp8_rtcd();
+ vpx_scale_rtcd();
/* This function only allocates space for the vpx_codec_alg_priv_t
* structure. More memory may be required at the time the stream
diff --git a/vp9/common/vp9_rtcd.c b/vp9/common/vp9_rtcd.c
index c777bc81f..2dfa09f50 100644
--- a/vp9/common/vp9_rtcd.c
+++ b/vp9/common/vp9_rtcd.c
@@ -12,10 +12,7 @@
#include "./vp9_rtcd.h"
#include "vpx_ports/vpx_once.h"
-void vpx_scale_rtcd(void);
-
void vp9_rtcd() {
- vpx_scale_rtcd();
// TODO(JBB): Remove this once, by insuring that both the encoder and
// decoder setup functions are protected by once();
once(setup_rtcd_internal);
diff --git a/vp9/decoder/vp9_decoder.c b/vp9/decoder/vp9_decoder.c
index 358f22a8d..54802226b 100644
--- a/vp9/decoder/vp9_decoder.c
+++ b/vp9/decoder/vp9_decoder.c
@@ -12,6 +12,7 @@
#include <limits.h>
#include <stdio.h>
+#include "./vp9_rtcd.h"
#include "./vpx_scale_rtcd.h"
#include "vpx_mem/vpx_mem.h"
@@ -39,6 +40,7 @@ static void initialize_dec(void) {
if (!init_done) {
vp9_rtcd();
+ vpx_scale_rtcd();
vp9_init_intra_predictors();
init_done = 1;
}
diff --git a/vp9/encoder/vp9_encoder.c b/vp9/encoder/vp9_encoder.c
index 82f99b3e5..7c7723c32 100644
--- a/vp9/encoder/vp9_encoder.c
+++ b/vp9/encoder/vp9_encoder.c
@@ -13,6 +13,7 @@
#include <limits.h>
#include "./vpx_config.h"
+#include "./vp9_rtcd.h"
#include "./vpx_scale_rtcd.h"
#include "vpx/internal/vpx_psnr.h"
#include "vpx_ports/vpx_timer.h"
@@ -293,6 +294,7 @@ void vp9_initialize_enc(void) {
if (!init_done) {
vp9_rtcd();
+ vpx_scale_rtcd();
vp9_init_intra_predictors();
vp9_init_me_luts();
vp9_rc_init_minq_luts();
diff --git a/vpx_ports/vpx_once.h b/vpx_ports/vpx_once.h
index bd9eebd64..f1df39434 100644
--- a/vpx_ports/vpx_once.h
+++ b/vpx_ports/vpx_once.h
@@ -110,7 +110,7 @@ static void once(void (*func)(void))
#else
-/* No-op version that performs no synchronization. vp8_rtcd() is idempotent,
+/* No-op version that performs no synchronization. *_rtcd() is idempotent,
* so as long as your platform provides atomic loads/stores of pointers
* no synchronization is strictly necessary.
*/
diff --git a/vpx_scale/vpx_scale_rtcd.c b/vpx_scale/vpx_scale_rtcd.c
index 656a22f52..bea603fd1 100644
--- a/vpx_scale/vpx_scale_rtcd.c
+++ b/vpx_scale/vpx_scale_rtcd.c
@@ -7,9 +7,9 @@
* in the file PATENTS. All contributing project authors may
* be found in the AUTHORS file in the root of the source tree.
*/
-#include "vpx_config.h"
+#include "./vpx_config.h"
#define RTCD_C
-#include "vpx_scale_rtcd.h"
+#include "./vpx_scale_rtcd.h"
#include "vpx_ports/vpx_once.h"
void vpx_scale_rtcd()