]> granicus.if.org Git - libvpx/commitdiff
vp9/encoder: add extern "C" to headers
authorJames Zern <jzern@google.com>
Sat, 18 Jan 2014 20:16:11 +0000 (12:16 -0800)
committerJames Zern <jzern@google.com>
Fri, 24 Jan 2014 00:21:24 +0000 (16:21 -0800)
Change-Id: I4f51ce859a97bf1b8fd2b37ac585b7c643232b69

28 files changed:
vp9/encoder/vp9_bitstream.h
vp9/encoder/vp9_block.h
vp9/encoder/vp9_dct.h
vp9/encoder/vp9_encodeframe.h
vp9/encoder/vp9_encodemb.h
vp9/encoder/vp9_encodemv.h
vp9/encoder/vp9_extend.h
vp9/encoder/vp9_firstpass.h
vp9/encoder/vp9_lookahead.h
vp9/encoder/vp9_mbgraph.h
vp9/encoder/vp9_mcomp.h
vp9/encoder/vp9_onyx_int.h
vp9/encoder/vp9_picklpf.h
vp9/encoder/vp9_pickmode.h
vp9/encoder/vp9_psnr.h
vp9/encoder/vp9_quantize.h
vp9/encoder/vp9_ratectrl.h
vp9/encoder/vp9_rdopt.h
vp9/encoder/vp9_segmentation.h
vp9/encoder/vp9_subexp.h
vp9/encoder/vp9_temporal_filter.h
vp9/encoder/vp9_tokenize.h
vp9/encoder/vp9_treewriter.h
vp9/encoder/vp9_vaq.h
vp9/encoder/vp9_variance.h
vp9/encoder/vp9_write_bit_buffer.h
vp9/encoder/vp9_writer.h
vp9/encoder/x86/vp9_mcomp_x86.h

index 52be50272f9b174ea5080ddb91a188121f34cd62..94bec8a439a4ae3c2d6288d6e5418ae363756d7d 100644 (file)
 #ifndef VP9_ENCODER_VP9_BITSTREAM_H_
 #define VP9_ENCODER_VP9_BITSTREAM_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 void vp9_update_skip_probs(VP9_COMMON *cm, vp9_writer *bc);
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_BITSTREAM_H_
index c1b95817fcbcdf2f0d8d8f7b69cbd7ad8d0b7045..29e68b1d71c33966634ff675f0bf7d721d11a72c 100644 (file)
 #include "vpx_ports/mem.h"
 #include "vp9/common/vp9_onyxc_int.h"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 // motion search site
 typedef struct {
   MV mv;
@@ -254,4 +258,8 @@ struct rdcost_block_args {
   const int16_t *scan, *nb;
 };
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_BLOCK_H_
index aaf976d93c5abfb00c94e8bbb953f7334841d58f..cf5f001a9d81bf3e4c3112751d872a9fe04b85d1 100644 (file)
 #ifndef VP9_ENCODER_VP9_DCT_H_
 #define VP9_ENCODER_VP9_DCT_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 void vp9_fht4x4(TX_TYPE tx_type, const int16_t *input, int16_t *output,
                 int stride);
 
@@ -21,4 +25,8 @@ void vp9_fht8x8(TX_TYPE tx_type, const int16_t *input, int16_t *output,
 void vp9_fht16x16(TX_TYPE tx_type, const int16_t *input, int16_t *output,
                   int stride);
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_DCT_H_
index 3e9f5381c06ae66b0cc61cb6bca8891a168965ab..f7d17c301fa59acc17bd4a0fc2587bb298b5b5fb 100644 (file)
 #ifndef VP9_ENCODER_VP9_ENCODEFRAME_H_
 #define VP9_ENCODER_VP9_ENCODEFRAME_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 struct macroblock;
 struct yv12_buffer_config;
 
@@ -19,4 +23,8 @@ void vp9_setup_src_planes(struct macroblock *x,
                           const struct yv12_buffer_config *src,
                           int mi_row, int mi_col);
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_ENCODEFRAME_H_
index 207d573a5f9c0bc9854aab79f1dbba349cf8eead..6a06f0ae430e6545df24fa13a26ac4962ab7f5b0 100644 (file)
 #include "vp9/encoder/vp9_onyx_int.h"
 #include "vp9/common/vp9_onyxc_int.h"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 struct optimize_ctx {
   ENTROPY_CONTEXT ta[MAX_MB_PLANE][16];
   ENTROPY_CONTEXT tl[MAX_MB_PLANE][16];
@@ -47,4 +51,8 @@ int vp9_encode_intra(MACROBLOCK *x, int use_16x16_pred);
 void vp9_setup_interp_filters(MACROBLOCKD *xd,
                               INTERPOLATION_TYPE mcomp_filter_type,
                               VP9_COMMON *cm);
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_ENCODEMB_H_
index 761278fd1a8910685d364dac75610bf899926fb5..c57b01db47f3a55e174119daaf4c0e3454389c8a 100644 (file)
 
 #include "vp9/encoder/vp9_onyx_int.h"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 void vp9_entropy_mv_init();
 
 void vp9_write_nmv_probs(VP9_COMMON *cm, int usehp, vp9_writer* const);
@@ -30,4 +34,8 @@ void vp9_build_nmv_cost_table(int *mvjoint,
 
 void vp9_update_mv_count(VP9_COMP *cpi, MACROBLOCK *x, int_mv best_ref_mv[2]);
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_ENCODEMV_H_
index 9b95ee43725e84b2740566eabd823e35c9f14a34..058fe09cf983d67870217d31f34d813ce1fe12b3 100644 (file)
 #include "vpx_scale/yv12config.h"
 #include "vpx/vpx_integer.h"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 
 void vp9_copy_and_extend_frame(const YV12_BUFFER_CONFIG *src,
                                YV12_BUFFER_CONFIG *dst);
@@ -22,4 +26,8 @@ void vp9_copy_and_extend_frame_with_rect(const YV12_BUFFER_CONFIG *src,
                                          YV12_BUFFER_CONFIG *dst,
                                          int srcy, int srcx,
                                          int srch, int srcw);
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_EXTEND_H_
index f89e4cb1c3ff1145bdc498cce77318df66095cf1..ca5b10080baa0b80b54e8c9e32f8775f3113a504 100644 (file)
 #define VP9_ENCODER_VP9_FIRSTPASS_H_
 #include "vp9/encoder/vp9_onyx_int.h"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 void vp9_init_first_pass(VP9_COMP *cpi);
 void vp9_first_pass(VP9_COMP *cpi);
 void vp9_end_first_pass(VP9_COMP *cpi);
@@ -25,4 +29,8 @@ void vp9_get_one_pass_params(VP9_COMP *cpi);
 void vp9_get_one_pass_cbr_params(VP9_COMP *cpi);
 void vp9_get_svc_params(VP9_COMP *cpi);
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_FIRSTPASS_H_
index c773f8fcc6d64cc39f197f88e4fc7b291b8f1e16..1c00c462d2485f3a5d9db2003b04f86b091b5360 100644 (file)
 #include "vpx_scale/yv12config.h"
 #include "vpx/vpx_integer.h"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #define MAX_LAG_BUFFERS 25
 
 struct lookahead_entry {
@@ -94,4 +98,8 @@ struct lookahead_entry *vp9_lookahead_peek(struct lookahead_ctx *ctx,
  */
 unsigned int vp9_lookahead_depth(struct lookahead_ctx *ctx);
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_LOOKAHEAD_H_
index c5bca4d01f53c8ad3b156e6437cdaf0f72fe6858..79dd2bc958d2d8a1f370e3d73dc33a8d34f4ca37 100644 (file)
 #ifndef VP9_ENCODER_VP9_MBGRAPH_H_
 #define VP9_ENCODER_VP9_MBGRAPH_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 void vp9_update_mbgraph_stats(VP9_COMP *cpi);
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_MBGRAPH_H_
index 74035842fe7e6c1dfd15ea74d304f6bfd3b94f24..5cd9fd1703b82beaf19212dc8c4880efa06340e7 100644 (file)
 #include "vp9/encoder/vp9_block.h"
 #include "vp9/encoder/vp9_variance.h"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 // The maximum number of steps in a step search given the largest
 // allowed initial step
 #define MAX_MVSEARCH_STEPS 11
@@ -129,4 +133,8 @@ int vp9_refining_search_8p_c(const MACROBLOCK *x,
                              int *mvjcost, int *mvcost[2],
                              const MV *center_mv, const uint8_t *second_pred,
                              int w, int h);
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_MCOMP_H_
index a665bf859d35d938b4ef1aff9b80d1bba0c8eafc..ede57ba05d6cc7534221a8ae4481110c6df7ae56 100644 (file)
 #include "vp9/encoder/vp9_mcomp.h"
 #include "vp9/encoder/vp9_lookahead.h"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #define DISABLE_RC_LONG_TERM_MEM 0
 // #define MODE_TEST_HIT_STATS
 
@@ -825,4 +829,8 @@ static int get_token_alloc(int mb_rows, int mb_cols) {
   return mb_rows * mb_cols * (48 * 16 + 4);
 }
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_ONYX_INT_H_
index 9de4cf849cc55e9d60fdb6139b0d559f17462d8d..f9cb14c2780e116e7c8e0a347f85b2f8a6d765c9 100644 (file)
 #ifndef VP9_ENCODER_VP9_PICKLPF_H_
 #define VP9_ENCODER_VP9_PICKLPF_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 struct yv12_buffer_config;
 struct VP9_COMP;
 
@@ -19,4 +23,8 @@ void vp9_set_alt_lf_level(struct VP9_COMP *cpi, int filt_val);
 
 void vp9_pick_filter_level(struct yv12_buffer_config *sd,
                            struct VP9_COMP *cpi, int partial);
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_PICKLPF_H_
index 32750fa69f2ed1e237425e49cd1dafdb20061a6e..82904ae8ac13cd9a023f68053f16868f0f8df93b 100644 (file)
@@ -8,8 +8,15 @@
  *  be found in the AUTHORS file in the root of the source tree.
  */
 
+#ifndef VP9_ENCODER_VP9_PICKMODE_H_
+#define VP9_ENCODER_VP9_PICKMODE_H_
+
 #include "vp9/encoder/vp9_onyx_int.h"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 int64_t vp9_pick_inter_mode(VP9_COMP *cpi, MACROBLOCK *x,
                             const struct TileInfo *const tile,
                             int mi_row, int mi_col,
@@ -17,3 +24,9 @@ int64_t vp9_pick_inter_mode(VP9_COMP *cpi, MACROBLOCK *x,
                             int64_t *returndistortion,
                             BLOCK_SIZE bsize,
                             PICK_MODE_CONTEXT *ctx);
+
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
+#endif  // VP9_ENCODER_VP9_PICKMODE_H_
index 15dd8366bd830c16eb28b7be47e95861752bf577..ffe00ed2c41313585882f830faafec6ea38884d3 100644 (file)
 #ifndef VP9_ENCODER_VP9_PSNR_H_
 #define VP9_ENCODER_VP9_PSNR_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 double vp9_mse2psnr(double samples, double peak, double mse);
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_PSNR_H_
index 41cfa5283639741ebec34f8d9cdf512bb53944ea..680cf4aec638c11a26784a4aeaff5d67d55bb098 100644 (file)
 
 #include "vp9/encoder/vp9_block.h"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 void vp9_regular_quantize_b_4x4(MACROBLOCK *x, int plane, int block,
                                 const int16_t *scan, const int16_t *iscan);
 
@@ -28,4 +32,8 @@ void vp9_mb_init_quantizer(struct VP9_COMP *cpi, MACROBLOCK *x);
 
 void vp9_init_quantizer(struct VP9_COMP *cpi);
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_QUANTIZE_H_
index 086755af8d008fe12a972d6478753dfe610f1546..65ddead119978179d8d3030ee5d1253631e0798a 100644 (file)
 
 #include "vp9/encoder/vp9_onyx_int.h"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #define FRAME_OVERHEAD_BITS 200
 
 void vp9_save_coding_context(VP9_COMP *cpi);
@@ -69,4 +73,8 @@ int vp9_drop_frame(VP9_COMP *cpi);
 // Update the buffer level.
 void vp9_update_buffer_level(VP9_COMP *cpi, int encoded_frame_size);
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_RATECTRL_H_
index 9ac1f5404490a7d2f8deeaf162f89c4578e9cc90..3d23ccae1dcfa2d901fde1ab606677fb928ef252 100644 (file)
 
 #include "vp9/encoder/vp9_onyx_int.h"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #define RDDIV_BITS          7
 
 #define RDCOST(RM, DM, R, D) \
@@ -80,4 +84,8 @@ void vp9_get_entropy_contexts(TX_SIZE tx_size,
     const ENTROPY_CONTEXT *above, const ENTROPY_CONTEXT *left,
     int num_4x4_w, int num_4x4_h);
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_RDOPT_H_
index 3c6eb7038e0e470f8b7d92243e37b79371b95224..8238892e23f3f540fccc431eaf6c789721ba390b 100644 (file)
 #include "vp9/common/vp9_blockd.h"
 #include "vp9/encoder/vp9_onyx_int.h"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 void vp9_enable_segmentation(VP9_PTR ptr);
 void vp9_disable_segmentation(VP9_PTR ptr);
 
@@ -45,4 +49,8 @@ void vp9_choose_segmap_coding_method(VP9_COMP *cpi);
 
 void vp9_reset_segment_features(struct segmentation *seg);
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_SEGMENTATION_H_
index 1cafd8775557398e4a710d1d44847cc537e27143..ab5659bf783f214b4ef2d74ada95bf06829f1fb3 100644 (file)
 #ifndef VP9_ENCODER_VP9_SUBEXP_H_
 #define VP9_ENCODER_VP9_SUBEXP_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 void vp9_compute_update_table();
 
 
@@ -32,4 +36,8 @@ int vp9_prob_diff_update_savings_search_model(const unsigned int *ct,
                                               vp9_prob upd,
                                               int b, int r);
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_SUBEXP_H_
index c5f3b467e5403a09d983eaf2c126147b1c6bb22d..eea2f1018577d48cc14f8a73f7f59a6c2fcf2697 100644 (file)
 #ifndef VP9_ENCODER_VP9_TEMPORAL_FILTER_H_
 #define VP9_ENCODER_VP9_TEMPORAL_FILTER_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 void vp9_temporal_filter_prepare(VP9_COMP *cpi, int distance);
 void configure_arnr_filter(VP9_COMP *cpi, const unsigned int this_frame,
                            const int group_boost);
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_TEMPORAL_FILTER_H_
index 67e6c9d3daae1bb934e89c5b6df0dfb1ee4479ed..ea86240beee2ac5d14042e650552b1d7f03f331e 100644 (file)
 #include "vp9/encoder/vp9_block.h"
 #include "vp9/encoder/vp9_treewriter.h"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 void vp9_tokenize_initialize();
 
 #define EOSB_TOKEN 127     // Not signalled, encoder only
@@ -50,4 +54,8 @@ extern const int *vp9_dct_value_cost_ptr;
  */
 extern const TOKENVALUE *vp9_dct_value_tokens_ptr;
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_TOKENIZE_H_
index 09f80b0bad567ccb1212a47d97676d88aaf8aab3..fedfbe937afab9f480121f97cf15822e75d06cee 100644 (file)
 
 #include "vp9/encoder/vp9_writer.h"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #define vp9_cost_zero(prob) (vp9_prob_cost[prob])
 
 #define vp9_cost_one(prob) vp9_cost_zero(vp9_complement(prob))
@@ -69,4 +73,8 @@ static INLINE void vp9_write_token(vp9_writer *w, const vp9_tree_index *tree,
   vp9_write_tree(w, tree, probs, token->value, token->len, 0);
 }
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_TREEWRITER_H_
index c45c479de022087c65d0aa11f889eb7352316568..c73114aebb6dc6b487d84f16c70b03d46ce76d0f 100644 (file)
 
 #include "vp9/encoder/vp9_onyx_int.h"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 unsigned int vp9_vaq_segment_id(int energy);
 double vp9_vaq_rdmult_ratio(int energy);
 double vp9_vaq_inv_q_ratio(int energy);
@@ -23,4 +27,8 @@ void vp9_vaq_frame_setup(VP9_COMP *cpi);
 
 int vp9_block_energy(VP9_COMP *cpi, MACROBLOCK *x, BLOCK_SIZE bs);
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_VAQ_H_
index 2ded97c559e82adcea2ddaee3c40f5415ad4760b..3bc2091f8e96e4623ee945ea0c315a6920dc37c6 100644 (file)
 #define VP9_ENCODER_VP9_VARIANCE_H_
 
 #include "vpx/vpx_integer.h"
-// #include "./vpx_config.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
 
 void variance(const uint8_t *src_ptr,
               int  source_stride,
@@ -112,4 +115,8 @@ static void comp_avg_pred(uint8_t *comp_pred, const uint8_t *pred, int width,
     ref += ref_stride;
   }
 }
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_VARIANCE_H_
index dfed903702402d9caa835a09944917c47edf5c54..5958b48067c59b91c430da0200708b3d81eeebb9 100644 (file)
 
 #include "vpx/vpx_integer.h"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 struct vp9_write_bit_buffer {
   uint8_t *bit_buffer;
   size_t bit_offset;
@@ -45,4 +49,8 @@ static void vp9_wb_write_literal(struct vp9_write_bit_buffer *wb,
 }
 
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_WRITE_BIT_BUFFER_H_
index 9cac7a84f4802589523c4eb9cf2fc1761ae49391..62f555c99e20759051a52b710211fba57e1cd5ff 100644 (file)
 
 #include "vp9/common/vp9_prob.h"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 typedef struct {
   unsigned int lowvalue;
   unsigned int range;
@@ -105,4 +109,8 @@ static void vp9_write_literal(vp9_writer *w, int data, int bits) {
 
 #define vp9_write_prob(w, v) vp9_write_literal((w), (v), 8)
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_VP9_WRITER_H_
index e1fcf40f24b1ae04940a56442732bca69d40f059..c15039ad819f7e274c717544e4e6cde903376157 100644 (file)
 #ifndef VP9_ENCODER_X86_VP9_MCOMP_X86_H_
 #define VP9_ENCODER_X86_VP9_MCOMP_X86_H_
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 #if HAVE_SSE3
 #if !CONFIG_RUNTIME_CPU_DETECT
 
@@ -36,5 +40,9 @@
 #endif
 #endif
 
+#ifdef __cplusplus
+}  // extern "C"
+#endif
+
 #endif  // VP9_ENCODER_X86_VP9_MCOMP_X86_H_