summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Koleszar <jkoleszar@google.com>2011-02-18 00:05:13 -0500
committerJohn Koleszar <jkoleszar@google.com>2011-02-18 00:05:13 -0500
commitf13212b72817ec5e8ec90f8375b98d1515eab27b (patch)
treec5cb709d408e0f9ef451c78a90a213ac3165753b
parent95a86dd007ee53170a25e8406c1d09e40cdbe78a (diff)
parentb2ae57f1b6cbbf018d356528bd8e816752dbbfb7 (diff)
downloadlibvpx-f13212b72817ec5e8ec90f8375b98d1515eab27b.tar
libvpx-f13212b72817ec5e8ec90f8375b98d1515eab27b.tar.gz
libvpx-f13212b72817ec5e8ec90f8375b98d1515eab27b.tar.bz2
libvpx-f13212b72817ec5e8ec90f8375b98d1515eab27b.zip
Merge remote branch 'internal/upstream' into HEAD
-rw-r--r--vp8/common/arm/arm_systemdependent.c14
-rw-r--r--vp8/common/arm/bilinearfilter_arm.c6
-rw-r--r--vp8/common/arm/filter_arm.c4
-rw-r--r--vp8/common/arm/loopfilter_arm.c4
-rw-r--r--vp8/common/arm/neon/recon_neon.c4
-rw-r--r--vp8/common/arm/reconintra_arm.c6
-rw-r--r--vp8/common/generic/systemdependent.c12
-rw-r--r--vp8/common/recon.h1
-rw-r--r--vp8/common/reconintra4x4.c86
-rw-r--r--vp8/common/x86/loopfilter_x86.c2
-rw-r--r--vp8/common/x86/vp8_asm_stubs.c2
-rw-r--r--vp8/common/x86/x86_systemdependent.c14
-rw-r--r--vp8/decoder/arm/arm_dsystemdependent.c10
-rw-r--r--vp8/decoder/arm/armv6/idct_blk_v6.c4
-rw-r--r--vp8/decoder/arm/dequantize_arm.c6
-rw-r--r--vp8/decoder/arm/neon/idct_blk_neon.c4
-rw-r--r--vp8/decoder/decodemv.c6
-rw-r--r--vp8/decoder/decodframe.c28
-rw-r--r--vp8/decoder/dequantize.c4
-rw-r--r--vp8/decoder/dequantize.h2
-rw-r--r--vp8/decoder/detokenize.c4
-rw-r--r--vp8/decoder/generic/dsystemdependent.c4
-rw-r--r--vp8/decoder/idct_blk.c2
-rw-r--r--vp8/decoder/onyxd_if.c20
-rw-r--r--vp8/decoder/onyxd_int.h6
-rw-r--r--vp8/decoder/reconintra_mt.c4
-rw-r--r--vp8/decoder/threading.c8
-rw-r--r--vp8/decoder/treereader.h2
-rw-r--r--vp8/decoder/x86/idct_blk_mmx.c4
-rw-r--r--vp8/decoder/x86/idct_blk_sse2.c4
-rw-r--r--vp8/decoder/x86/onyxdxv.c14
-rw-r--r--vp8/decoder/x86/x86_dsystemdependent.c2
-rw-r--r--vp8/encoder/arm/arm_csystemdependent.c4
-rw-r--r--vp8/encoder/arm/boolhuff_arm.c4
-rw-r--r--vp8/encoder/arm/encodemb_arm.c14
-rw-r--r--vp8/encoder/arm/picklpf_arm.c8
-rw-r--r--vp8/encoder/arm/quantize_arm.c6
-rw-r--r--vp8/encoder/arm/variance_arm.c6
-rw-r--r--vp8/encoder/bitstream.c40
-rw-r--r--vp8/encoder/block.h8
-rw-r--r--vp8/encoder/boolhuff.c2
-rw-r--r--vp8/encoder/encodeframe.c18
-rw-r--r--vp8/encoder/encodeintra.c12
-rw-r--r--vp8/encoder/encodemb.c8
-rw-r--r--vp8/encoder/encodemv.c6
-rw-r--r--vp8/encoder/ethreading.c6
-rw-r--r--vp8/encoder/firstpass.c10
-rw-r--r--vp8/encoder/generic/csystemdependent.c4
-rw-r--r--vp8/encoder/modecosts.c4
-rw-r--r--vp8/encoder/onyx_if.c20
-rw-r--r--vp8/encoder/onyx_int.h10
-rw-r--r--vp8/encoder/parms.cpp2
-rw-r--r--vp8/encoder/pickinter.c12
-rw-r--r--vp8/encoder/pickinter.h2
-rw-r--r--vp8/encoder/picklpf.c4
-rw-r--r--vp8/encoder/ppc/csystemdependent.c4
-rw-r--r--vp8/encoder/psnr.c2
-rw-r--r--vp8/encoder/quantize.c4
-rw-r--r--vp8/encoder/ratectrl.c6
-rw-r--r--vp8/encoder/rdopt.c18
-rw-r--r--vp8/encoder/segmentation.h2
-rw-r--r--vp8/encoder/temporal_filter.c20
-rw-r--r--vp8/encoder/tokenize.h2
-rw-r--r--vp8/encoder/treewriter.h2
-rw-r--r--vp8/encoder/x86/variance_mmx.c4
-rw-r--r--vp8/encoder/x86/variance_sse2.c4
-rw-r--r--vp8/encoder/x86/x86_csystemdependent.c4
-rw-r--r--vp8/vp8_common.mk11
-rw-r--r--vp8/vp8_cx_iface.c4
-rw-r--r--vp8/vp8_dx_iface.c21
-rw-r--r--vp8/vp8cx.mk2
-rw-r--r--vp8/vp8dx.mk3
72 files changed, 247 insertions, 369 deletions
diff --git a/vp8/common/arm/arm_systemdependent.c b/vp8/common/arm/arm_systemdependent.c
index 83921f807..69e1bdff4 100644
--- a/vp8/common/arm/arm_systemdependent.c
+++ b/vp8/common/arm/arm_systemdependent.c
@@ -11,13 +11,13 @@
#include "vpx_ports/config.h"
#include "vpx_ports/arm.h"
-#include "g_common.h"
-#include "pragmas.h"
-#include "subpixel.h"
-#include "loopfilter.h"
-#include "recon.h"
-#include "idct.h"
-#include "onyxc_int.h"
+#include "vp8/common/g_common.h"
+#include "vp8/common/pragmas.h"
+#include "vp8/common/subpixel.h"
+#include "vp8/common/loopfilter.h"
+#include "vp8/common/recon.h"
+#include "vp8/common/idct.h"
+#include "vp8/common/onyxc_int.h"
extern void (*vp8_build_intra_predictors_mby_ptr)(MACROBLOCKD *x);
extern void vp8_build_intra_predictors_mby(MACROBLOCKD *x);
diff --git a/vp8/common/arm/bilinearfilter_arm.c b/vp8/common/arm/bilinearfilter_arm.c
index 6a46ef685..7340e20f3 100644
--- a/vp8/common/arm/bilinearfilter_arm.c
+++ b/vp8/common/arm/bilinearfilter_arm.c
@@ -10,9 +10,9 @@
#include <math.h>
-#include "filter.h"
-#include "subpixel.h"
-#include "arm/bilinearfilter_arm.h"
+#include "vp8/common/filter.h"
+#include "vp8/common/subpixel.h"
+#include "bilinearfilter_arm.h"
void vp8_filter_block2d_bil_armv6
(
diff --git a/vp8/common/arm/filter_arm.c b/vp8/common/arm/filter_arm.c
index 2612fc18a..fe3c5a52e 100644
--- a/vp8/common/arm/filter_arm.c
+++ b/vp8/common/arm/filter_arm.c
@@ -11,8 +11,8 @@
#include "vpx_ports/config.h"
#include <math.h>
-#include "filter.h"
-#include "subpixel.h"
+#include "vp8/common/filter.h"
+#include "vp8/common/subpixel.h"
#include "vpx_ports/mem.h"
extern void vp8_filter_block2d_first_pass_armv6
diff --git a/vp8/common/arm/loopfilter_arm.c b/vp8/common/arm/loopfilter_arm.c
index 684a7f156..3532a0356 100644
--- a/vp8/common/arm/loopfilter_arm.c
+++ b/vp8/common/arm/loopfilter_arm.c
@@ -11,8 +11,8 @@
#include "vpx_ports/config.h"
#include <math.h>
-#include "loopfilter.h"
-#include "onyxc_int.h"
+#include "vp8/common/loopfilter.h"
+#include "vp8/common/onyxc_int.h"
extern prototype_loopfilter(vp8_loop_filter_horizontal_edge_armv6);
extern prototype_loopfilter(vp8_loop_filter_vertical_edge_armv6);
diff --git a/vp8/common/arm/neon/recon_neon.c b/vp8/common/arm/neon/recon_neon.c
index f7930ee5f..09fd2a56f 100644
--- a/vp8/common/arm/neon/recon_neon.c
+++ b/vp8/common/arm/neon/recon_neon.c
@@ -10,8 +10,8 @@
#include "vpx_ports/config.h"
-#include "recon.h"
-#include "blockd.h"
+#include "vp8/common/recon.h"
+#include "vp8/common/blockd.h"
extern void vp8_recon16x16mb_neon(unsigned char *pred_ptr, short *diff_ptr, unsigned char *dst_ptr, int ystride, unsigned char *udst_ptr, unsigned char *vdst_ptr);
diff --git a/vp8/common/arm/reconintra_arm.c b/vp8/common/arm/reconintra_arm.c
index 4cc93d134..f8f4dca3e 100644
--- a/vp8/common/arm/reconintra_arm.c
+++ b/vp8/common/arm/reconintra_arm.c
@@ -10,10 +10,10 @@
#include "vpx_ports/config.h"
-#include "blockd.h"
-#include "reconintra.h"
+#include "vp8/common/blockd.h"
+#include "vp8/common/reconintra.h"
#include "vpx_mem/vpx_mem.h"
-#include "recon.h"
+#include "vp8/common/recon.h"
#if HAVE_ARMV7
extern void vp8_build_intra_predictors_mby_neon_func(
diff --git a/vp8/common/generic/systemdependent.c b/vp8/common/generic/systemdependent.c
index 6ba0cfb87..b2eca3e26 100644
--- a/vp8/common/generic/systemdependent.c
+++ b/vp8/common/generic/systemdependent.c
@@ -10,12 +10,12 @@
#include "vpx_ports/config.h"
-#include "g_common.h"
-#include "subpixel.h"
-#include "loopfilter.h"
-#include "recon.h"
-#include "idct.h"
-#include "onyxc_int.h"
+#include "vp8/common/g_common.h"
+#include "vp8/common/subpixel.h"
+#include "vp8/common/loopfilter.h"
+#include "vp8/common/recon.h"
+#include "vp8/common/idct.h"
+#include "vp8/common/onyxc_int.h"
extern void vp8_arch_x86_common_init(VP8_COMMON *ctx);
extern void vp8_arch_arm_common_init(VP8_COMMON *ctx);
diff --git a/vp8/common/recon.h b/vp8/common/recon.h
index 1e6e343fc..e7df90a71 100644
--- a/vp8/common/recon.h
+++ b/vp8/common/recon.h
@@ -94,6 +94,5 @@ typedef struct vp8_recon_rtcd_vtable
#define RECON_INVOKE(ctx,fn) vp8_recon_##fn
#endif
-void vp8_recon_intra4x4mb(const vp8_recon_rtcd_vtable_t *rtcd, MACROBLOCKD *x);
void vp8_recon_intra_mbuv(const vp8_recon_rtcd_vtable_t *rtcd, MACROBLOCKD *x);
#endif
diff --git a/vp8/common/reconintra4x4.c b/vp8/common/reconintra4x4.c
index d3d133836..8ddae0059 100644
--- a/vp8/common/reconintra4x4.c
+++ b/vp8/common/reconintra4x4.c
@@ -313,89 +313,3 @@ void vp8_intra_prediction_down_copy(MACROBLOCKD *x)
}
-void vp8_recon_intra4x4mb(const vp8_recon_rtcd_vtable_t *rtcd, MACROBLOCKD *x)
-{
- int i;
-
- vp8_intra_prediction_down_copy(x);
-
-#if ARCH_ARM
- {
- BLOCKD *b = &x->block[0];
-
- vp8_predict_intra4x4(b, b->bmi.mode, b->predictor);
- RECON_INVOKE(rtcd, recon)(b->predictor, b->diff, *(b->base_dst) + b->dst, b->dst_stride);
- b += 1;
-
- vp8_predict_intra4x4(b, b->bmi.mode, b->predictor);
- RECON_INVOKE(rtcd, recon)(b->predictor, b->diff, *(b->base_dst) + b->dst, b->dst_stride);
- b += 1;
-
- vp8_predict_intra4x4(b, b->bmi.mode, b->predictor);
- RECON_INVOKE(rtcd, recon)(b->predictor, b->diff, *(b->base_dst) + b->dst, b->dst_stride);
- b += 1;
-
- vp8_predict_intra4x4(b, b->bmi.mode, b->predictor);
- RECON_INVOKE(rtcd, recon)(b->predictor, b->diff, *(b->base_dst) + b->dst, b->dst_stride);
- b += 1;
-
- vp8_predict_intra4x4(b, b->bmi.mode, b->predictor);
- RECON_INVOKE(rtcd, recon)(b->predictor, b->diff, *(b->base_dst) + b->dst, b->dst_stride);
- b += 1;
-
- vp8_predict_intra4x4(b, b->bmi.mode, b->predictor);
- RECON_INVOKE(rtcd, recon)(b->predictor, b->diff, *(b->base_dst) + b->dst, b->dst_stride);
- b += 1;
-
- vp8_predict_intra4x4(b, b->bmi.mode, b->predictor);
- RECON_INVOKE(rtcd, recon)(b->predictor, b->diff, *(b->base_dst) + b->dst, b->dst_stride);
- b += 1;
-
- vp8_predict_intra4x4(b, b->bmi.mode, b->predictor);
- RECON_INVOKE(rtcd, recon)(b->predictor, b->diff, *(b->base_dst) + b->dst, b->dst_stride);
- b += 1;
-
- vp8_predict_intra4x4(b, b->bmi.mode, b->predictor);
- RECON_INVOKE(rtcd, recon)(b->predictor, b->diff, *(b->base_dst) + b->dst, b->dst_stride);
- b += 1;
-
- vp8_predict_intra4x4(b, b->bmi.mode, b->predictor);
- RECON_INVOKE(rtcd, recon)(b->predictor, b->diff, *(b->base_dst) + b->dst, b->dst_stride);
- b += 1;
-
- vp8_predict_intra4x4(b, b->bmi.mode, b->predictor);
- RECON_INVOKE(rtcd, recon)(b->predictor, b->diff, *(b->base_dst) + b->dst, b->dst_stride);
- b += 1;
-
- vp8_predict_intra4x4(b, b->bmi.mode, b->predictor);
- RECON_INVOKE(rtcd, recon)(b->predictor, b->diff, *(b->base_dst) + b->dst, b->dst_stride);
- b += 1;
-
- vp8_predict_intra4x4(b, b->bmi.mode, b->predictor);
- RECON_INVOKE(rtcd, recon)(b->predictor, b->diff, *(b->base_dst) + b->dst, b->dst_stride);
- b += 1;
-
- vp8_predict_intra4x4(b, b->bmi.mode, b->predictor);
- RECON_INVOKE(rtcd, recon)(b->predictor, b->diff, *(b->base_dst) + b->dst, b->dst_stride);
- b += 1;
-
- vp8_predict_intra4x4(b, b->bmi.mode, b->predictor);
- RECON_INVOKE(rtcd, recon)(b->predictor, b->diff, *(b->base_dst) + b->dst, b->dst_stride);
- b += 1;
-
- vp8_predict_intra4x4(b, b->bmi.mode, b->predictor);
- RECON_INVOKE(rtcd, recon)(b->predictor, b->diff, *(b->base_dst) + b->dst, b->dst_stride);
- }
-#else
- for (i = 0; i < 16; i++)
- {
- BLOCKD *b = &x->block[i];
-
- vp8_predict_intra4x4(b, x->block[i].bmi.mode, x->block[i].predictor);
- RECON_INVOKE(rtcd, recon)(b->predictor, b->diff, *(b->base_dst) + b->dst, b->dst_stride);
- }
-#endif
-
- vp8_recon_intra_mbuv(rtcd, x);
-
-}
diff --git a/vp8/common/x86/loopfilter_x86.c b/vp8/common/x86/loopfilter_x86.c
index 3621fe1d7..5837bc0dc 100644
--- a/vp8/common/x86/loopfilter_x86.c
+++ b/vp8/common/x86/loopfilter_x86.c
@@ -10,7 +10,7 @@
#include "vpx_ports/config.h"
-#include "loopfilter.h"
+#include "vp8/common/loopfilter.h"
prototype_loopfilter(vp8_loop_filter_horizontal_edge_c);
prototype_loopfilter(vp8_loop_filter_vertical_edge_c);
diff --git a/vp8/common/x86/vp8_asm_stubs.c b/vp8/common/x86/vp8_asm_stubs.c
index 8dd07c90d..790400609 100644
--- a/vp8/common/x86/vp8_asm_stubs.c
+++ b/vp8/common/x86/vp8_asm_stubs.c
@@ -11,7 +11,7 @@
#include "vpx_ports/config.h"
#include "vpx_ports/mem.h"
-#include "subpixel.h"
+#include "vp8/common/subpixel.h"
extern const short vp8_six_tap_mmx[8][6*8];
extern const short vp8_bilinear_filters_mmx[8][2*8];
diff --git a/vp8/common/x86/x86_systemdependent.c b/vp8/common/x86/x86_systemdependent.c
index 38500fd01..e89c07a4f 100644
--- a/vp8/common/x86/x86_systemdependent.c
+++ b/vp8/common/x86/x86_systemdependent.c
@@ -11,13 +11,13 @@
#include "vpx_ports/config.h"
#include "vpx_ports/x86.h"
-#include "g_common.h"
-#include "subpixel.h"
-#include "loopfilter.h"
-#include "recon.h"
-#include "idct.h"
-#include "pragmas.h"
-#include "onyxc_int.h"
+#include "vp8/common/g_common.h"
+#include "vp8/common/subpixel.h"
+#include "vp8/common/loopfilter.h"
+#include "vp8/common/recon.h"
+#include "vp8/common/idct.h"
+#include "vp8/common/pragmas.h"
+#include "vp8/common/onyxc_int.h"
void vp8_arch_x86_common_init(VP8_COMMON *ctx)
{
diff --git a/vp8/decoder/arm/arm_dsystemdependent.c b/vp8/decoder/arm/arm_dsystemdependent.c
index 02e45d170..51e901d79 100644
--- a/vp8/decoder/arm/arm_dsystemdependent.c
+++ b/vp8/decoder/arm/arm_dsystemdependent.c
@@ -11,11 +11,11 @@
#include "vpx_ports/config.h"
#include "vpx_ports/arm.h"
-#include "blockd.h"
-#include "pragmas.h"
-#include "postproc.h"
-#include "dequantize.h"
-#include "onyxd_int.h"
+#include "vp8/common/blockd.h"
+#include "vp8/common/pragmas.h"
+#include "vp8/common/postproc.h"
+#include "vp8/decoder/dequantize.h"
+#include "vp8/decoder/onyxd_int.h"
void vp8_arch_arm_decode_init(VP8D_COMP *pbi)
{
diff --git a/vp8/decoder/arm/armv6/idct_blk_v6.c b/vp8/decoder/arm/armv6/idct_blk_v6.c
index 3c7bc502f..57c344698 100644
--- a/vp8/decoder/arm/armv6/idct_blk_v6.c
+++ b/vp8/decoder/arm/armv6/idct_blk_v6.c
@@ -9,8 +9,8 @@
*/
#include "vpx_ports/config.h"
-#include "idct.h"
-#include "dequantize.h"
+#include "vp8/common/idct.h"
+#include "vp8/decoder/dequantize.h"
void vp8_dequant_dc_idct_add_y_block_v6
(short *q, short *dq, unsigned char *pre,
diff --git a/vp8/decoder/arm/dequantize_arm.c b/vp8/decoder/arm/dequantize_arm.c
index b3e14b793..b26af975f 100644
--- a/vp8/decoder/arm/dequantize_arm.c
+++ b/vp8/decoder/arm/dequantize_arm.c
@@ -10,9 +10,9 @@
#include "vpx_ports/config.h"
-#include "dequantize.h"
-#include "predictdc.h"
-#include "idct.h"
+#include "vp8/decoder/dequantize.h"
+#include "vp8/common/predictdc.h"
+#include "vp8/common/idct.h"
#include "vpx_mem/vpx_mem.h"
#if HAVE_ARMV7
diff --git a/vp8/decoder/arm/neon/idct_blk_neon.c b/vp8/decoder/arm/neon/idct_blk_neon.c
index fe4f2e0d4..ee3500425 100644
--- a/vp8/decoder/arm/neon/idct_blk_neon.c
+++ b/vp8/decoder/arm/neon/idct_blk_neon.c
@@ -9,8 +9,8 @@
*/
#include "vpx_ports/config.h"
-#include "idct.h"
-#include "dequantize.h"
+#include "vp8/common/idct.h"
+#include "vp8/decoder/dequantize.h"
/* place these declarations here because we don't want to maintain them
* outside of this scope
diff --git a/vp8/decoder/decodemv.c b/vp8/decoder/decodemv.c
index 415392b68..d67cb54fa 100644
--- a/vp8/decoder/decodemv.c
+++ b/vp8/decoder/decodemv.c
@@ -10,10 +10,10 @@
#include "treereader.h"
-#include "entropymv.h"
-#include "entropymode.h"
+#include "vp8/common/entropymv.h"
+#include "vp8/common/entropymode.h"
#include "onyxd_int.h"
-#include "findnearmv.h"
+#include "vp8/common/findnearmv.h"
#if CONFIG_DEBUG
#include <assert.h>
diff --git a/vp8/decoder/decodframe.c b/vp8/decoder/decodframe.c
index c97fa7f5f..323ab9a3f 100644
--- a/vp8/decoder/decodframe.c
+++ b/vp8/decoder/decodframe.c
@@ -10,28 +10,28 @@
#include "onyxd_int.h"
-#include "header.h"
-#include "reconintra.h"
-#include "reconintra4x4.h"
-#include "recon.h"
-#include "reconinter.h"
+#include "vp8/common/header.h"
+#include "vp8/common/reconintra.h"
+#include "vp8/common/reconintra4x4.h"
+#include "vp8/common/recon.h"
+#include "vp8/common/reconinter.h"
#include "dequantize.h"
#include "detokenize.h"
-#include "invtrans.h"
-#include "alloccommon.h"
-#include "entropymode.h"
-#include "quant_common.h"
+#include "vp8/common/invtrans.h"
+#include "vp8/common/alloccommon.h"
+#include "vp8/common/entropymode.h"
+#include "vp8/common/quant_common.h"
#include "vpx_scale/vpxscale.h"
#include "vpx_scale/yv12extend.h"
-#include "setupintrarecon.h"
+#include "vp8/common/setupintrarecon.h"
#include "decodemv.h"
-#include "extend.h"
+#include "vp8/common/extend.h"
#include "vpx_mem/vpx_mem.h"
-#include "idct.h"
+#include "vp8/common/idct.h"
#include "dequantize.h"
-#include "predictdc.h"
-#include "threading.h"
+#include "vp8/common/predictdc.h"
+#include "vp8/common/threading.h"
#include "decoderthreading.h"
#include "dboolhuff.h"
diff --git a/vp8/decoder/dequantize.c b/vp8/decoder/dequantize.c
index 84a9fd943..4e1a5e17a 100644
--- a/vp8/decoder/dequantize.c
+++ b/vp8/decoder/dequantize.c
@@ -11,8 +11,8 @@
#include "vpx_ports/config.h"
#include "dequantize.h"
-#include "predictdc.h"
-#include "idct.h"
+#include "vp8/common/predictdc.h"
+#include "vp8/common/idct.h"
#include "vpx_mem/vpx_mem.h"
extern void vp8_short_idct4x4llm_c(short *input, short *output, int pitch) ;
diff --git a/vp8/decoder/dequantize.h b/vp8/decoder/dequantize.h
index b78e39c1d..2e662a593 100644
--- a/vp8/decoder/dequantize.h
+++ b/vp8/decoder/dequantize.h
@@ -11,7 +11,7 @@
#ifndef DEQUANTIZE_H
#define DEQUANTIZE_H
-#include "blockd.h"
+#include "vp8/common/blockd.h"
#define prototype_dequant_block(sym) \
void sym(BLOCKD *x)
diff --git a/vp8/decoder/detokenize.c b/vp8/decoder/detokenize.c
index 93caa74ea..e4440f0f6 100644
--- a/vp8/decoder/detokenize.c
+++ b/vp8/decoder/detokenize.c
@@ -9,8 +9,8 @@
*/
-#include "type_aliases.h"
-#include "blockd.h"
+#include "vp8/common/type_aliases.h"
+#include "vp8/common/blockd.h"
#include "onyxd_int.h"
#include "vpx_mem/vpx_mem.h"
#include "vpx_ports/mem.h"
diff --git a/vp8/decoder/generic/dsystemdependent.c b/vp8/decoder/generic/dsystemdependent.c
index 2e2c6ae77..f76653231 100644
--- a/vp8/decoder/generic/dsystemdependent.c
+++ b/vp8/decoder/generic/dsystemdependent.c
@@ -10,8 +10,8 @@
#include "vpx_ports/config.h"
-#include "dequantize.h"
-#include "onyxd_int.h"
+#include "vp8/decoder/dequantize.h"
+#include "vp8/decoder/onyxd_int.h"
extern void vp8_arch_x86_decode_init(VP8D_COMP *pbi);
extern void vp8_arch_arm_decode_init(VP8D_COMP *pbi);
diff --git a/vp8/decoder/idct_blk.c b/vp8/decoder/idct_blk.c
index c98bd5bb8..df0192354 100644
--- a/vp8/decoder/idct_blk.c
+++ b/vp8/decoder/idct_blk.c
@@ -9,7 +9,7 @@
*/
#include "vpx_ports/config.h"
-#include "idct.h"
+#include "vp8/common/idct.h"
#include "dequantize.h"
void vp8_dequant_dc_idct_add_c(short *input, short *dq, unsigned char *pred,
diff --git a/vp8/decoder/onyxd_if.c b/vp8/decoder/onyxd_if.c
index 9fec3e051..0fc49ac79 100644
--- a/vp8/decoder/onyxd_if.c
+++ b/vp8/decoder/onyxd_if.c
@@ -9,25 +9,25 @@
*/
-#include "onyxc_int.h"
+#include "vp8/common/onyxc_int.h"
#if CONFIG_POSTPROC
-#include "postproc.h"
+#include "vp8/common/postproc.h"
#endif
-#include "onyxd.h"
+#include "vp8/common/onyxd.h"
#include "onyxd_int.h"
#include "vpx_mem/vpx_mem.h"
-#include "alloccommon.h"
+#include "vp8/common/alloccommon.h"
#include "vpx_scale/yv12extend.h"
-#include "loopfilter.h"
-#include "swapyv12buffer.h"
-#include "g_common.h"
-#include "threading.h"
+#include "vp8/common/loopfilter.h"
+#include "vp8/common/swapyv12buffer.h"
+#include "vp8/common/g_common.h"
+#include "vp8/common/threading.h"
#include "decoderthreading.h"
#include <stdio.h>
-#include "quant_common.h"
+#include "vp8/common/quant_common.h"
#include "vpx_scale/vpxscale.h"
-#include "systemdependent.h"
+#include "vp8/common/systemdependent.h"
#include "vpx_ports/vpx_timer.h"
#include "detokenize.h"
#if ARCH_ARM
diff --git a/vp8/decoder/onyxd_int.h b/vp8/decoder/onyxd_int.h
index 47b4fe0a5..70cb0fe3c 100644
--- a/vp8/decoder/onyxd_int.h
+++ b/vp8/decoder/onyxd_int.h
@@ -12,10 +12,10 @@
#ifndef __INC_VP8D_INT_H
#define __INC_VP8D_INT_H
#include "vpx_ports/config.h"
-#include "onyxd.h"
+#include "vp8/common/onyxd.h"
#include "treereader.h"
-#include "onyxc_int.h"
-#include "threading.h"
+#include "vp8/common/onyxc_int.h"
+#include "vp8/common/threading.h"
#include "dequantize.h"
typedef struct
diff --git a/vp8/decoder/reconintra_mt.c b/vp8/decoder/reconintra_mt.c
index 854aba35a..b9d2b3703 100644
--- a/vp8/decoder/reconintra_mt.c
+++ b/vp8/decoder/reconintra_mt.c
@@ -10,8 +10,8 @@
#include "vpx_ports/config.h"
-#include "recon.h"
-#include "reconintra.h"
+#include "vp8/common/recon.h"
+#include "vp8/common/reconintra.h"
#include "vpx_mem/vpx_mem.h"
#include "onyxd_int.h"
diff --git a/vp8/decoder/threading.c b/vp8/decoder/threading.c
index 2388909a1..7fc901054 100644
--- a/vp8/decoder/threading.c
+++ b/vp8/decoder/threading.c
@@ -17,13 +17,13 @@
#endif
#include "onyxd_int.h"
#include "vpx_mem/vpx_mem.h"
-#include "threading.h"
+#include "vp8/common/threading.h"
-#include "loopfilter.h"
-#include "extend.h"
+#include "vp8/common/loopfilter.h"
+#include "vp8/common/extend.h"
#include "vpx_ports/vpx_timer.h"
#include "detokenize.h"
-#include "reconinter.h"
+#include "vp8/common/reconinter.h"
#include "reconintra_mt.h"
extern void mb_init_dequantizer(VP8D_COMP *pbi, MACROBLOCKD *xd);
diff --git a/vp8/decoder/treereader.h b/vp8/decoder/treereader.h
index 277842896..b50a4d2ff 100644
--- a/vp8/decoder/treereader.h
+++ b/vp8/decoder/treereader.h
@@ -12,7 +12,7 @@
#ifndef tree_reader_h
#define tree_reader_h 1
-#include "treecoder.h"
+#include "vp8/common/treecoder.h"
#include "dboolhuff.h"
diff --git a/vp8/decoder/x86/idct_blk_mmx.c b/vp8/decoder/x86/idct_blk_mmx.c
index 78c91d3d2..8f1a363cd 100644
--- a/vp8/decoder/x86/idct_blk_mmx.c
+++ b/vp8/decoder/x86/idct_blk_mmx.c
@@ -9,8 +9,8 @@
*/
#include "vpx_ports/config.h"
-#include "idct.h"
-#include "dequantize.h"
+#include "vp8/common/idct.h"
+#include "vp8/decoder/dequantize.h"
void vp8_dequant_dc_idct_add_y_block_mmx
(short *q, short *dq, unsigned char *pre,
diff --git a/vp8/decoder/x86/idct_blk_sse2.c b/vp8/decoder/x86/idct_blk_sse2.c
index 0273d6ed2..4c88db474 100644
--- a/vp8/decoder/x86/idct_blk_sse2.c
+++ b/vp8/decoder/x86/idct_blk_sse2.c
@@ -9,8 +9,8 @@
*/
#include "vpx_ports/config.h"
-#include "idct.h"
-#include "dequantize.h"
+#include "vp8/common/idct.h"
+#include "vp8/decoder/dequantize.h"
void idct_dequant_dc_0_2x_sse2
(short *q, short *dq, unsigned char *pre,
diff --git a/vp8/decoder/x86/onyxdxv.c b/vp8/decoder/x86/onyxdxv.c
index 50293c792..ed38e2b9a 100644
--- a/vp8/decoder/x86/onyxdxv.c
+++ b/vp8/decoder/x86/onyxdxv.c
@@ -21,19 +21,19 @@
* Header Files
****************************************************************************/
#include <math.h> // For Abs()
-#include "pragmas.h"
+#include "vp8/common/pragmas.h"
#include "vpxdxv.h"
#include "vpxdxv_plugin.h"
-#include "onyxd_int.h"
-#include "onyx.h"
-#include "codec_common_interface.h"
+#include "vp8/decoder/onyxd_int.h"
+#include "vp8/common/onyx.h"
+#include "vp8/common/codec_common_interface.h"
#include "vpx_scale/vpxscale.h"
#include "vpx_mem/vpx_mem.h"
-#include "postproc.h"
-#include "vpxblit.h"
-#include "g_common.h"
+#include "vp8/common/postproc.h"
+#include "vp8/common/vpxblit.h"
+#include "vp8/common/g_common.h"
#include "vpx_scale/yv12extend.h"
#include <limits.h>
diff --git a/vp8/decoder/x86/x86_dsystemdependent.c b/vp8/decoder/x86/x86_dsystemdependent.c
index 47e346dd9..3f1b7d5ad 100644
--- a/vp8/decoder/x86/x86_dsystemdependent.c
+++ b/vp8/decoder/x86/x86_dsystemdependent.c
@@ -11,7 +11,7 @@
#include "vpx_ports/config.h"
#include "vpx_ports/x86.h"
-#include "onyxd_int.h"
+#include "vp8/decoder/onyxd_int.h"
#if HAVE_MMX
diff --git a/vp8/encoder/arm/arm_csystemdependent.c b/vp8/encoder/arm/arm_csystemdependent.c
index cec35d548..5852afddb 100644
--- a/vp8/encoder/arm/arm_csystemdependent.c
+++ b/vp8/encoder/arm/arm_csystemdependent.c
@@ -11,8 +11,8 @@
#include "vpx_ports/config.h"
#include "vpx_ports/arm.h"
-#include "variance.h"
-#include "onyx_int.h"
+#include "vp8/encoder/variance.h"
+#include "vp8/encoder/onyx_int.h"
extern void (*vp8_yv12_copy_partial_frame_ptr)(YV12_BUFFER_CONFIG *src_ybc, YV12_BUFFER_CONFIG *dst_ybc, int Fraction);
extern void vp8_yv12_copy_partial_frame(YV12_BUFFER_CONFIG *src_ybc, YV12_BUFFER_CONFIG *dst_ybc, int Fraction);
diff --git a/vp8/encoder/arm/boolhuff_arm.c b/vp8/encoder/arm/boolhuff_arm.c
index fe8e70c16..9089663ca 100644
--- a/vp8/encoder/arm/boolhuff_arm.c
+++ b/vp8/encoder/arm/boolhuff_arm.c
@@ -9,8 +9,8 @@
*/
-#include "boolhuff.h"
-#include "blockd.h"
+#include "vp8/encoder/boolhuff.h"
+#include "vp8/common/blockd.h"
const unsigned int vp8_prob_cost[256] =
{
diff --git a/vp8/encoder/arm/encodemb_arm.c b/vp8/encoder/arm/encodemb_arm.c
index cc9e014b2..88ad3fcff 100644
--- a/vp8/encoder/arm/encodemb_arm.c
+++ b/vp8/encoder/arm/encodemb_arm.c
@@ -9,13 +9,13 @@
*/
-#include "encodemb.h"
-#include "reconinter.h"
-#include "quantize.h"
-#include "invtrans.h"
-#include "recon.h"
-#include "reconintra.h"
-#include "dct.h"
+#include "vp8/encoder/encodemb.h"
+#include "vp8/common/reconinter.h"
+#include "vp8/encoder/quantize.h"
+#include "vp8/common/invtrans.h"
+#include "vp8/common/recon.h"
+#include "vp8/common/reconintra.h"
+#include "vp8/encoder/dct.h"
#include "vpx_mem/vpx_mem.h"
extern void vp8_subtract_b_neon_func(short *diff, unsigned char *src, unsigned char *pred, int stride, int pitch);
diff --git a/vp8/encoder/arm/picklpf_arm.c b/vp8/encoder/arm/picklpf_arm.c
index b2d8f2b2c..3fb370c3d 100644
--- a/vp8/encoder/arm/picklpf_arm.c
+++ b/vp8/encoder/arm/picklpf_arm.c
@@ -9,13 +9,13 @@
*/
-#include "onyxc_int.h"
-#include "onyx_int.h"
-#include "quantize.h"
+#include "vp8/common/onyxc_int.h"
+#include "vp8/encoder/onyx_int.h"
+#include "vp8/encoder/quantize.h"
#include "vpx_mem/vpx_mem.h"
#include "vpx_scale/yv12extend.h"
#include "vpx_scale/vpxscale.h"
-#include "alloccommon.h"
+#include "vp8/common/alloccommon.h"
extern void vp8_memcpy_neon(unsigned char *dst_ptr, unsigned char *src_ptr, int sz);
diff --git a/vp8/encoder/arm/quantize_arm.c b/vp8/encoder/arm/quantize_arm.c
index 225feaca6..75ec205cc 100644
--- a/vp8/encoder/arm/quantize_arm.c
+++ b/vp8/encoder/arm/quantize_arm.c
@@ -12,9 +12,9 @@
#include <math.h>
#include "vpx_mem/vpx_mem.h"
-#include "quantize.h"
-#include "entropy.h"
-#include "predictdc.h"
+#include "vp8/encoder/quantize.h"
+#include "vp8/common/entropy.h"
+#include "vp8/common/predictdc.h"
DECLARE_ALIGNED(16, const short, vp8_rvsplus1_default_zig_zag1d[16]) =
{
diff --git a/vp8/encoder/arm/variance_arm.c b/vp8/encoder/arm/variance_arm.c
index 9737bef46..1cf9fd8f0 100644
--- a/vp8/encoder/arm/variance_arm.c
+++ b/vp8/encoder/arm/variance_arm.c
@@ -9,9 +9,9 @@
*/
#include "vpx_config.h"
-#include "variance.h"
-#include "filter.h"
-#include "arm/bilinearfilter_arm.h"
+#include "vp8/encoder/variance.h"
+#include "vp8/common/filter.h"
+#include "vp8/common/arm/bilinearfilter_arm.h"
#if HAVE_ARMV6
diff --git a/vp8/encoder/bitstream.c b/vp8/encoder/bitstream.c
index 419646c30..cb0846046 100644
--- a/vp8/encoder/bitstream.c
+++ b/vp8/encoder/bitstream.c
@@ -9,15 +9,15 @@
*/
-#include "header.h"
+#include "vp8/common/header.h"
#include "encodemv.h"
-#include "entropymode.h"
-#include "findnearmv.h"
+#include "vp8/common/entropymode.h"
+#include "vp8/common/findnearmv.h"
#include "mcomp.h"
-#include "systemdependent.h"
+#include "vp8/common/systemdependent.h"
#include <assert.h>
#include <stdio.h>
-#include "pragmas.h"
+#include "vp8/common/pragmas.h"
#include "vpx_mem/vpx_mem.h"
#include "bitstream.h"
#if CONFIG_SEGMENTATION
@@ -60,16 +60,6 @@ extern unsigned int active_section;
int count_mb_seg[4] = { 0, 0, 0, 0 };
#endif
-#if CONFIG_BIG_ENDIAN
-# define make_endian_16(a) \
- (((unsigned int)(a & 0xff)) << 8) | (((unsigned int)(a & 0xff00)) >> 8)
-# define make_endian_32(a) \
- (((unsigned int)(a & 0xff)) << 24) | (((unsigned int)(a & 0xff00)) << 8) | \
- (((unsigned int)(a & 0xff0000)) >> 8) | (((unsigned int)(a & 0xff000000)) >> 24)
-#else
-# define make_endian_16(a) a
-# define make_endian_32(a) a
-#endif
static void update_mode(
vp8_writer *const w,
@@ -1467,13 +1457,20 @@ void vp8_pack_bitstream(VP8_COMP *cpi, unsigned char *dest, unsigned long *size)
// every keyframe send startcode, width, height, scale factor, clamp and color type
if (oh.type == KEY_FRAME)
{
+ int v;
+
// Start / synch code
cx_data[0] = 0x9D;
cx_data[1] = 0x01;
cx_data[2] = 0x2a;
- *((unsigned short *)(cx_data + 3)) = make_endian_16((pc->horiz_scale << 14) | pc->Width);
- *((unsigned short *)(cx_data + 5)) = make_endian_16((pc->vert_scale << 14) | pc->Height);
+ v = (pc->horiz_scale << 14) | pc->Width;
+ cx_data[3] = v;
+ cx_data[4] = v >> 8;
+
+ v = (pc->vert_scale << 14) | pc->Height;
+ cx_data[5] = v;
+ cx_data[6] = v >> 8;
extra_bytes_packed = 7;
cx_data += extra_bytes_packed ;
@@ -1748,19 +1745,16 @@ void vp8_pack_bitstream(VP8_COMP *cpi, unsigned char *dest, unsigned long *size)
*size = cpi->bc2.pos + cpi->bc.pos + VP8_HEADER_SIZE + extra_bytes_packed;
}
-#if CONFIG_BIG_ENDIAN
{
int v = (oh.first_partition_length_in_bytes << 5) |
(oh.show_frame << 4) |
(oh.version << 1) |
oh.type;
- v = make_endian_32(v);
- vpx_memcpy(dest, &v, 3);
+ dest[0] = v;
+ dest[1] = v >> 8;
+ dest[2] = v >> 16;
}
-#else
- vpx_memcpy(dest, &oh, 3);
-#endif
}
#ifdef ENTROPY_STATS
diff --git a/vp8/encoder/block.h b/vp8/encoder/block.h
index 3ad40efc0..2fd67822b 100644
--- a/vp8/encoder/block.h
+++ b/vp8/encoder/block.h
@@ -12,10 +12,10 @@
#ifndef __INC_BLOCK_H
#define __INC_BLOCK_H
-#include "onyx.h"
-#include "blockd.h"
-#include "entropymv.h"
-#include "entropy.h"
+#include "vp8/common/onyx.h"
+#include "vp8/common/blockd.h"
+#include "vp8/common/entropymv.h"
+#include "vp8/common/entropy.h"
#include "vpx_ports/mem.h"
// motion search site
diff --git a/vp8/encoder/boolhuff.c b/vp8/encoder/boolhuff.c
index 82006b196..788d2b05f 100644
--- a/vp8/encoder/boolhuff.c
+++ b/vp8/encoder/boolhuff.c
@@ -10,7 +10,7 @@
#include "boolhuff.h"
-#include "blockd.h"
+#include "vp8/common/blockd.h"
diff --git a/vp8/encoder/encodeframe.c b/vp8/encoder/encodeframe.c
index 2950bb45f..5dbe1975f 100644
--- a/vp8/encoder/encodeframe.c
+++ b/vp8/encoder/encodeframe.c
@@ -12,22 +12,22 @@
#include "vpx_ports/config.h"
#include "encodemb.h"
#include "encodemv.h"
-#include "common.h"
+#include "vp8/common/common.h"
#include "onyx_int.h"
-#include "extend.h"
-#include "entropymode.h"
-#include "quant_common.h"
+#include "vp8/common/extend.h"
+#include "vp8/common/entropymode.h"
+#include "vp8/common/quant_common.h"
#include "segmentation.h"
-#include "setupintrarecon.h"
+#include "vp8/common/setupintrarecon.h"
#include "encodeintra.h"
-#include "reconinter.h"
+#include "vp8/common/reconinter.h"
#include "rdopt.h"
#include "pickinter.h"
-#include "findnearmv.h"
-#include "reconintra.h"
+#include "vp8/common/findnearmv.h"
+#include "vp8/common/reconintra.h"
#include <stdio.h>
#include <limits.h>
-#include "subpixel.h"
+#include "vp8/common/subpixel.h"
#include "vpx_ports/vpx_timer.h"
diff --git a/vp8/encoder/encodeintra.c b/vp8/encoder/encodeintra.c
index e016fa35b..cd66016cc 100644
--- a/vp8/encoder/encodeintra.c
+++ b/vp8/encoder/encodeintra.c
@@ -10,15 +10,15 @@
#include "vpx_ports/config.h"
-#include "idct.h"
+#include "vp8/common/idct.h"
#include "quantize.h"
-#include "reconintra.h"
-#include "reconintra4x4.h"
+#include "vp8/common/reconintra.h"
+#include "vp8/common/reconintra4x4.h"
#include "encodemb.h"
-#include "invtrans.h"
-#include "recon.h"
+#include "vp8/common/invtrans.h"
+#include "vp8/common/recon.h"
#include "dct.h"
-#include "g_common.h"
+#include "vp8/common/g_common.h"
#include "encodeintra.h"
#define intra4x4ibias_rate 128
diff --git a/vp8/encoder/encodemb.c b/vp8/encoder/encodemb.c
index aa2beacde..f75b25858 100644
--- a/vp8/encoder/encodemb.c
+++ b/vp8/encoder/encodemb.c
@@ -11,12 +11,12 @@
#include "vpx_ports/config.h"
#include "encodemb.h"
-#include "reconinter.h"
+#include "vp8/common/reconinter.h"
#include "quantize.h"
#include "tokenize.h"
-#include "invtrans.h"
-#include "recon.h"
-#include "reconintra.h"
+#include "vp8/common/invtrans.h"
+#include "vp8/common/recon.h"
+#include "vp8/common/reconintra.h"
#include "dct.h"
#include "vpx_mem/vpx_mem.h"
diff --git a/vp8/encoder/encodemv.c b/vp8/encoder/encodemv.c
index 4cb4c6e55..6b1e6f965 100644
--- a/vp8/encoder/encodemv.c
+++ b/vp8/encoder/encodemv.c
@@ -9,10 +9,10 @@
*/
-#include "common.h"
+#include "vp8/common/common.h"
#include "encodemv.h"
-#include "entropymode.h"
-#include "systemdependent.h"
+#include "vp8/common/entropymode.h"
+#include "vp8/common/systemdependent.h"
#include <math.h>
diff --git a/vp8/encoder/ethreading.c b/vp8/encoder/ethreading.c
index 967d2a6a9..d7a2089d2 100644
--- a/vp8/encoder/ethreading.c
+++ b/vp8/encoder/ethreading.c
@@ -9,9 +9,9 @@
*/
#include "onyx_int.h"
-#include "threading.h"
-#include "common.h"
-#include "extend.h"
+#include "vp8/common/threading.h"
+#include "vp8/common/common.h"
+#include "vp8/common/extend.h"
#if CONFIG_MULTITHREAD
diff --git a/vp8/encoder/firstpass.c b/vp8/encoder/firstpass.c
index a27f9ce6c..eec239afb 100644
--- a/vp8/encoder/firstpass.c
+++ b/vp8/encoder/firstpass.c
@@ -14,18 +14,18 @@
#include "onyx_int.h"
#include "variance.h"
#include "encodeintra.h"
-#include "setupintrarecon.h"
+#include "vp8/common/setupintrarecon.h"
#include "mcomp.h"
#include "vpx_scale/vpxscale.h"
#include "encodemb.h"
-#include "extend.h"
-#include "systemdependent.h"
+#include "vp8/common/extend.h"
+#include "vp8/common/systemdependent.h"
#include "vpx_scale/yv12extend.h"
#include "vpx_mem/vpx_mem.h"
-#include "swapyv12buffer.h"
+#include "vp8/common/swapyv12buffer.h"
#include <stdio.h>
#include "rdopt.h"
-#include "quant_common.h"
+#include "vp8/common/quant_common.h"
#include "encodemv.h"
//#define OUTPUT_FPF 1
diff --git a/vp8/encoder/generic/csystemdependent.c b/vp8/encoder/generic/csystemdependent.c
index b6de95b8d..f067b3937 100644
--- a/vp8/encoder/generic/csystemdependent.c
+++ b/vp8/encoder/generic/csystemdependent.c
@@ -10,8 +10,8 @@
#include "vpx_ports/config.h"
-#include "variance.h"
-#include "onyx_int.h"
+#include "vp8/encoder/variance.h"
+#include "vp8/encoder/onyx_int.h"
void vp8_arch_x86_encoder_init(VP8_COMP *cpi);
diff --git a/vp8/encoder/modecosts.c b/vp8/encoder/modecosts.c
index d23c97e6e..c636c482b 100644
--- a/vp8/encoder/modecosts.c
+++ b/vp8/encoder/modecosts.c
@@ -9,10 +9,10 @@
*/
-#include "blockd.h"
+#include "vp8/common/blockd.h"
#include "onyx_int.h"
#include "treewriter.h"
-#include "entropymode.h"
+#include "vp8/common/entropymode.h"
void vp8_init_mode_costs(VP8_COMP *c)
diff --git a/vp8/encoder/onyx_if.c b/vp8/encoder/onyx_if.c
index b0912941e..c53bb7dda 100644
--- a/vp8/encoder/onyx_if.c
+++ b/vp8/encoder/onyx_if.c
@@ -9,27 +9,27 @@
*/
-#include "onyxc_int.h"
+#include "vp8/common/onyxc_int.h"
#include "onyx_int.h"
-#include "systemdependent.h"
+#include "vp8/common/systemdependent.h"
#include "quantize.h"
-#include "alloccommon.h"
+#include "vp8/common/alloccommon.h"
#include "mcomp.h"
#include "firstpass.h"
#include "psnr.h"
#include "vpx_scale/vpxscale.h"
-#include "extend.h"
+#include "vp8/common/extend.h"
#include "ratectrl.h"
-#include "quant_common.h"
+#include "vp8/common/quant_common.h"
#include "segmentation.h"
-#include "g_common.h"
+#include "vp8/common/g_common.h"
#include "vpx_scale/yv12extend.h"
-#include "postproc.h"
+#include "vp8/common/postproc.h"
#include "vpx_mem/vpx_mem.h"
-#include "swapyv12buffer.h"
-#include "threading.h"
+#include "vp8/common/swapyv12buffer.h"
+#include "vp8/common/threading.h"
#include "vpx_ports/vpx_timer.h"
-#include "vpxerrors.h"
+#include "vp8/common/vpxerrors.h"
#include "temporal_filter.h"
#if ARCH_ARM
#include "vpx_ports/arm.h"
diff --git a/vp8/encoder/onyx_int.h b/vp8/encoder/onyx_int.h
index 881594c29..0d33b42a6 100644
--- a/vp8/encoder/onyx_int.h
+++ b/vp8/encoder/onyx_int.h
@@ -14,21 +14,21 @@
#include <stdio.h>
#include "vpx_ports/config.h"
-#include "onyx.h"
+#include "vp8/common/onyx.h"
#include "treewriter.h"
#include "tokenize.h"
-#include "onyxc_int.h"
+#include "vp8/common/onyxc_int.h"
#include "variance.h"
#include "dct.h"
#include "encodemb.h"
#include "quantize.h"
-#include "entropy.h"
-#include "threading.h"
+#include "vp8/common/entropy.h"
+#include "vp8/common/threading.h"
#include "vpx_ports/mem.h"
#include "vpx/internal/vpx_codec_internal.h"
#include "mcomp.h"
#include "temporal_filter.h"
-#include "findnearmv.h"
+#include "vp8/common/findnearmv.h"
//#define SPEEDSTATS 1
#define MIN_GF_INTERVAL 4
diff --git a/vp8/encoder/parms.cpp b/vp8/encoder/parms.cpp
index 6cc450121..2a39b2ca3 100644
--- a/vp8/encoder/parms.cpp
+++ b/vp8/encoder/parms.cpp
@@ -16,7 +16,7 @@
#include <fstream>
extern "C"
{
- #include "onyx.h"
+ #include "vp8/common/onyx.h"
}
diff --git a/vp8/encoder/pickinter.c b/vp8/encoder/pickinter.c
index 1a58257a3..6ab85adbc 100644
--- a/vp8/encoder/pickinter.c
+++ b/vp8/encoder/pickinter.c
@@ -14,14 +14,14 @@
#include "onyx_int.h"
#include "modecosts.h"
#include "encodeintra.h"
-#include "entropymode.h"
+#include "vp8/common/entropymode.h"
#include "pickinter.h"
-#include "findnearmv.h"
+#include "vp8/common/findnearmv.h"
#include "encodemb.h"
-#include "reconinter.h"
-#include "reconintra.h"
-#include "reconintra4x4.h"
-#include "g_common.h"
+#include "vp8/common/reconinter.h"
+#include "vp8/common/reconintra.h"
+#include "vp8/common/reconintra4x4.h"
+#include "vp8/common/g_common.h"
#include "variance.h"
#include "mcomp.h"
#include "rdopt.h"
diff --git a/vp8/encoder/pickinter.h b/vp8/encoder/pickinter.h
index b80e4c86f..af060d701 100644
--- a/vp8/encoder/pickinter.h
+++ b/vp8/encoder/pickinter.h
@@ -12,7 +12,7 @@
#ifndef __INC_PICKINTER_H
#define __INC_PICKINTER_H
#include "vpx_ports/config.h"
-#include "onyxc_int.h"
+#include "vp8/common/onyxc_int.h"
#define RD_ESTIMATE(RM,DM,R,D) ( ((128+(R)*(RM)) >> 8) + (DM)*(D) )
extern int vp8_pick_intra4x4mby_modes(const VP8_ENCODER_RTCD *, MACROBLOCK *mb, int *Rate, int *Distortion);
diff --git a/vp8/encoder/picklpf.c b/vp8/encoder/picklpf.c
index 78aa866dd..d294af6c0 100644
--- a/vp8/encoder/picklpf.c
+++ b/vp8/encoder/picklpf.c
@@ -9,13 +9,13 @@
*/
-#include "onyxc_int.h"
+#include "vp8/common/onyxc_int.h"
#include "onyx_int.h"
#include "quantize.h"
#include "vpx_mem/vpx_mem.h"
#include "vpx_scale/yv12extend.h"
#include "vpx_scale/vpxscale.h"
-#include "alloccommon.h"
+#include "vp8/common/alloccommon.h"
#if ARCH_ARM
#include "vpx_ports/arm.h"
#endif
diff --git a/vp8/encoder/ppc/csystemdependent.c b/vp8/encoder/ppc/csystemdependent.c
index 588656b97..8dfd2a543 100644
--- a/vp8/encoder/ppc/csystemdependent.c
+++ b/vp8/encoder/ppc/csystemdependent.c
@@ -9,8 +9,8 @@
*/
-#include "variance.h"
-#include "onyx_int.h"
+#include "vp8/encoder/variance.h"
+#include "vp8/encoder/onyx_int.h"
SADFunction *vp8_sad16x16;
SADFunction *vp8_sad16x8;
diff --git a/vp8/encoder/psnr.c b/vp8/encoder/psnr.c
index ff0222e2d..abd2ed47c 100644
--- a/vp8/encoder/psnr.c
+++ b/vp8/encoder/psnr.c
@@ -11,7 +11,7 @@
#include "vpx_scale/yv12config.h"
#include "math.h"
-#include "systemdependent.h" /* for vp8_clear_system_state() */
+#include "vp8/common/systemdependent.h" /* for vp8_clear_system_state() */
#define MAX_PSNR 100
diff --git a/vp8/encoder/quantize.c b/vp8/encoder/quantize.c
index 4a2329fc1..02b9d7bd9 100644
--- a/vp8/encoder/quantize.c
+++ b/vp8/encoder/quantize.c
@@ -13,8 +13,8 @@
#include "vpx_mem/vpx_mem.h"
#include "quantize.h"
-#include "entropy.h"
-#include "predictdc.h"
+#include "vp8/common/entropy.h"
+#include "vp8/common/predictdc.h"
#define EXACT_QUANT
diff --git a/vp8/encoder/ratectrl.c b/vp8/encoder/ratectrl.c
index c38cf4c74..0a5f3bff1 100644
--- a/vp8/encoder/ratectrl.c
+++ b/vp8/encoder/ratectrl.c
@@ -16,11 +16,11 @@
#include <assert.h>
#include "math.h"
-#include "common.h"
+#include "vp8/common/common.h"
#include "ratectrl.h"
-#include "entropymode.h"
+#include "vp8/common/entropymode.h"
#include "vpx_mem/vpx_mem.h"
-#include "systemdependent.h"
+#include "vp8/common/systemdependent.h"
#include "encodemv.h"
diff --git a/vp8/encoder/rdopt.c b/vp8/encoder/rdopt.c
index 2ecd5018b..cf5b5ccc6 100644
--- a/vp8/encoder/rdopt.c
+++ b/vp8/encoder/rdopt.c
@@ -13,28 +13,28 @@
#include <math.h>
#include <limits.h>
#include <assert.h>
-#include "pragmas.h"
+#include "vp8/common/pragmas.h"
#include "tokenize.h"
#include "treewriter.h"
#include "onyx_int.h"
#include "modecosts.h"
#include "encodeintra.h"
-#include "entropymode.h"
-#include "reconinter.h"
-#include "reconintra.h"
-#include "reconintra4x4.h"
-#include "findnearmv.h"
+#include "vp8/common/entropymode.h"
+#include "vp8/common/reconinter.h"
+#include "vp8/common/reconintra.h"
+#include "vp8/common/reconintra4x4.h"
+#include "vp8/common/findnearmv.h"
#include "encodemb.h"
#include "quantize.h"
-#include "idct.h"
-#include "g_common.h"
+#include "vp8/common/idct.h"
+#include "vp8/common/g_common.h"
#include "variance.h"
#include "mcomp.h"
#include "vpx_mem/vpx_mem.h"
#include "dct.h"
-#include "systemdependent.h"
+#include "vp8/common/systemdependent.h"
#if CONFIG_RUNTIME_CPU_DETECT
#define IF_RTCD(x) (x)
diff --git a/vp8/encoder/segmentation.h b/vp8/encoder/segmentation.h
index 216e194c2..12815b087 100644
--- a/vp8/encoder/segmentation.h
+++ b/vp8/encoder/segmentation.h
@@ -10,7 +10,7 @@
#include "string.h"
-#include "blockd.h"
+#include "vp8/common/blockd.h"
#include "onyx_int.h"
extern void vp8_update_gf_useage_maps(VP8_COMP *cpi, VP8_COMMON *cm, MACROBLOCK *x);
diff --git a/vp8/encoder/temporal_filter.c b/vp8/encoder/temporal_filter.c
index e4c3db1b8..9ff8887e5 100644
--- a/vp8/encoder/temporal_filter.c
+++ b/vp8/encoder/temporal_filter.c
@@ -9,27 +9,27 @@
*/
-#include "onyxc_int.h"
+#include "vp8/common/onyxc_int.h"
#include "onyx_int.h"
-#include "systemdependent.h"
+#include "vp8/common/systemdependent.h"
#include "quantize.h"
-#include "alloccommon.h"
+#include "vp8/common/alloccommon.h"
#include "mcomp.h"
#include "firstpass.h"
#include "psnr.h"
#include "vpx_scale/vpxscale.h"
-#include "extend.h"
+#include "vp8/common/extend.h"
#include "ratectrl.h"
-#include "quant_common.h"
+#include "vp8/common/quant_common.h"
#include "segmentation.h"
-#include "g_common.h"
+#include "vp8/common/g_common.h"
#include "vpx_scale/yv12extend.h"
-#include "postproc.h"
+#include "vp8/common/postproc.h"
#include "vpx_mem/vpx_mem.h"
-#include "swapyv12buffer.h"
-#include "threading.h"
+#include "vp8/common/swapyv12buffer.h"
+#include "vp8/common/threading.h"
#include "vpx_ports/vpx_timer.h"
-#include "vpxerrors.h"
+#include "vp8/common/vpxerrors.h"
#include <math.h>
#include <limits.h>
diff --git a/vp8/encoder/tokenize.h b/vp8/encoder/tokenize.h
index ed5eb0ce9..d87c1a3e7 100644
--- a/vp8/encoder/tokenize.h
+++ b/vp8/encoder/tokenize.h
@@ -12,7 +12,7 @@
#ifndef tokenize_h
#define tokenize_h
-#include "entropy.h"
+#include "vp8/common/entropy.h"
#include "block.h"
void vp8_tokenize_initialize();
diff --git a/vp8/encoder/treewriter.h b/vp8/encoder/treewriter.h
index 88096d875..c28a0fa37 100644
--- a/vp8/encoder/treewriter.h
+++ b/vp8/encoder/treewriter.h
@@ -15,7 +15,7 @@
/* Trees map alphabets into huffman-like codes suitable for an arithmetic
bit coder. Timothy S Murphy 11 October 2004 */
-#include "treecoder.h"
+#include "vp8/common/treecoder.h"
#include "boolhuff.h" /* for now */
diff --git a/vp8/encoder/x86/variance_mmx.c b/vp8/encoder/x86/variance_mmx.c
index 2df73a635..6eed98e07 100644
--- a/vp8/encoder/x86/variance_mmx.c
+++ b/vp8/encoder/x86/variance_mmx.c
@@ -9,8 +9,8 @@
*/
-#include "variance.h"
-#include "pragmas.h"
+#include "vp8/encoder/variance.h"
+#include "vp8/common/pragmas.h"
#include "vpx_ports/mem.h"
extern void filter_block1d_h6_mmx
diff --git a/vp8/encoder/x86/variance_sse2.c b/vp8/encoder/x86/variance_sse2.c
index 6f79f0d23..7cf6a6308 100644
--- a/vp8/encoder/x86/variance_sse2.c
+++ b/vp8/encoder/x86/variance_sse2.c
@@ -9,8 +9,8 @@
*/
-#include "variance.h"
-#include "pragmas.h"
+#include "vp8/encoder/variance.h"
+#include "vp8/common/pragmas.h"
#include "vpx_ports/mem.h"
extern void filter_block1d_h6_mmx(const unsigned char *src_ptr, unsigned short *output_ptr, unsigned int src_pixels_per_line, unsigned int pixel_step, unsigned int output_height, unsigned int output_width, short *vp7_filter);
diff --git a/vp8/encoder/x86/x86_csystemdependent.c b/vp8/encoder/x86/x86_csystemdependent.c
index 31438f916..4e3ce070d 100644
--- a/vp8/encoder/x86/x86_csystemdependent.c
+++ b/vp8/encoder/x86/x86_csystemdependent.c
@@ -11,8 +11,8 @@
#include "vpx_ports/config.h"
#include "vpx_ports/x86.h"
-#include "variance.h"
-#include "onyx_int.h"
+#include "vp8/encoder/variance.h"
+#include "vp8/encoder/onyx_int.h"
#if HAVE_MMX
diff --git a/vp8/vp8_common.mk b/vp8/vp8_common.mk
index e98ee6b5a..6a317c28d 100644
--- a/vp8/vp8_common.mk
+++ b/vp8/vp8_common.mk
@@ -8,24 +8,13 @@
## be found in the AUTHORS file in the root of the source tree.
##
-
-#add this file to the installed sources list
VP8_COMMON_SRCS-yes += vp8_common.mk
-
-CFLAGS+=-I$(SRC_PATH_BARE)/$(VP8_PREFIX)common
VP8_COMMON_SRCS-yes += common/type_aliases.h
VP8_COMMON_SRCS-yes += common/pragmas.h
-
-CFLAGS+=-I$(SRC_PATH_BARE)/$(VP8_PREFIX)common
VP8_COMMON_SRCS-yes += common/vpxerrors.h
-
-CFLAGS+=-I$(SRC_PATH_BARE)/$(VP8_PREFIX)common
VP8_COMMON_SRCS-yes += common/ppflags.h
VP8_COMMON_SRCS-yes += common/onyx.h
VP8_COMMON_SRCS-yes += common/onyxd.h
-
-CFLAGS+=-I$(SRC_PATH_BARE)/$(VP8_PREFIX)common
-
VP8_COMMON_SRCS-yes += common/alloccommon.c
VP8_COMMON_SRCS-yes += common/blockd.c
VP8_COMMON_SRCS-yes += common/coefupdateprobs.h
diff --git a/vp8/vp8_cx_iface.c b/vp8/vp8_cx_iface.c
index 7e8211ae4..eb568e18b 100644
--- a/vp8/vp8_cx_iface.c
+++ b/vp8/vp8_cx_iface.c
@@ -12,10 +12,10 @@
#include "vpx/vpx_codec.h"
#include "vpx/internal/vpx_codec_internal.h"
#include "vpx_version.h"
-#include "onyx_int.h"
+#include "vp8/encoder/onyx_int.h"
#include "vpx/vp8e.h"
#include "vp8/encoder/firstpass.h"
-#include "onyx.h"
+#include "vp8/common/onyx.h"
#include <stdlib.h>
#include <string.h>
diff --git a/vp8/vp8_dx_iface.c b/vp8/vp8_dx_iface.c
index 1b1cf3b94..23df75b03 100644
--- a/vp8/vp8_dx_iface.c
+++ b/vp8/vp8_dx_iface.c
@@ -15,24 +15,11 @@
#include "vpx/vp8dx.h"
#include "vpx/internal/vpx_codec_internal.h"
#include "vpx_version.h"
-#include "onyxd.h"
-#include "onyxd_int.h"
+#include "common/onyxd.h"
+#include "decoder/onyxd_int.h"
#define VP8_CAP_POSTPROC (CONFIG_POSTPROC ? VPX_CODEC_CAP_POSTPROC : 0)
-#if CONFIG_BIG_ENDIAN
-# define swap4(d)\
- ((d&0x000000ff)<<24) | \
- ((d&0x0000ff00)<<8) | \
- ((d&0x00ff0000)>>8) | \
- ((d&0xff000000)>>24)
-# define swap2(d)\
- ((d&0x000000ff)<<8) | \
- ((d&0x0000ff00)>>8)
-#else
-# define swap4(d) d
-# define swap2(d) d
-#endif
typedef vpx_codec_stream_info_t vp8_stream_info_t;
/* Structures for handling memory allocations */
@@ -283,8 +270,8 @@ static vpx_codec_err_t vp8_peek_si(const uint8_t *data,
if (c[0] != 0x9d || c[1] != 0x01 || c[2] != 0x2a)
res = VPX_CODEC_UNSUP_BITSTREAM;
- si->w = swap2(*(const unsigned short *)(c + 3)) & 0x3fff;
- si->h = swap2(*(const unsigned short *)(c + 5)) & 0x3fff;
+ si->w = (c[3] | (c[4] << 8)) & 0x3fff;
+ si->h = (c[5] | (c[6] << 8)) & 0x3fff;
/*printf("w=%d, h=%d\n", si->w, si->h);*/
if (!(si->h | si->w))
diff --git a/vp8/vp8cx.mk b/vp8/vp8cx.mk
index 1ec26e69e..a84188f0c 100644
--- a/vp8/vp8cx.mk
+++ b/vp8/vp8cx.mk
@@ -33,8 +33,6 @@ VP8_CX_SRCS-yes += vp8_cx_iface.c
#INCLUDES += common
#INCLUDES += encoder
-CFLAGS+=-I$(SRC_PATH_BARE)/$(VP8_PREFIX)encoder
-
VP8_CX_SRCS-yes += encoder/bitstream.c
VP8_CX_SRCS-yes += encoder/boolhuff.c
VP8_CX_SRCS-yes += encoder/dct.c
diff --git a/vp8/vp8dx.mk b/vp8/vp8dx.mk
index 62f6211f6..564967191 100644
--- a/vp8/vp8dx.mk
+++ b/vp8/vp8dx.mk
@@ -24,9 +24,6 @@ endif
VP8_DX_SRCS-yes += vp8_dx_iface.c
-CFLAGS+=-I$(SRC_PATH_BARE)/$(VP8_PREFIX)decoder
-
-
# common
#define ARM
#define DISABLE_THREAD