From 337e8015c9deaf8ab7e8d0c3c132160a77dd1590 Mon Sep 17 00:00:00 2001 From: hkuang Date: Mon, 7 Jul 2014 14:52:19 -0700 Subject: [PATCH] Move vp9_thread.* to common. Prepare for frame parallel decoding, the reference count buffers need to be protected by mutex. Move vp9_thread.* to common folder so that those buffers could use cross-platform mutex from vp9_thread.*. Change-Id: I541277cf15eefed6641555944f67f4a0bcdc8154 --- test/vp9_thread_test.cc | 2 +- vp9/{decoder => common}/vp9_thread.c | 0 vp9/{decoder => common}/vp9_thread.h | 0 vp9/decoder/vp9_decodeframe.c | 2 +- vp9/decoder/vp9_decoder.h | 2 +- vp9/decoder/vp9_dthread.h | 2 +- vp9/vp9_common.mk | 2 ++ vp9/vp9dx.mk | 2 -- 8 files changed, 6 insertions(+), 6 deletions(-) rename vp9/{decoder => common}/vp9_thread.c (100%) rename vp9/{decoder => common}/vp9_thread.h (100%) diff --git a/test/vp9_thread_test.cc b/test/vp9_thread_test.cc index 72719a698..fa51835a5 100644 --- a/test/vp9_thread_test.cc +++ b/test/vp9_thread_test.cc @@ -18,7 +18,7 @@ #if CONFIG_WEBM_IO #include "test/webm_video_source.h" #endif -#include "vp9/decoder/vp9_thread.h" +#include "vp9/common/vp9_thread.h" namespace { diff --git a/vp9/decoder/vp9_thread.c b/vp9/common/vp9_thread.c similarity index 100% rename from vp9/decoder/vp9_thread.c rename to vp9/common/vp9_thread.c diff --git a/vp9/decoder/vp9_thread.h b/vp9/common/vp9_thread.h similarity index 100% rename from vp9/decoder/vp9_thread.h rename to vp9/common/vp9_thread.h diff --git a/vp9/decoder/vp9_decodeframe.c b/vp9/decoder/vp9_decodeframe.c index 8b96abb9d..a3790d9cc 100644 --- a/vp9/decoder/vp9_decodeframe.c +++ b/vp9/decoder/vp9_decodeframe.c @@ -28,6 +28,7 @@ #include "vp9/common/vp9_reconintra.h" #include "vp9/common/vp9_reconinter.h" #include "vp9/common/vp9_seg_common.h" +#include "vp9/common/vp9_thread.h" #include "vp9/common/vp9_tile_common.h" #include "vp9/decoder/vp9_decodeframe.h" @@ -38,7 +39,6 @@ #include "vp9/decoder/vp9_dthread.h" #include "vp9/decoder/vp9_read_bit_buffer.h" #include "vp9/decoder/vp9_reader.h" -#include "vp9/decoder/vp9_thread.h" #define MAX_VP9_HEADER_SIZE 80 diff --git a/vp9/decoder/vp9_decoder.h b/vp9/decoder/vp9_decoder.h index ab4f9a2c3..2c33316aa 100644 --- a/vp9/decoder/vp9_decoder.h +++ b/vp9/decoder/vp9_decoder.h @@ -18,10 +18,10 @@ #include "vp9/common/vp9_onyxc_int.h" #include "vp9/common/vp9_ppflags.h" +#include "vp9/common/vp9_thread.h" #include "vp9/decoder/vp9_decoder.h" #include "vp9/decoder/vp9_dthread.h" -#include "vp9/decoder/vp9_thread.h" #ifdef __cplusplus extern "C" { diff --git a/vp9/decoder/vp9_dthread.h b/vp9/decoder/vp9_dthread.h index a727e2aef..423bd8808 100644 --- a/vp9/decoder/vp9_dthread.h +++ b/vp9/decoder/vp9_dthread.h @@ -12,8 +12,8 @@ #define VP9_DECODER_VP9_DTHREAD_H_ #include "./vpx_config.h" +#include "vp9/common/vp9_thread.h" #include "vp9/decoder/vp9_reader.h" -#include "vp9/decoder/vp9_thread.h" struct VP9Common; struct VP9Decoder; diff --git a/vp9/vp9_common.mk b/vp9/vp9_common.mk index 8c1f34567..81fe6a620 100644 --- a/vp9/vp9_common.mk +++ b/vp9/vp9_common.mk @@ -50,6 +50,8 @@ VP9_COMMON_SRCS-yes += common/vp9_seg_common.h VP9_COMMON_SRCS-yes += common/vp9_seg_common.c VP9_COMMON_SRCS-yes += common/vp9_systemdependent.h VP9_COMMON_SRCS-yes += common/vp9_textblit.h +VP9_COMMON_SRCS-yes += common/vp9_thread.h +VP9_COMMON_SRCS-yes += common/vp9_thread.c VP9_COMMON_SRCS-yes += common/vp9_tile_common.h VP9_COMMON_SRCS-yes += common/vp9_tile_common.c VP9_COMMON_SRCS-yes += common/vp9_loopfilter.c diff --git a/vp9/vp9dx.mk b/vp9/vp9dx.mk index 92ec6fd16..1fcb36f66 100644 --- a/vp9/vp9dx.mk +++ b/vp9/vp9dx.mk @@ -31,8 +31,6 @@ VP9_DX_SRCS-yes += decoder/vp9_decodemv.h VP9_DX_SRCS-yes += decoder/vp9_detokenize.h VP9_DX_SRCS-yes += decoder/vp9_decoder.c VP9_DX_SRCS-yes += decoder/vp9_decoder.h -VP9_DX_SRCS-yes += decoder/vp9_thread.c -VP9_DX_SRCS-yes += decoder/vp9_thread.h VP9_DX_SRCS-yes += decoder/vp9_dsubexp.c VP9_DX_SRCS-yes += decoder/vp9_dsubexp.h