summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYaowu Xu <yaowu@google.com>2015-07-20 11:05:04 -0700
committerYaowu Xu <yaowu@google.com>2015-07-20 11:20:02 -0700
commitc5ad31e518ceaffebb055e6a186bcece8c6ced96 (patch)
tree776f34b8d78a825c7b361488e3981dc51d99f882
parent345ff1a2f224db82d6f2e2bea638bb48aebf1530 (diff)
downloadlibvpx-c5ad31e518ceaffebb055e6a186bcece8c6ced96.tar.gz
Move bit writer files to vpx_dsp/
Change-Id: Id27e0007a0feac821ca66bcecbf3a723305da82d
-rw-r--r--test/vp9_boolcoder_test.cc3
-rw-r--r--vp9/encoder/vp9_bitstream.c2
-rw-r--r--vp9/encoder/vp9_subexp.c3
-rw-r--r--vp9/encoder/vp9_treewriter.h2
-rw-r--r--vp9/vp9cx.mk4
-rw-r--r--vpx_dsp/vp9_write_bit_buffer.c (renamed from vp9/encoder/vp9_write_bit_buffer.c)3
-rw-r--r--vpx_dsp/vp9_write_bit_buffer.h (renamed from vp9/encoder/vp9_write_bit_buffer.h)0
-rw-r--r--vpx_dsp/vp9_writer.c (renamed from vp9/encoder/vp9_writer.c)4
-rw-r--r--vpx_dsp/vp9_writer.h (renamed from vp9/encoder/vp9_writer.h)0
-rw-r--r--vpx_dsp/vpx_dsp.mk7
10 files changed, 15 insertions, 13 deletions
diff --git a/test/vp9_boolcoder_test.cc b/test/vp9_boolcoder_test.cc
index 28da30319..1829a8628 100644
--- a/test/vp9_boolcoder_test.cc
+++ b/test/vp9_boolcoder_test.cc
@@ -16,8 +16,7 @@
#include "vpx/vpx_integer.h"
#include "vpx_dsp/bitreader.h"
-
-#include "vp9/encoder/vp9_writer.h"
+#include "vpx_dsp/vp9_writer.h"
#include "test/acm_random.h"
diff --git a/vp9/encoder/vp9_bitstream.c b/vp9/encoder/vp9_bitstream.c
index 4ca4083a6..0ab5e8c85 100644
--- a/vp9/encoder/vp9_bitstream.c
+++ b/vp9/encoder/vp9_bitstream.c
@@ -13,6 +13,7 @@
#include <limits.h>
#include "vpx/vpx_encoder.h"
+#include "vpx_dsp/vp9_write_bit_buffer.h"
#include "vpx_mem/vpx_mem.h"
#include "vpx_ports/mem_ops.h"
@@ -32,7 +33,6 @@
#include "vp9/encoder/vp9_segmentation.h"
#include "vp9/encoder/vp9_subexp.h"
#include "vp9/encoder/vp9_tokenize.h"
-#include "vp9/encoder/vp9_write_bit_buffer.h"
static const struct vp9_token intra_mode_encodings[INTRA_MODES] = {
{0, 1}, {6, 3}, {28, 5}, {30, 5}, {58, 6}, {59, 6}, {126, 7}, {127, 7},
diff --git a/vp9/encoder/vp9_subexp.c b/vp9/encoder/vp9_subexp.c
index b345b162c..7b5202b90 100644
--- a/vp9/encoder/vp9_subexp.c
+++ b/vp9/encoder/vp9_subexp.c
@@ -7,13 +7,12 @@
* in the file PATENTS. All contributing project authors may
* be found in the AUTHORS file in the root of the source tree.
*/
+#include "vpx_dsp/vp9_writer.h"
#include "vp9/common/vp9_common.h"
#include "vp9/common/vp9_entropy.h"
-
#include "vp9/encoder/vp9_cost.h"
#include "vp9/encoder/vp9_subexp.h"
-#include "vp9/encoder/vp9_writer.h"
#define vp9_cost_upd256 ((int)(vp9_cost_one(upd) - vp9_cost_zero(upd)))
diff --git a/vp9/encoder/vp9_treewriter.h b/vp9/encoder/vp9_treewriter.h
index 4a76d87cd..22f741562 100644
--- a/vp9/encoder/vp9_treewriter.h
+++ b/vp9/encoder/vp9_treewriter.h
@@ -11,7 +11,7 @@
#ifndef VP9_ENCODER_VP9_TREEWRITER_H_
#define VP9_ENCODER_VP9_TREEWRITER_H_
-#include "vp9/encoder/vp9_writer.h"
+#include "vpx_dsp/vp9_writer.h"
#ifdef __cplusplus
extern "C" {
diff --git a/vp9/vp9cx.mk b/vp9/vp9cx.mk
index 01e5303d0..8836c1ff7 100644
--- a/vp9/vp9cx.mk
+++ b/vp9/vp9cx.mk
@@ -37,10 +37,6 @@ VP9_CX_SRCS-yes += encoder/vp9_extend.c
VP9_CX_SRCS-$(CONFIG_INTERNAL_STATS) += encoder/vp9_fastssim.c
VP9_CX_SRCS-yes += encoder/vp9_firstpass.c
VP9_CX_SRCS-yes += encoder/vp9_block.h
-VP9_CX_SRCS-yes += encoder/vp9_writer.h
-VP9_CX_SRCS-yes += encoder/vp9_writer.c
-VP9_CX_SRCS-yes += encoder/vp9_write_bit_buffer.c
-VP9_CX_SRCS-yes += encoder/vp9_write_bit_buffer.h
VP9_CX_SRCS-yes += encoder/vp9_bitstream.h
VP9_CX_SRCS-yes += encoder/vp9_encodemb.h
VP9_CX_SRCS-yes += encoder/vp9_encodemv.h
diff --git a/vp9/encoder/vp9_write_bit_buffer.c b/vpx_dsp/vp9_write_bit_buffer.c
index 6d55e84e8..f5369134f 100644
--- a/vp9/encoder/vp9_write_bit_buffer.c
+++ b/vpx_dsp/vp9_write_bit_buffer.c
@@ -9,7 +9,8 @@
*/
#include <limits.h>
-#include "vp9/encoder/vp9_write_bit_buffer.h"
+
+#include "./vp9_write_bit_buffer.h"
size_t vp9_wb_bytes_written(const struct vp9_write_bit_buffer *wb) {
return wb->bit_offset / CHAR_BIT + (wb->bit_offset % CHAR_BIT > 0);
diff --git a/vp9/encoder/vp9_write_bit_buffer.h b/vpx_dsp/vp9_write_bit_buffer.h
index 59f9bbe30..59f9bbe30 100644
--- a/vp9/encoder/vp9_write_bit_buffer.h
+++ b/vpx_dsp/vp9_write_bit_buffer.h
diff --git a/vp9/encoder/vp9_writer.c b/vpx_dsp/vp9_writer.c
index ff461f218..9652e1009 100644
--- a/vp9/encoder/vp9_writer.c
+++ b/vpx_dsp/vp9_writer.c
@@ -9,8 +9,8 @@
*/
#include <assert.h>
-#include "vp9/encoder/vp9_writer.h"
-#include "vp9/common/vp9_entropy.h"
+
+#include "./vp9_writer.h"
void vp9_start_encode(vp9_writer *br, uint8_t *source) {
br->lowvalue = 0;
diff --git a/vp9/encoder/vp9_writer.h b/vpx_dsp/vp9_writer.h
index 4526216e9..4526216e9 100644
--- a/vp9/encoder/vp9_writer.h
+++ b/vpx_dsp/vp9_writer.h
diff --git a/vpx_dsp/vpx_dsp.mk b/vpx_dsp/vpx_dsp.mk
index 415a4368b..0cfbbdc2e 100644
--- a/vpx_dsp/vpx_dsp.mk
+++ b/vpx_dsp/vpx_dsp.mk
@@ -17,6 +17,13 @@ DSP_SRCS-$(HAVE_MSA) += mips/macros_msa.h
DSP_SRCS-yes += prob.h
DSP_SRCS-yes += prob.c
+ifeq ($(CONFIG_ENCODERS),yes)
+DSP_SRCS-yes += vp9_writer.h
+DSP_SRCS-yes += vp9_writer.c
+DSP_SRCS-yes += vp9_write_bit_buffer.c
+DSP_SRCS-yes += vp9_write_bit_buffer.h
+endif
+
ifeq ($(CONFIG_DECODERS),yes)
DSP_SRCS-yes += bitreader.h
DSP_SRCS-yes += bitreader.c