Apply Clang-format
Change-Id: Iaa3ca871a8106a8e57bbc40f4743cf934c98dcbf
diff --git a/aom/aom.h b/aom/aom.h
index e83b4d5..a73b6ab 100644
--- a/aom/aom.h
+++ b/aom/aom.h
@@ -152,4 +152,3 @@
#endif
#endif // AOM_AOM_H_
-
diff --git a/aom/aomcx.h b/aom/aomcx.h
index c4480d0..ef12acf 100644
--- a/aom/aomcx.h
+++ b/aom/aomcx.h
@@ -842,4 +842,3 @@
#endif
#endif // AOM_AOMCX_H_
-
diff --git a/aom/aomdx.h b/aom/aomdx.h
index c1b71c7..e2521fb 100644
--- a/aom/aomdx.h
+++ b/aom/aomdx.h
@@ -64,7 +64,7 @@
* a callback function and opaque context pointer.
*/
AOMD_SET_DECRYPTOR,
- // AOMD_SET_DECRYPTOR = AOMD_SET_DECRYPTOR,
+ // AOMD_SET_DECRYPTOR = AOMD_SET_DECRYPTOR,
/** control function to get the dimensions that the current frame is decoded
* at. This may be different to the intended display size for the frame as
@@ -144,7 +144,7 @@
#define AOM_CTRL_AOMD_GET_LAST_REF_USED
AOM_CTRL_USE_TYPE(AOMD_SET_DECRYPTOR, aom_decrypt_init *)
#define AOM_CTRL_AOMD_SET_DECRYPTOR
-//AOM_CTRL_USE_TYPE(AOMD_SET_DECRYPTOR, aom_decrypt_init *)
+// AOM_CTRL_USE_TYPE(AOMD_SET_DECRYPTOR, aom_decrypt_init *)
//#define AOM_CTRL_AOMD_SET_DECRYPTOR
AOM_CTRL_USE_TYPE(AV1D_GET_DISPLAY_SIZE, int *)
#define AOM_CTRL_AV1D_GET_DISPLAY_SIZE
@@ -163,4 +163,3 @@
#endif
#endif // AOM_AOMDX_H_
-
diff --git a/av1/common/blockd.h b/av1/common/blockd.h
index 0eb0431..3427601 100644
--- a/av1/common/blockd.h
+++ b/av1/common/blockd.h
@@ -124,10 +124,10 @@
}
PREDICTION_MODE av1_left_block_mode(const MODE_INFO *cur_mi,
- const MODE_INFO *left_mi, int b);
+ const MODE_INFO *left_mi, int b);
PREDICTION_MODE av1_above_block_mode(const MODE_INFO *cur_mi,
- const MODE_INFO *above_mi, int b);
+ const MODE_INFO *above_mi, int b);
enum mv_precision { MV_PRECISION_Q3, MV_PRECISION_Q4 };
@@ -307,13 +307,13 @@
foreach_transformed_block_visitor visit, void *arg);
void av1_foreach_transformed_block(const MACROBLOCKD *const xd,
- BLOCK_SIZE bsize,
- foreach_transformed_block_visitor visit,
- void *arg);
+ BLOCK_SIZE bsize,
+ foreach_transformed_block_visitor visit,
+ void *arg);
void av1_set_contexts(const MACROBLOCKD *xd, struct macroblockd_plane *pd,
- BLOCK_SIZE plane_bsize, TX_SIZE tx_size, int has_eob,
- int aoff, int loff);
+ BLOCK_SIZE plane_bsize, TX_SIZE tx_size, int has_eob,
+ int aoff, int loff);
#ifdef __cplusplus
} // extern "C"
diff --git a/av1/common/clpf.h b/av1/common/clpf.h
index d4587f3..0b352f6 100644
--- a/av1/common/clpf.h
+++ b/av1/common/clpf.h
@@ -22,6 +22,6 @@
0 // 1 = filter both luma and chroma, 0 = filter only luma
void av1_clpf_frame(const YV12_BUFFER_CONFIG *frame, const AV1_COMMON *cm,
- MACROBLOCKD *xd);
+ MACROBLOCKD *xd);
#endif
diff --git a/av1/common/common.h b/av1/common/common.h
index 4a2d031..3df5c4f 100644
--- a/av1/common/common.h
+++ b/av1/common/common.h
@@ -27,14 +27,14 @@
#endif
// Only need this for fixed-size arrays, for structs just assign.
-#define av1_copy(dest, src) \
+#define av1_copy(dest, src) \
{ \
assert(sizeof(dest) == sizeof(src)); \
memcpy(dest, src, sizeof(src)); \
}
// Use this for variably-sized arrays.
-#define av1_copy_array(dest, src, n) \
+#define av1_copy_array(dest, src, n) \
{ \
assert(sizeof(*dest) == sizeof(*src)); \
memcpy(dest, src, n * sizeof(*src)); \
diff --git a/av1/common/dering.h b/av1/common/dering.h
index a46e207..2c1efd7 100644
--- a/av1/common/dering.h
+++ b/av1/common/dering.h
@@ -31,11 +31,10 @@
int compute_level_from_index(int global_level, int gi);
int sb_all_skip(const AV1_COMMON *const cm, int mi_row, int mi_col);
void av1_dering_frame(YV12_BUFFER_CONFIG *frame, AV1_COMMON *cm,
- MACROBLOCKD *xd, int global_level);
+ MACROBLOCKD *xd, int global_level);
int av1_dering_search(YV12_BUFFER_CONFIG *frame, const YV12_BUFFER_CONFIG *ref,
- AV1_COMMON *cm,
- MACROBLOCKD *xd);
+ AV1_COMMON *cm, MACROBLOCKD *xd);
#ifdef __cplusplus
} // extern "C"
diff --git a/av1/common/entropy.h b/av1/common/entropy.h
index fdfccf3..edc167c 100644
--- a/av1/common/entropy.h
+++ b/av1/common/entropy.h
@@ -166,7 +166,7 @@
extern const aom_prob av1_pareto8_full[COEFF_PROB_MODELS][MODEL_NODES];
typedef aom_prob av1_coeff_probs_model[REF_TYPES][COEF_BANDS][COEFF_CONTEXTS]
- [UNCONSTRAINED_NODES];
+ [UNCONSTRAINED_NODES];
typedef unsigned int av1_coeff_count_model
[REF_TYPES][COEF_BANDS][COEFF_CONTEXTS][UNCONSTRAINED_NODES + 1];
diff --git a/av1/common/entropymode.h b/av1/common/entropymode.h
index e68cf10..ec5bfb3 100644
--- a/av1/common/entropymode.h
+++ b/av1/common/entropymode.h
@@ -55,8 +55,8 @@
aom_prob partition_prob[PARTITION_CONTEXTS][PARTITION_TYPES - 1];
av1_coeff_probs_model coef_probs[TX_SIZES][PLANE_TYPES];
aom_prob
- switchable_interp_prob[SWITCHABLE_FILTER_CONTEXTS]
- [SWITCHABLE_FILTERS - 1];
+ switchable_interp_prob[SWITCHABLE_FILTER_CONTEXTS][SWITCHABLE_FILTERS -
+ 1];
#if CONFIG_REF_MV
aom_prob newmv_prob[NEWMV_MODE_CONTEXTS];
@@ -142,11 +142,11 @@
void av1_adapt_inter_frame_probs(struct AV1Common *cm);
void av1_tx_counts_to_branch_counts_32x32(const unsigned int *tx_count_32x32p,
- unsigned int (*ct_32x32p)[2]);
+ unsigned int (*ct_32x32p)[2]);
void av1_tx_counts_to_branch_counts_16x16(const unsigned int *tx_count_16x16p,
- unsigned int (*ct_16x16p)[2]);
+ unsigned int (*ct_16x16p)[2]);
void av1_tx_counts_to_branch_counts_8x8(const unsigned int *tx_count_8x8p,
- unsigned int (*ct_8x8p)[2]);
+ unsigned int (*ct_8x8p)[2]);
extern const aom_tree_index av1_ext_tx_tree[TREE_SIZE(TX_TYPES)];
diff --git a/av1/common/enums.h b/av1/common/enums.h
index dab659e..372157e 100644
--- a/av1/common/enums.h
+++ b/av1/common/enums.h
@@ -134,21 +134,21 @@
#if CONFIG_REF_MV
#define NMV_CONTEXTS 3
-#define NEWMV_MODE_CONTEXTS 7
+#define NEWMV_MODE_CONTEXTS 7
#define ZEROMV_MODE_CONTEXTS 2
-#define REFMV_MODE_CONTEXTS 9
-#define DRL_MODE_CONTEXTS 5
+#define REFMV_MODE_CONTEXTS 9
+#define DRL_MODE_CONTEXTS 5
#define ZEROMV_OFFSET 3
-#define REFMV_OFFSET 4
+#define REFMV_OFFSET 4
#define NEWMV_CTX_MASK ((1 << ZEROMV_OFFSET) - 1)
#define ZEROMV_CTX_MASK ((1 << (REFMV_OFFSET - ZEROMV_OFFSET)) - 1)
#define REFMV_CTX_MASK ((1 << (8 - REFMV_OFFSET)) - 1)
-#define ALL_ZERO_FLAG_OFFSET 8
-#define SKIP_NEARESTMV_OFFSET 9
-#define SKIP_NEARMV_OFFSET 10
+#define ALL_ZERO_FLAG_OFFSET 8
+#define SKIP_NEARESTMV_OFFSET 9
+#define SKIP_NEARMV_OFFSET 10
#define SKIP_NEARESTMV_SUB8X8_OFFSET 11
#endif
@@ -159,7 +159,7 @@
#if CONFIG_REF_MV
#define MAX_REF_MV_STACK_SIZE 16
-#define REF_CAT_LEVEL 160
+#define REF_CAT_LEVEL 160
#endif
#define INTRA_INTER_CONTEXTS 4
diff --git a/av1/common/frame_buffers.h b/av1/common/frame_buffers.h
index c062ffe..e7341cf 100644
--- a/av1/common/frame_buffers.h
+++ b/av1/common/frame_buffers.h
@@ -41,7 +41,7 @@
// |min_size| is the minimum size in bytes needed to decode the next frame.
// |fb| pointer to the frame buffer.
int av1_get_frame_buffer(void *cb_priv, size_t min_size,
- aom_codec_frame_buffer_t *fb);
+ aom_codec_frame_buffer_t *fb);
// Callback used by libaom when there are no references to the frame buffer.
// |cb_priv| is not used. |fb| pointer to the frame buffer.
diff --git a/av1/common/idct.h b/av1/common/idct.h
index 3b680c6..a667aac 100644
--- a/av1/common/idct.h
+++ b/av1/common/idct.h
@@ -40,41 +40,41 @@
#endif // CONFIG_AOM_HIGHBITDEPTH
void av1_iwht4x4_add(const tran_low_t *input, uint8_t *dest, int stride,
- int eob);
+ int eob);
void av1_idct4x4_add(const tran_low_t *input, uint8_t *dest, int stride,
- int eob);
+ int eob);
void av1_inv_txfm_add_4x4(const tran_low_t *input, uint8_t *dest, int stride,
- int eob, TX_TYPE tx_type, int lossless);
+ int eob, TX_TYPE tx_type, int lossless);
void av1_inv_txfm_add_8x8(const tran_low_t *input, uint8_t *dest, int stride,
- int eob, TX_TYPE tx_type);
+ int eob, TX_TYPE tx_type);
void av1_inv_txfm_add_16x16(const tran_low_t *input, uint8_t *dest, int stride,
- int eob, TX_TYPE tx_type);
+ int eob, TX_TYPE tx_type);
void av1_inv_txfm_add_32x32(const tran_low_t *input, uint8_t *dest, int stride,
- int eob, TX_TYPE tx_type);
+ int eob, TX_TYPE tx_type);
#if CONFIG_AOM_HIGHBITDEPTH
void av1_highbd_iwht4x4_add(const tran_low_t *input, uint8_t *dest, int stride,
- int eob, int bd);
+ int eob, int bd);
void av1_highbd_idct4x4_add(const tran_low_t *input, uint8_t *dest, int stride,
- int eob, int bd);
+ int eob, int bd);
void av1_highbd_idct8x8_add(const tran_low_t *input, uint8_t *dest, int stride,
- int eob, int bd);
+ int eob, int bd);
void av1_highbd_idct16x16_add(const tran_low_t *input, uint8_t *dest,
- int stride, int eob, int bd);
+ int stride, int eob, int bd);
void av1_highbd_idct32x32_add(const tran_low_t *input, uint8_t *dest,
- int stride, int eob, int bd);
+ int stride, int eob, int bd);
void av1_highbd_inv_txfm_add_4x4(const tran_low_t *input, uint8_t *dest,
- int stride, int eob, int bd, TX_TYPE tx_type,
- int lossless);
+ int stride, int eob, int bd, TX_TYPE tx_type,
+ int lossless);
void av1_highbd_inv_txfm_add_8x8(const tran_low_t *input, uint8_t *dest,
- int stride, int eob, int bd, TX_TYPE tx_type);
+ int stride, int eob, int bd, TX_TYPE tx_type);
void av1_highbd_inv_txfm_add_16x16(const tran_low_t *input, uint8_t *dest,
- int stride, int eob, int bd,
- TX_TYPE tx_type);
+ int stride, int eob, int bd,
+ TX_TYPE tx_type);
void av1_highbd_inv_txfm_add_32x32(const tran_low_t *input, uint8_t *dest,
- int stride, int eob, int bd,
- TX_TYPE tx_type);
+ int stride, int eob, int bd,
+ TX_TYPE tx_type);
#endif // CONFIG_AOM_HIGHBITDEPTH
#ifdef __cplusplus
} // extern "C"
diff --git a/av1/common/loopfilter.h b/av1/common/loopfilter.h
index a8992f4..423fb6a 100644
--- a/av1/common/loopfilter.h
+++ b/av1/common/loopfilter.h
@@ -99,20 +99,20 @@
// This function sets up the bit masks for the entire 64x64 region represented
// by mi_row, mi_col.
void av1_setup_mask(struct AV1Common *const cm, const int mi_row,
- const int mi_col, MODE_INFO **mi_8x8,
- const int mode_info_stride, LOOP_FILTER_MASK *lfm);
+ const int mi_col, MODE_INFO **mi_8x8,
+ const int mode_info_stride, LOOP_FILTER_MASK *lfm);
void av1_filter_block_plane_ss00(struct AV1Common *const cm,
- struct macroblockd_plane *const plane,
- int mi_row, LOOP_FILTER_MASK *lfm);
+ struct macroblockd_plane *const plane,
+ int mi_row, LOOP_FILTER_MASK *lfm);
void av1_filter_block_plane_ss11(struct AV1Common *const cm,
- struct macroblockd_plane *const plane,
- int mi_row, LOOP_FILTER_MASK *lfm);
+ struct macroblockd_plane *const plane,
+ int mi_row, LOOP_FILTER_MASK *lfm);
void av1_filter_block_plane_non420(struct AV1Common *cm,
- struct macroblockd_plane *plane,
- MODE_INFO **mi_8x8, int mi_row, int mi_col);
+ struct macroblockd_plane *plane,
+ MODE_INFO **mi_8x8, int mi_row, int mi_col);
void av1_loop_filter_init(struct AV1Common *cm);
@@ -123,14 +123,14 @@
void av1_loop_filter_frame_init(struct AV1Common *cm, int default_filt_lvl);
void av1_loop_filter_frame(YV12_BUFFER_CONFIG *frame, struct AV1Common *cm,
- struct macroblockd *mbd, int filter_level,
- int y_only, int partial_frame);
+ struct macroblockd *mbd, int filter_level,
+ int y_only, int partial_frame);
// Apply the loop filter to [start, stop) macro block rows in frame_buffer.
void av1_loop_filter_rows(YV12_BUFFER_CONFIG *frame_buffer,
- struct AV1Common *cm,
- struct macroblockd_plane planes[MAX_MB_PLANE],
- int start, int stop, int y_only);
+ struct AV1Common *cm,
+ struct macroblockd_plane planes[MAX_MB_PLANE],
+ int start, int stop, int y_only);
typedef struct LoopFilterWorkerData {
YV12_BUFFER_CONFIG *frame_buffer;
diff --git a/av1/common/mvref_common.h b/av1/common/mvref_common.h
index 14c567e..df5942b 100644
--- a/av1/common/mvref_common.h
+++ b/av1/common/mvref_common.h
@@ -242,12 +242,13 @@
#if CONFIG_REF_MV
static INLINE int_mv get_sub_block_pred_mv(const MODE_INFO *candidate,
- int which_mv,
- int search_col, int block_idx) {
- return block_idx >= 0 && candidate->mbmi.sb_type < BLOCK_8X8 ?
- candidate->bmi[idx_n_column_to_subblock[block_idx]
- [search_col == 0]].pred_mv[which_mv] :
- candidate->mbmi.pred_mv[which_mv];
+ int which_mv, int search_col,
+ int block_idx) {
+ return block_idx >= 0 && candidate->mbmi.sb_type < BLOCK_8X8
+ ? candidate
+ ->bmi[idx_n_column_to_subblock[block_idx][search_col == 0]]
+ .pred_mv[which_mv]
+ : candidate->mbmi.pred_mv[which_mv];
}
#endif
@@ -316,18 +317,15 @@
static INLINE void lower_mv_precision(MV *mv, int allow_hp) {
const int use_hp = allow_hp && av1_use_mv_hp(mv);
if (!use_hp) {
- if (mv->row & 1)
- mv->row += (mv->row > 0 ? -1 : 1);
- if (mv->col & 1)
- mv->col += (mv->col > 0 ? -1 : 1);
+ if (mv->row & 1) mv->row += (mv->row > 0 ? -1 : 1);
+ if (mv->col & 1) mv->col += (mv->col > 0 ? -1 : 1);
}
}
#if CONFIG_REF_MV
static INLINE int av1_nmv_ctx(const uint8_t ref_mv_count,
const CANDIDATE_MV *ref_mv_stack) {
- if (ref_mv_stack[0].weight >= REF_CAT_LEVEL &&
- ref_mv_count > 0) {
+ if (ref_mv_stack[0].weight >= REF_CAT_LEVEL && ref_mv_count > 0) {
if (abs(ref_mv_stack[0].this_mv.as_mv.row -
ref_mv_stack[0].pred_mv.as_mv.row) <= 4 &&
abs(ref_mv_stack[0].this_mv.as_mv.col -
@@ -340,8 +338,7 @@
}
static int8_t av1_ref_frame_type(const MV_REFERENCE_FRAME *const rf) {
- if (rf[1] > INTRA_FRAME)
- return rf[0] + ALTREF_FRAME;
+ if (rf[1] > INTRA_FRAME) return rf[0] + ALTREF_FRAME;
return rf[0];
}
@@ -376,7 +373,7 @@
}
static INLINE uint8_t av1_drl_ctx(const CANDIDATE_MV *ref_mv_stack,
- int ref_idx) {
+ int ref_idx) {
if (ref_mv_stack[ref_idx].weight >= REF_CAT_LEVEL &&
ref_mv_stack[ref_idx + 1].weight >= REF_CAT_LEVEL) {
if (ref_mv_stack[ref_idx].weight == ref_mv_stack[ref_idx + 1].weight)
@@ -406,8 +403,7 @@
void av1_find_mv_refs(const AV1_COMMON *cm, const MACROBLOCKD *xd,
MODE_INFO *mi, MV_REFERENCE_FRAME ref_frame,
#if CONFIG_REF_MV
- uint8_t *ref_mv_count,
- CANDIDATE_MV *ref_mv_stack,
+ uint8_t *ref_mv_count, CANDIDATE_MV *ref_mv_stack,
#endif
int_mv *mv_ref_list, int mi_row, int mi_col,
find_mv_refs_sync sync, void *const data,
@@ -417,7 +413,7 @@
// above and a number cols of pixels in the left to select the one with best
// score to use as ref motion vector
void av1_find_best_ref_mvs(int allow_hp, int_mv *mvlist, int_mv *nearest_mv,
- int_mv *near_mv);
+ int_mv *near_mv);
void av1_append_sub8x8_mvs_for_idx(AV1_COMMON *cm, MACROBLOCKD *xd, int block,
int ref, int mi_row, int mi_col,
diff --git a/av1/common/od_dering.h b/av1/common/od_dering.h
index bf0a70f..17fee7d 100644
--- a/av1/common/od_dering.h
+++ b/av1/common/od_dering.h
@@ -10,14 +10,14 @@
*/
#if !defined(_dering_H)
-# define _dering_H (1)
+#define _dering_H (1)
-# include "odintrin.h"
+#include "odintrin.h"
-# if defined(DAALA_ODINTRIN)
-# include "filter.h"
+#if defined(DAALA_ODINTRIN)
+#include "filter.h"
typedef int16_t od_dering_in;
-# endif
+#endif
#define OD_DERINGSIZES (2)
@@ -27,18 +27,21 @@
#define OD_DERING_LEVELS (6)
extern const double OD_DERING_GAIN_TABLE[OD_DERING_LEVELS];
-#define OD_DERING_NBLOCKS (OD_BSIZE_MAX/8)
+#define OD_DERING_NBLOCKS (OD_BSIZE_MAX / 8)
#define OD_FILT_BORDER (3)
-#define OD_FILT_BSTRIDE (OD_BSIZE_MAX + 2*OD_FILT_BORDER)
+#define OD_FILT_BSTRIDE (OD_BSIZE_MAX + 2 * OD_FILT_BORDER)
extern const int OD_DIRECTION_OFFSETS_TABLE[8][3];
typedef void (*od_filter_dering_direction_func)(int16_t *y, int ystride,
- const int16_t *in, int threshold, int dir);
+ const int16_t *in,
+ int threshold, int dir);
typedef void (*od_filter_dering_orthogonal_func)(int16_t *y, int ystride,
- const int16_t *in, const od_dering_in *x, int xstride, int threshold,
- int dir);
+ const int16_t *in,
+ const od_dering_in *x,
+ int xstride, int threshold,
+ int dir);
struct od_dering_opt_vtbl {
od_filter_dering_direction_func filter_dering_direction[OD_DERINGSIZES];
@@ -46,28 +49,31 @@
};
typedef struct od_dering_opt_vtbl od_dering_opt_vtbl;
-
void od_dering(const od_dering_opt_vtbl *vtbl, int16_t *y, int ystride,
- const od_dering_in *x, int xstride, int nvb, int nhb, int sbx, int sby,
- int nhsb, int nvsb, int xdec, int dir[OD_DERING_NBLOCKS][OD_DERING_NBLOCKS],
- int pli, unsigned char *bskip, int skip_stride, int threshold, int overlap,
- int coeff_shift);
+ const od_dering_in *x, int xstride, int nvb, int nhb, int sbx,
+ int sby, int nhsb, int nvsb, int xdec,
+ int dir[OD_DERING_NBLOCKS][OD_DERING_NBLOCKS], int pli,
+ unsigned char *bskip, int skip_stride, int threshold,
+ int overlap, int coeff_shift);
void od_filter_dering_direction_c(int16_t *y, int ystride, const int16_t *in,
- int ln, int threshold, int dir);
+ int ln, int threshold, int dir);
void od_filter_dering_orthogonal_c(int16_t *y, int ystride, const int16_t *in,
- const od_dering_in *x, int xstride, int ln, int threshold, int dir);
+ const od_dering_in *x, int xstride, int ln,
+ int threshold, int dir);
extern const od_dering_opt_vtbl OD_DERING_VTBL_C;
void od_filter_dering_direction_4x4_c(int16_t *y, int ystride,
- const int16_t *in, int threshold, int dir);
+ const int16_t *in, int threshold,
+ int dir);
void od_filter_dering_direction_8x8_c(int16_t *y, int ystride,
- const int16_t *in, int threshold, int dir);
+ const int16_t *in, int threshold,
+ int dir);
void od_filter_dering_orthogonal_4x4_c(int16_t *y, int ystride,
- const int16_t *in, const od_dering_in *x, int xstride, int threshold,
- int dir);
+ const int16_t *in, const od_dering_in *x,
+ int xstride, int threshold, int dir);
void od_filter_dering_orthogonal_8x8_c(int16_t *y, int ystride,
- const int16_t *in, const od_dering_in *x, int xstride, int threshold,
- int dir);
+ const int16_t *in, const od_dering_in *x,
+ int xstride, int threshold, int dir);
#endif
diff --git a/av1/common/odintrin.h b/av1/common/odintrin.h
index 66e83ef..d01f829 100644
--- a/av1/common/odintrin.h
+++ b/av1/common/odintrin.h
@@ -21,42 +21,43 @@
#endif
/*Smallest blocks are 4x4*/
-# define OD_LOG_BSIZE0 (2)
+#define OD_LOG_BSIZE0 (2)
/*There are 5 block sizes total (4x4, 8x8, 16x16, 32x32 and 64x64).*/
-# define OD_NBSIZES (5)
+#define OD_NBSIZES (5)
/*The log of the maximum length of the side of a block.*/
-# define OD_LOG_BSIZE_MAX (OD_LOG_BSIZE0 + OD_NBSIZES - 1)
+#define OD_LOG_BSIZE_MAX (OD_LOG_BSIZE0 + OD_NBSIZES - 1)
/*The maximum length of the side of a block.*/
-# define OD_BSIZE_MAX (1 << OD_LOG_BSIZE_MAX)
+#define OD_BSIZE_MAX (1 << OD_LOG_BSIZE_MAX)
typedef int od_coeff;
typedef int16_t od_dering_in;
-# define OD_DIVU_DMAX (1024)
+#define OD_DIVU_DMAX (1024)
extern uint32_t OD_DIVU_SMALL_CONSTS[OD_DIVU_DMAX][2];
/*Translate unsigned division by small divisors into multiplications.*/
-# define OD_DIVU_SMALL(_x, _d) \
- ((uint32_t)((OD_DIVU_SMALL_CONSTS[(_d)-1][0]* \
- (uint64_t)(_x)+OD_DIVU_SMALL_CONSTS[(_d)-1][1])>>32)>> \
- (OD_ILOG(_d)-1))
+#define OD_DIVU_SMALL(_x, _d) \
+ ((uint32_t)((OD_DIVU_SMALL_CONSTS[(_d)-1][0] * (uint64_t)(_x) + \
+ OD_DIVU_SMALL_CONSTS[(_d)-1][1]) >> \
+ 32) >> \
+ (OD_ILOG(_d) - 1))
-# define OD_DIVU(_x, _d) \
- (((_d) < OD_DIVU_DMAX)?(OD_DIVU_SMALL((_x), (_d))):((_x)/(_d)))
+#define OD_DIVU(_x, _d) \
+ (((_d) < OD_DIVU_DMAX) ? (OD_DIVU_SMALL((_x), (_d))) : ((_x) / (_d)))
#define OD_MINI AOMMIN
#define OD_CLAMPI(min, val, max) clamp((val), (min), (max))
-# define OD_CLZ0 (1)
-# define OD_CLZ(x) (-get_msb(x))
-# define OD_ILOG_NZ(x) (OD_CLZ0 - OD_CLZ(x))
+#define OD_CLZ0 (1)
+#define OD_CLZ(x) (-get_msb(x))
+#define OD_ILOG_NZ(x) (OD_CLZ0 - OD_CLZ(x))
/*Note that __builtin_clz is not defined when x == 0, according to the gcc
documentation (and that of the x86 BSR instruction that implements it), so
we have to special-case it.
We define a special version of the macro to use when x can be zero.*/
-# define OD_ILOG(x) ((x) ? OD_ILOG_NZ(x) : 0)
+#define OD_ILOG(x) ((x) ? OD_ILOG_NZ(x) : 0)
#ifdef __cplusplus
} // extern "C"
diff --git a/av1/common/onyxc_int.h b/av1/common/onyxc_int.h
index f1e58bb..fe1fff5 100644
--- a/av1/common/onyxc_int.h
+++ b/av1/common/onyxc_int.h
@@ -389,7 +389,7 @@
}
static INLINE void av1_init_macroblockd(AV1_COMMON *cm, MACROBLOCKD *xd,
- tran_low_t *dqcoeff) {
+ tran_low_t *dqcoeff) {
int i;
for (i = 0; i < MAX_MB_PLANE; ++i) {
@@ -469,12 +469,10 @@
#if CONFIG_REF_MV
xd->is_sec_rect = 0;
if (xd->n8_w < xd->n8_h)
- if (mi_col & (xd->n8_h - 1))
- xd->is_sec_rect = 1;
+ if (mi_col & (xd->n8_h - 1)) xd->is_sec_rect = 1;
if (xd->n8_w > xd->n8_h)
- if (mi_row & (xd->n8_w - 1))
- xd->is_sec_rect = 1;
+ if (mi_row & (xd->n8_w - 1)) xd->is_sec_rect = 1;
#endif
}
diff --git a/av1/common/pred_common.h b/av1/common/pred_common.h
index b870fee..5b0e512 100644
--- a/av1/common/pred_common.h
+++ b/av1/common/pred_common.h
@@ -63,7 +63,7 @@
}
static INLINE aom_prob av1_get_skip_prob(const AV1_COMMON *cm,
- const MACROBLOCKD *xd) {
+ const MACROBLOCKD *xd) {
return cm->fc->skip_probs[av1_get_skip_context(xd)];
}
@@ -72,23 +72,22 @@
int av1_get_intra_inter_context(const MACROBLOCKD *xd);
static INLINE aom_prob av1_get_intra_inter_prob(const AV1_COMMON *cm,
- const MACROBLOCKD *xd) {
+ const MACROBLOCKD *xd) {
return cm->fc->intra_inter_prob[av1_get_intra_inter_context(xd)];
}
-int av1_get_reference_mode_context(const AV1_COMMON *cm,
- const MACROBLOCKD *xd);
+int av1_get_reference_mode_context(const AV1_COMMON *cm, const MACROBLOCKD *xd);
static INLINE aom_prob av1_get_reference_mode_prob(const AV1_COMMON *cm,
- const MACROBLOCKD *xd) {
+ const MACROBLOCKD *xd) {
return cm->fc->comp_inter_prob[av1_get_reference_mode_context(cm, xd)];
}
int av1_get_pred_context_comp_ref_p(const AV1_COMMON *cm,
- const MACROBLOCKD *xd);
+ const MACROBLOCKD *xd);
static INLINE aom_prob av1_get_pred_prob_comp_ref_p(const AV1_COMMON *cm,
- const MACROBLOCKD *xd) {
+ const MACROBLOCKD *xd) {
const int pred_context = av1_get_pred_context_comp_ref_p(cm, xd);
return cm->fc->comp_ref_prob[pred_context];
}
@@ -96,14 +95,14 @@
int av1_get_pred_context_single_ref_p1(const MACROBLOCKD *xd);
static INLINE aom_prob av1_get_pred_prob_single_ref_p1(const AV1_COMMON *cm,
- const MACROBLOCKD *xd) {
+ const MACROBLOCKD *xd) {
return cm->fc->single_ref_prob[av1_get_pred_context_single_ref_p1(xd)][0];
}
int av1_get_pred_context_single_ref_p2(const MACROBLOCKD *xd);
static INLINE aom_prob av1_get_pred_prob_single_ref_p2(const AV1_COMMON *cm,
- const MACROBLOCKD *xd) {
+ const MACROBLOCKD *xd) {
return cm->fc->single_ref_prob[av1_get_pred_context_single_ref_p2(xd)][1];
}
diff --git a/av1/common/quant_common.h b/av1/common/quant_common.h
index 063a1bd..e0238a9 100644
--- a/av1/common/quant_common.h
+++ b/av1/common/quant_common.h
@@ -41,7 +41,7 @@
int16_t av1_ac_quant(int qindex, int delta, aom_bit_depth_t bit_depth);
int av1_get_qindex(const struct segmentation *seg, int segment_id,
- int base_qindex);
+ int base_qindex);
#if CONFIG_AOM_QM
// Reduce the large number of quantizers to a smaller number of levels for which
// different matrices may be defined
diff --git a/av1/common/reconinter.h b/av1/common/reconinter.h
index 97a0c9d..cb7291f 100644
--- a/av1/common/reconinter.h
+++ b/av1/common/reconinter.h
@@ -113,26 +113,26 @@
int bh, int x, int y, int w, int h, int mi_x,
int mi_y);
-void av1_build_inter_predictor_sub8x8(MACROBLOCKD *xd, int plane, int i,
- int ir, int ic, int mi_row, int mi_col);
+void av1_build_inter_predictor_sub8x8(MACROBLOCKD *xd, int plane, int i, int ir,
+ int ic, int mi_row, int mi_col);
void av1_build_inter_predictors_sby(MACROBLOCKD *xd, int mi_row, int mi_col,
- BLOCK_SIZE bsize);
-
-void av1_build_inter_predictors_sbp(MACROBLOCKD *xd, int mi_row, int mi_col,
- BLOCK_SIZE bsize, int plane);
-
-void av1_build_inter_predictors_sbuv(MACROBLOCKD *xd, int mi_row, int mi_col,
- BLOCK_SIZE bsize);
-
-void av1_build_inter_predictors_sb(MACROBLOCKD *xd, int mi_row, int mi_col,
BLOCK_SIZE bsize);
-void av1_build_inter_predictor(const uint8_t *src, int src_stride,
- uint8_t *dst, int dst_stride, const MV *mv_q3,
- const struct scale_factors *sf, int w, int h,
- int do_avg, const InterpKernel *kernel,
- enum mv_precision precision, int x, int y);
+void av1_build_inter_predictors_sbp(MACROBLOCKD *xd, int mi_row, int mi_col,
+ BLOCK_SIZE bsize, int plane);
+
+void av1_build_inter_predictors_sbuv(MACROBLOCKD *xd, int mi_row, int mi_col,
+ BLOCK_SIZE bsize);
+
+void av1_build_inter_predictors_sb(MACROBLOCKD *xd, int mi_row, int mi_col,
+ BLOCK_SIZE bsize);
+
+void av1_build_inter_predictor(const uint8_t *src, int src_stride, uint8_t *dst,
+ int dst_stride, const MV *mv_q3,
+ const struct scale_factors *sf, int w, int h,
+ int do_avg, const InterpKernel *kernel,
+ enum mv_precision precision, int x, int y);
#if CONFIG_AOM_HIGHBITDEPTH
void av1_highbd_build_inter_predictor(
@@ -160,12 +160,12 @@
}
void av1_setup_dst_planes(struct macroblockd_plane planes[MAX_MB_PLANE],
- const YV12_BUFFER_CONFIG *src, int mi_row,
- int mi_col);
+ const YV12_BUFFER_CONFIG *src, int mi_row,
+ int mi_col);
void av1_setup_pre_planes(MACROBLOCKD *xd, int idx,
- const YV12_BUFFER_CONFIG *src, int mi_row,
- int mi_col, const struct scale_factors *sf);
+ const YV12_BUFFER_CONFIG *src, int mi_row, int mi_col,
+ const struct scale_factors *sf);
#ifdef __cplusplus
} // extern "C"
diff --git a/av1/common/reconintra.h b/av1/common/reconintra.h
index 9a00b9b..f75dbcd 100644
--- a/av1/common/reconintra.h
+++ b/av1/common/reconintra.h
@@ -22,9 +22,9 @@
void av1_init_intra_predictors(void);
void av1_predict_intra_block(const MACROBLOCKD *xd, int bwl_in, int bhl_in,
- TX_SIZE tx_size, PREDICTION_MODE mode,
- const uint8_t *ref, int ref_stride, uint8_t *dst,
- int dst_stride, int aoff, int loff, int plane);
+ TX_SIZE tx_size, PREDICTION_MODE mode,
+ const uint8_t *ref, int ref_stride, uint8_t *dst,
+ int dst_stride, int aoff, int loff, int plane);
#ifdef __cplusplus
} // extern "C"
#endif
diff --git a/av1/common/scale.h b/av1/common/scale.h
index 29df9b6..16ec349 100644
--- a/av1/common/scale.h
+++ b/av1/common/scale.h
@@ -42,11 +42,11 @@
#if CONFIG_AOM_HIGHBITDEPTH
void av1_setup_scale_factors_for_frame(struct scale_factors *sf, int other_w,
- int other_h, int this_w, int this_h,
- int use_high);
+ int other_h, int this_w, int this_h,
+ int use_high);
#else
void av1_setup_scale_factors_for_frame(struct scale_factors *sf, int other_w,
- int other_h, int this_w, int this_h);
+ int other_h, int this_w, int this_h);
#endif
static INLINE int av1_is_valid_scale(const struct scale_factors *sf) {
diff --git a/av1/common/seg_common.h b/av1/common/seg_common.h
index eda022f..8c85d9a 100644
--- a/av1/common/seg_common.h
+++ b/av1/common/seg_common.h
@@ -60,14 +60,14 @@
void av1_clearall_segfeatures(struct segmentation *seg);
void av1_enable_segfeature(struct segmentation *seg, int segment_id,
- SEG_LVL_FEATURES feature_id);
+ SEG_LVL_FEATURES feature_id);
int av1_seg_feature_data_max(SEG_LVL_FEATURES feature_id);
int av1_is_segfeature_signed(SEG_LVL_FEATURES feature_id);
void av1_set_segdata(struct segmentation *seg, int segment_id,
- SEG_LVL_FEATURES feature_id, int seg_data);
+ SEG_LVL_FEATURES feature_id, int seg_data);
static INLINE int get_segdata(const struct segmentation *seg, int segment_id,
SEG_LVL_FEATURES feature_id) {
diff --git a/av1/common/thread_common.h b/av1/common/thread_common.h
index 763737b..8f33d27 100644
--- a/av1/common/thread_common.h
+++ b/av1/common/thread_common.h
@@ -41,21 +41,21 @@
} AV1LfSync;
// Allocate memory for loopfilter row synchronization.
-void av1_loop_filter_alloc(AV1LfSync *lf_sync, struct AV1Common *cm,
- int rows, int width, int num_workers);
+void av1_loop_filter_alloc(AV1LfSync *lf_sync, struct AV1Common *cm, int rows,
+ int width, int num_workers);
// Deallocate loopfilter synchronization related mutex and data.
void av1_loop_filter_dealloc(AV1LfSync *lf_sync);
// Multi-threaded loopfilter that uses the tile threads.
void av1_loop_filter_frame_mt(YV12_BUFFER_CONFIG *frame, struct AV1Common *cm,
- struct macroblockd_plane planes[MAX_MB_PLANE],
- int frame_filter_level, int y_only,
- int partial_frame, AVxWorker *workers,
- int num_workers, AV1LfSync *lf_sync);
+ struct macroblockd_plane planes[MAX_MB_PLANE],
+ int frame_filter_level, int y_only,
+ int partial_frame, AVxWorker *workers,
+ int num_workers, AV1LfSync *lf_sync);
void av1_accumulate_frame_counts(struct AV1Common *cm,
- struct FRAME_COUNTS *counts, int is_dec);
+ struct FRAME_COUNTS *counts, int is_dec);
#ifdef __cplusplus
} // extern "C"
diff --git a/av1/common/tile_common.h b/av1/common/tile_common.h
index 23a7ce0..5b997e6 100644
--- a/av1/common/tile_common.h
+++ b/av1/common/tile_common.h
@@ -26,13 +26,13 @@
// initializes 'tile->mi_(row|col)_(start|end)' for (row, col) based on
// 'cm->log2_tile_(rows|cols)' & 'cm->mi_(rows|cols)'
void av1_tile_init(TileInfo *tile, const struct AV1Common *cm, int row,
- int col);
+ int col);
void av1_tile_set_row(TileInfo *tile, const struct AV1Common *cm, int row);
void av1_tile_set_col(TileInfo *tile, const struct AV1Common *cm, int col);
void av1_get_tile_n_bits(int mi_cols, int *min_log2_tile_cols,
- int *max_log2_tile_cols);
+ int *max_log2_tile_cols);
#ifdef __cplusplus
} // extern "C"
diff --git a/av1/decoder/decodeframe.h b/av1/decoder/decodeframe.h
index f6e35a4..346a0d9 100644
--- a/av1/decoder/decodeframe.h
+++ b/av1/decoder/decodeframe.h
@@ -21,11 +21,11 @@
int av1_read_sync_code(struct aom_read_bit_buffer *const rb);
void av1_read_frame_size(struct aom_read_bit_buffer *rb, int *width,
- int *height);
+ int *height);
BITSTREAM_PROFILE av1_read_profile(struct aom_read_bit_buffer *rb);
void av1_decode_frame(struct AV1Decoder *pbi, const uint8_t *data,
- const uint8_t *data_end, const uint8_t **p_data_end);
+ const uint8_t *data_end, const uint8_t **p_data_end);
#ifdef __cplusplus
} // extern "C"
diff --git a/av1/decoder/decodemv.h b/av1/decoder/decodemv.h
index 6ae3df4..6a714e5 100644
--- a/av1/decoder/decodemv.h
+++ b/av1/decoder/decodemv.h
@@ -21,7 +21,7 @@
#endif
void av1_read_mode_info(AV1Decoder *const pbi, MACROBLOCKD *xd, int mi_row,
- int mi_col, aom_reader *r, int x_mis, int y_mis);
+ int mi_col, aom_reader *r, int x_mis, int y_mis);
#ifdef __cplusplus
} // extern "C"
diff --git a/av1/decoder/decoder.h b/av1/decoder/decoder.h
index 8bdef30..af4293a 100644
--- a/av1/decoder/decoder.h
+++ b/av1/decoder/decoder.h
@@ -83,18 +83,18 @@
} AV1Decoder;
int av1_receive_compressed_data(struct AV1Decoder *pbi, size_t size,
- const uint8_t **dest);
+ const uint8_t **dest);
int av1_get_raw_frame(struct AV1Decoder *pbi, YV12_BUFFER_CONFIG *sd);
aom_codec_err_t av1_copy_reference_dec(struct AV1Decoder *pbi,
- AOM_REFFRAME ref_frame_flag,
- YV12_BUFFER_CONFIG *sd);
-
-aom_codec_err_t av1_set_reference_dec(AV1_COMMON *cm,
AOM_REFFRAME ref_frame_flag,
YV12_BUFFER_CONFIG *sd);
+aom_codec_err_t av1_set_reference_dec(AV1_COMMON *cm,
+ AOM_REFFRAME ref_frame_flag,
+ YV12_BUFFER_CONFIG *sd);
+
static INLINE uint8_t read_marker(aom_decrypt_cb decrypt_cb,
void *decrypt_state, const uint8_t *data) {
if (decrypt_cb) {
@@ -108,9 +108,9 @@
// This function is exposed for use in tests, as well as the inlined function
// "read_marker".
aom_codec_err_t av1_parse_superframe_index(const uint8_t *data, size_t data_sz,
- uint32_t sizes[8], int *count,
- aom_decrypt_cb decrypt_cb,
- void *decrypt_state);
+ uint32_t sizes[8], int *count,
+ aom_decrypt_cb decrypt_cb,
+ void *decrypt_state);
struct AV1Decoder *av1_decoder_create(BufferPool *const pool);
diff --git a/av1/decoder/detokenize.h b/av1/decoder/detokenize.h
index 2f21334..8077811 100644
--- a/av1/decoder/detokenize.h
+++ b/av1/decoder/detokenize.h
@@ -21,8 +21,8 @@
#endif
int av1_decode_block_tokens(MACROBLOCKD *xd, int plane, const scan_order *sc,
- int x, int y, TX_SIZE tx_size, aom_reader *r,
- int seg_id);
+ int x, int y, TX_SIZE tx_size, aom_reader *r,
+ int seg_id);
#ifdef __cplusplus
} // extern "C"
diff --git a/av1/decoder/dthread.h b/av1/decoder/dthread.h
index e54ca05..c17053d 100644
--- a/av1/decoder/dthread.h
+++ b/av1/decoder/dthread.h
@@ -58,7 +58,7 @@
// start decoding next frame. So need to check whether worker is still decoding
// ref_buf.
void av1_frameworker_wait(AVxWorker *const worker, RefCntBuffer *const ref_buf,
- int row);
+ int row);
// FrameWorker broadcasts its decoding progress so other workers that are
// waiting on it can resume decoding.
@@ -66,7 +66,7 @@
// Copy necessary decoding context from src worker to dst worker.
void av1_frameworker_copy_context(AVxWorker *const dst_worker,
- AVxWorker *const src_worker);
+ AVxWorker *const src_worker);
#ifdef __cplusplus
} // extern "C"
diff --git a/av1/encoder/aq_complexity.h b/av1/encoder/aq_complexity.h
index 05658d4..1d966ac 100644
--- a/av1/encoder/aq_complexity.h
+++ b/av1/encoder/aq_complexity.h
@@ -23,8 +23,8 @@
// Select a segment for the current Block.
void av1_caq_select_segment(struct AV1_COMP *cpi, struct macroblock *,
- BLOCK_SIZE bs, int mi_row, int mi_col,
- int projected_rate);
+ BLOCK_SIZE bs, int mi_row, int mi_col,
+ int projected_rate);
// This function sets up a set of segments with delta Q values around
// the baseline frame quantizer.
diff --git a/av1/encoder/aq_cyclicrefresh.h b/av1/encoder/aq_cyclicrefresh.h
index 327fe14..cdc9815 100644
--- a/av1/encoder/aq_cyclicrefresh.h
+++ b/av1/encoder/aq_cyclicrefresh.h
@@ -39,20 +39,20 @@
// Estimate the bits, incorporating the delta-q from segment 1, after encoding
// the frame.
int av1_cyclic_refresh_estimate_bits_at_q(const struct AV1_COMP *cpi,
- double correction_factor);
+ double correction_factor);
// Estimate the bits per mb, for a given q = i and a corresponding delta-q
// (for segment 1), prior to encoding the frame.
int av1_cyclic_refresh_rc_bits_per_mb(const struct AV1_COMP *cpi, int i,
- double correction_factor);
+ double correction_factor);
// Prior to coding a given prediction block, of size bsize at (mi_row, mi_col),
// check if we should reset the segment_id, and update the cyclic_refresh map
// and segmentation map.
void av1_cyclic_refresh_update_segment(struct AV1_COMP *const cpi,
- MB_MODE_INFO *const mbmi, int mi_row,
- int mi_col, BLOCK_SIZE bsize,
- int64_t rate, int64_t dist, int skip);
+ MB_MODE_INFO *const mbmi, int mi_row,
+ int mi_col, BLOCK_SIZE bsize,
+ int64_t rate, int64_t dist, int skip);
// Update the segmentation map, and related quantities: cyclic refresh map,
// refresh sb_index, and target number of blocks to be refreshed.
diff --git a/av1/encoder/block.h b/av1/encoder/block.h
index 97b07ec..4b2512c 100644
--- a/av1/encoder/block.h
+++ b/av1/encoder/block.h
@@ -49,7 +49,7 @@
/* The [2] dimension is for whether we skip the EOB node (i.e. if previous
* coefficient in this block was zero) or not. */
typedef unsigned int av1_coeff_cost[PLANE_TYPES][REF_TYPES][COEF_BANDS][2]
- [COEFF_CONTEXTS][ENTROPY_TOKENS];
+ [COEFF_CONTEXTS][ENTROPY_TOKENS];
typedef struct {
int_mv ref_mvs[MODE_CTX_REF_FRAMES][MAX_MV_REF_CANDIDATES];
diff --git a/av1/encoder/encodeframe.h b/av1/encoder/encodeframe.h
index 59936db..ca4d5a5 100644
--- a/av1/encoder/encodeframe.h
+++ b/av1/encoder/encodeframe.h
@@ -31,14 +31,14 @@
#define VAR_HIST_SMALL_CUT_OFF 45
void av1_setup_src_planes(struct macroblock *x,
- const struct yv12_buffer_config *src, int mi_row,
- int mi_col);
+ const struct yv12_buffer_config *src, int mi_row,
+ int mi_col);
void av1_encode_frame(struct AV1_COMP *cpi);
void av1_init_tile_data(struct AV1_COMP *cpi);
-void av1_encode_tile(struct AV1_COMP *cpi, struct ThreadData *td,
- int tile_row, int tile_col);
+void av1_encode_tile(struct AV1_COMP *cpi, struct ThreadData *td, int tile_row,
+ int tile_col);
void av1_set_variance_partition_thresholds(struct AV1_COMP *cpi, int q);
diff --git a/av1/encoder/encodemb.h b/av1/encoder/encodemb.h
index f0ebaea..961a6b1 100644
--- a/av1/encoder/encodemb.h
+++ b/av1/encoder/encodemb.h
@@ -27,26 +27,25 @@
void av1_encode_sb(MACROBLOCK *x, BLOCK_SIZE bsize);
void av1_encode_sby_pass1(MACROBLOCK *x, BLOCK_SIZE bsize);
void av1_xform_quant_fp(MACROBLOCK *x, int plane, int block, int blk_row,
- int blk_col, BLOCK_SIZE plane_bsize, TX_SIZE tx_size);
+ int blk_col, BLOCK_SIZE plane_bsize, TX_SIZE tx_size);
void av1_xform_quant_dc(MACROBLOCK *x, int plane, int block, int blk_row,
- int blk_col, BLOCK_SIZE plane_bsize, TX_SIZE tx_size);
+ int blk_col, BLOCK_SIZE plane_bsize, TX_SIZE tx_size);
void av1_xform_quant(MACROBLOCK *x, int plane, int block, int blk_row,
- int blk_col, BLOCK_SIZE plane_bsize, TX_SIZE tx_size);
+ int blk_col, BLOCK_SIZE plane_bsize, TX_SIZE tx_size);
void av1_subtract_plane(MACROBLOCK *x, BLOCK_SIZE bsize, int plane);
void av1_encode_block_intra(int plane, int block, int blk_row, int blk_col,
- BLOCK_SIZE plane_bsize, TX_SIZE tx_size,
- void *arg);
+ BLOCK_SIZE plane_bsize, TX_SIZE tx_size, void *arg);
void av1_encode_intra_block_plane(MACROBLOCK *x, BLOCK_SIZE bsize, int plane);
void av1_fwd_txfm_4x4(const int16_t *src_diff, tran_low_t *coeff,
- int diff_stride, TX_TYPE tx_type, int lossless);
+ int diff_stride, TX_TYPE tx_type, int lossless);
#if CONFIG_AOM_HIGHBITDEPTH
void av1_highbd_fwd_txfm_4x4(const int16_t *src_diff, tran_low_t *coeff,
- int diff_stride, TX_TYPE tx_type, int lossless);
+ int diff_stride, TX_TYPE tx_type, int lossless);
#endif // CONFIG_AOM_HIGHBITDEPTH
#ifdef __cplusplus
diff --git a/av1/encoder/encodemv.h b/av1/encoder/encodemv.h
index 1c0d90f..87e2de5 100644
--- a/av1/encoder/encodemv.h
+++ b/av1/encoder/encodemv.h
@@ -21,13 +21,13 @@
void av1_entropy_mv_init(void);
void av1_write_nmv_probs(AV1_COMMON *cm, int usehp, aom_writer *w,
- nmv_context_counts *const counts);
+ nmv_context_counts *const counts);
void av1_encode_mv(AV1_COMP *cpi, aom_writer *w, const MV *mv, const MV *ref,
- const nmv_context *mvctx, int usehp);
+ const nmv_context *mvctx, int usehp);
void av1_build_nmv_cost_table(int *mvjoint, int *mvcost[2],
- const nmv_context *mvctx, int usehp);
+ const nmv_context *mvctx, int usehp);
void av1_update_mv_count(ThreadData *td);
diff --git a/av1/encoder/encoder.h b/av1/encoder/encoder.h
index 482133a..c2240a7 100644
--- a/av1/encoder/encoder.h
+++ b/av1/encoder/encoder.h
@@ -499,7 +499,7 @@
void av1_initialize_enc(void);
struct AV1_COMP *av1_create_compressor(AV1EncoderConfig *oxcf,
- BufferPool *const pool);
+ BufferPool *const pool);
void av1_remove_compressor(AV1_COMP *cpi);
void av1_change_config(AV1_COMP *cpi, const AV1EncoderConfig *oxcf);
@@ -507,12 +507,12 @@
// receive a frames worth of data. caller can assume that a copy of this
// frame is made and not just a copy of the pointer..
int av1_receive_raw_frame(AV1_COMP *cpi, unsigned int frame_flags,
- YV12_BUFFER_CONFIG *sd, int64_t time_stamp,
- int64_t end_time_stamp);
+ YV12_BUFFER_CONFIG *sd, int64_t time_stamp,
+ int64_t end_time_stamp);
int av1_get_compressed_data(AV1_COMP *cpi, unsigned int *frame_flags,
- size_t *size, uint8_t *dest, int64_t *time_stamp,
- int64_t *time_end, int flush);
+ size_t *size, uint8_t *dest, int64_t *time_stamp,
+ int64_t *time_end, int flush);
int av1_get_preview_raw_frame(AV1_COMP *cpi, YV12_BUFFER_CONFIG *dest);
@@ -521,10 +521,10 @@
void av1_update_reference(AV1_COMP *cpi, int ref_frame_flags);
int av1_copy_reference_enc(AV1_COMP *cpi, AOM_REFFRAME ref_frame_flag,
- YV12_BUFFER_CONFIG *sd);
+ YV12_BUFFER_CONFIG *sd);
int av1_set_reference_enc(AV1_COMP *cpi, AOM_REFFRAME ref_frame_flag,
- YV12_BUFFER_CONFIG *sd);
+ YV12_BUFFER_CONFIG *sd);
int av1_update_entropy(AV1_COMP *cpi, int update);
@@ -533,10 +533,10 @@
int av1_get_active_map(AV1_COMP *cpi, unsigned char *map, int rows, int cols);
int av1_set_internal_size(AV1_COMP *cpi, AOM_SCALING horiz_mode,
- AOM_SCALING vert_mode);
+ AOM_SCALING vert_mode);
int av1_set_size_literal(AV1_COMP *cpi, unsigned int width,
- unsigned int height);
+ unsigned int height);
int av1_get_quantizer(struct AV1_COMP *cpi);
@@ -598,12 +598,12 @@
void av1_set_high_precision_mv(AV1_COMP *cpi, int allow_high_precision_mv);
YV12_BUFFER_CONFIG *av1_scale_if_required_fast(AV1_COMMON *cm,
- YV12_BUFFER_CONFIG *unscaled,
- YV12_BUFFER_CONFIG *scaled);
+ YV12_BUFFER_CONFIG *unscaled,
+ YV12_BUFFER_CONFIG *scaled);
YV12_BUFFER_CONFIG *av1_scale_if_required(AV1_COMMON *cm,
- YV12_BUFFER_CONFIG *unscaled,
- YV12_BUFFER_CONFIG *scaled);
+ YV12_BUFFER_CONFIG *unscaled,
+ YV12_BUFFER_CONFIG *scaled);
void av1_apply_encoding_flags(AV1_COMP *cpi, aom_enc_frame_flags_t flags);
diff --git a/av1/encoder/extend.h b/av1/encoder/extend.h
index ccd8654..48178b9 100644
--- a/av1/encoder/extend.h
+++ b/av1/encoder/extend.h
@@ -20,11 +20,11 @@
#endif
void av1_copy_and_extend_frame(const YV12_BUFFER_CONFIG *src,
- YV12_BUFFER_CONFIG *dst);
+ YV12_BUFFER_CONFIG *dst);
void av1_copy_and_extend_frame_with_rect(const YV12_BUFFER_CONFIG *src,
- YV12_BUFFER_CONFIG *dst, int srcy,
- int srcx, int srch, int srcw);
+ YV12_BUFFER_CONFIG *dst, int srcy,
+ int srcx, int srch, int srcw);
#ifdef __cplusplus
} // extern "C"
#endif
diff --git a/av1/encoder/firstpass.h b/av1/encoder/firstpass.h
index f5fe329..d9366c0 100644
--- a/av1/encoder/firstpass.h
+++ b/av1/encoder/firstpass.h
@@ -143,8 +143,7 @@
void av1_init_first_pass(struct AV1_COMP *cpi);
void av1_rc_get_first_pass_params(struct AV1_COMP *cpi);
-void av1_first_pass(struct AV1_COMP *cpi,
- const struct lookahead_entry *source);
+void av1_first_pass(struct AV1_COMP *cpi, const struct lookahead_entry *source);
void av1_end_first_pass(struct AV1_COMP *cpi);
void av1_init_second_pass(struct AV1_COMP *cpi);
@@ -157,7 +156,7 @@
void av1_init_subsampling(struct AV1_COMP *cpi);
void av1_calculate_coded_size(struct AV1_COMP *cpi, int *scaled_frame_width,
- int *scaled_frame_height);
+ int *scaled_frame_height);
#ifdef __cplusplus
} // extern "C"
diff --git a/av1/encoder/lookahead.h b/av1/encoder/lookahead.h
index b0e33ee..4f2803c 100644
--- a/av1/encoder/lookahead.h
+++ b/av1/encoder/lookahead.h
@@ -45,13 +45,13 @@
* may be done when buffers are enqueued.
*/
struct lookahead_ctx *av1_lookahead_init(unsigned int width,
- unsigned int height,
- unsigned int subsampling_x,
- unsigned int subsampling_y,
+ unsigned int height,
+ unsigned int subsampling_x,
+ unsigned int subsampling_y,
#if CONFIG_AOM_HIGHBITDEPTH
- int use_highbitdepth,
+ int use_highbitdepth,
#endif
- unsigned int depth);
+ unsigned int depth);
/**\brief Destroys the lookahead stage
*/
@@ -73,11 +73,11 @@
* \param[in] active_map Map that specifies which macroblock is active
*/
int av1_lookahead_push(struct lookahead_ctx *ctx, YV12_BUFFER_CONFIG *src,
- int64_t ts_start, int64_t ts_end,
+ int64_t ts_start, int64_t ts_end,
#if CONFIG_AOM_HIGHBITDEPTH
- int use_highbitdepth,
+ int use_highbitdepth,
#endif
- unsigned int flags);
+ unsigned int flags);
/**\brief Get the next source buffer to encode
*
@@ -89,8 +89,7 @@
* \retval NULL, if drain set and queue is empty
* \retval NULL, if drain not set and queue not of the configured depth
*/
-struct lookahead_entry *av1_lookahead_pop(struct lookahead_ctx *ctx,
- int drain);
+struct lookahead_entry *av1_lookahead_pop(struct lookahead_ctx *ctx, int drain);
/**\brief Get a future source buffer to encode
*
@@ -100,7 +99,7 @@
* \retval NULL, if no buffer exists at the specified index
*/
struct lookahead_entry *av1_lookahead_peek(struct lookahead_ctx *ctx,
- int index);
+ int index);
/**\brief Get the number of frames currently in the lookahead queue
*
diff --git a/av1/encoder/mcomp.h b/av1/encoder/mcomp.h
index c943d3c..59ff74e 100644
--- a/av1/encoder/mcomp.h
+++ b/av1/encoder/mcomp.h
@@ -48,15 +48,15 @@
void av1_set_mv_search_range(MACROBLOCK *x, const MV *mv);
int av1_mv_bit_cost(const MV *mv, const MV *ref, const int *mvjcost,
- int *mvcost[2], int weight);
+ int *mvcost[2], int weight);
// Utility to compute variance + MV rate cost for a given MV
int av1_get_mvpred_var(const MACROBLOCK *x, const MV *best_mv,
- const MV *center_mv, const aom_variance_fn_ptr_t *vfp,
- int use_mvcost);
+ const MV *center_mv, const aom_variance_fn_ptr_t *vfp,
+ int use_mvcost);
int av1_get_mvpred_av_var(const MACROBLOCK *x, const MV *best_mv,
- const MV *center_mv, const uint8_t *second_pred,
- const aom_variance_fn_ptr_t *vfp, int use_mvcost);
+ const MV *center_mv, const uint8_t *second_pred,
+ const aom_variance_fn_ptr_t *vfp, int use_mvcost);
struct AV1_COMP;
struct SPEED_FEATURES;
@@ -64,21 +64,21 @@
int av1_init_search_range(int size);
int av1_refining_search_sad(const struct macroblock *x, struct mv *ref_mv,
- int sad_per_bit, int distance,
- const struct aom_variance_vtable *fn_ptr,
- const struct mv *center_mv);
+ int sad_per_bit, int distance,
+ const struct aom_variance_vtable *fn_ptr,
+ const struct mv *center_mv);
// Runs sequence of diamond searches in smaller steps for RD.
int av1_full_pixel_diamond(const struct AV1_COMP *cpi, MACROBLOCK *x,
- MV *mvp_full, int step_param, int sadpb,
- int further_steps, int do_refine, int *cost_list,
- const aom_variance_fn_ptr_t *fn_ptr,
- const MV *ref_mv, MV *dst_mv);
+ MV *mvp_full, int step_param, int sadpb,
+ int further_steps, int do_refine, int *cost_list,
+ const aom_variance_fn_ptr_t *fn_ptr,
+ const MV *ref_mv, MV *dst_mv);
// Perform integral projection based motion estimation.
unsigned int av1_int_pro_motion_estimation(const struct AV1_COMP *cpi,
- MACROBLOCK *x, BLOCK_SIZE bsize,
- int mi_row, int mi_col);
+ MACROBLOCK *x, BLOCK_SIZE bsize,
+ int mi_row, int mi_col);
typedef int(integer_mv_pattern_search_fn)(const MACROBLOCK *x, MV *ref_mv,
int search_param, int error_per_bit,
@@ -107,31 +107,31 @@
extern fractional_mv_step_fp av1_find_best_sub_pixel_tree_pruned_evenmore;
typedef int (*av1_full_search_fn_t)(const MACROBLOCK *x, const MV *ref_mv,
- int sad_per_bit, int distance,
- const aom_variance_fn_ptr_t *fn_ptr,
- const MV *center_mv, MV *best_mv);
+ int sad_per_bit, int distance,
+ const aom_variance_fn_ptr_t *fn_ptr,
+ const MV *center_mv, MV *best_mv);
typedef int (*av1_refining_search_fn_t)(const MACROBLOCK *x, MV *ref_mv,
- int sad_per_bit, int distance,
- const aom_variance_fn_ptr_t *fn_ptr,
- const MV *center_mv);
+ int sad_per_bit, int distance,
+ const aom_variance_fn_ptr_t *fn_ptr,
+ const MV *center_mv);
typedef int (*av1_diamond_search_fn_t)(
const MACROBLOCK *x, const search_site_config *cfg, MV *ref_mv, MV *best_mv,
int search_param, int sad_per_bit, int *num00,
const aom_variance_fn_ptr_t *fn_ptr, const MV *center_mv);
-int av1_refining_search_8p_c(const MACROBLOCK *x, MV *ref_mv,
- int error_per_bit, int search_range,
- const aom_variance_fn_ptr_t *fn_ptr,
- const MV *center_mv, const uint8_t *second_pred);
+int av1_refining_search_8p_c(const MACROBLOCK *x, MV *ref_mv, int error_per_bit,
+ int search_range,
+ const aom_variance_fn_ptr_t *fn_ptr,
+ const MV *center_mv, const uint8_t *second_pred);
struct AV1_COMP;
-int av1_full_pixel_search(struct AV1_COMP *cpi, MACROBLOCK *x,
- BLOCK_SIZE bsize, MV *mvp_full, int step_param,
- int error_per_bit, int *cost_list, const MV *ref_mv,
- MV *tmp_mv, int var_max, int rd);
+int av1_full_pixel_search(struct AV1_COMP *cpi, MACROBLOCK *x, BLOCK_SIZE bsize,
+ MV *mvp_full, int step_param, int error_per_bit,
+ int *cost_list, const MV *ref_mv, MV *tmp_mv,
+ int var_max, int rd);
#ifdef __cplusplus
} // extern "C"
diff --git a/av1/encoder/picklpf.h b/av1/encoder/picklpf.h
index 44c9ee5..3d5c9a8 100644
--- a/av1/encoder/picklpf.h
+++ b/av1/encoder/picklpf.h
@@ -22,7 +22,7 @@
struct AV1_COMP;
void av1_pick_filter_level(const struct yv12_buffer_config *sd,
- struct AV1_COMP *cpi, LPF_PICK_METHOD method);
+ struct AV1_COMP *cpi, LPF_PICK_METHOD method);
#ifdef __cplusplus
} // extern "C"
#endif
diff --git a/av1/encoder/quantize.h b/av1/encoder/quantize.h
index c1d5810..3a46d06 100644
--- a/av1/encoder/quantize.h
+++ b/av1/encoder/quantize.h
@@ -40,7 +40,7 @@
} QUANTS;
void av1_regular_quantize_b_4x4(MACROBLOCK *x, int plane, int block,
- const int16_t *scan, const int16_t *iscan);
+ const int16_t *scan, const int16_t *iscan);
struct AV1_COMP;
struct AV1Common;
diff --git a/av1/encoder/ratectrl.h b/av1/encoder/ratectrl.h
index 3869312..b5fa338 100644
--- a/av1/encoder/ratectrl.h
+++ b/av1/encoder/ratectrl.h
@@ -149,18 +149,16 @@
struct AV1EncoderConfig;
void av1_rc_init(const struct AV1EncoderConfig *oxcf, int pass,
- RATE_CONTROL *rc);
+ RATE_CONTROL *rc);
int av1_estimate_bits_at_q(FRAME_TYPE frame_kind, int q, int mbs,
- double correction_factor,
- aom_bit_depth_t bit_depth);
+ double correction_factor, aom_bit_depth_t bit_depth);
double av1_convert_qindex_to_q(int qindex, aom_bit_depth_t bit_depth);
void av1_rc_init_minq_luts(void);
-int av1_rc_get_default_min_gf_interval(int width, int height,
- double framerate);
+int av1_rc_get_default_min_gf_interval(int width, int height, double framerate);
// Note av1_rc_get_default_max_gf_interval() requires the min_gf_interval to
// be passed in to ensure that the max_gf_interval returned is at least as bis
// as that.
@@ -208,27 +206,27 @@
// Computes frame size bounds.
void av1_rc_compute_frame_size_bounds(const struct AV1_COMP *cpi,
- int this_frame_target,
- int *frame_under_shoot_limit,
- int *frame_over_shoot_limit);
+ int this_frame_target,
+ int *frame_under_shoot_limit,
+ int *frame_over_shoot_limit);
// Picks q and q bounds given the target for bits
int av1_rc_pick_q_and_bounds(const struct AV1_COMP *cpi, int *bottom_index,
- int *top_index);
+ int *top_index);
// Estimates q to achieve a target bits per frame
int av1_rc_regulate_q(const struct AV1_COMP *cpi, int target_bits_per_frame,
- int active_best_quality, int active_worst_quality);
+ int active_best_quality, int active_worst_quality);
// Estimates bits per mb for a given qindex and correction factor.
int av1_rc_bits_per_mb(FRAME_TYPE frame_type, int qindex,
- double correction_factor, aom_bit_depth_t bit_depth);
+ double correction_factor, aom_bit_depth_t bit_depth);
// Clamping utilities for bitrate targets for iframes and pframes.
int av1_rc_clamp_iframe_target_size(const struct AV1_COMP *const cpi,
- int target);
+ int target);
int av1_rc_clamp_pframe_target_size(const struct AV1_COMP *const cpi,
- int target);
+ int target);
// Utility to set frame_target into the RATE_CONTROL structure
// This function is called only from the av1_rc_get_..._params() functions.
void av1_rc_set_frame_target(struct AV1_COMP *cpi, int target);
@@ -236,20 +234,20 @@
// Computes a q delta (in "q index" terms) to get from a starting q value
// to a target q value
int av1_compute_qdelta(const RATE_CONTROL *rc, double qstart, double qtarget,
- aom_bit_depth_t bit_depth);
+ aom_bit_depth_t bit_depth);
// Computes a q delta (in "q index" terms) to get from a starting q value
// to a value that should equate to the given rate ratio.
int av1_compute_qdelta_by_rate(const RATE_CONTROL *rc, FRAME_TYPE frame_type,
- int qindex, double rate_target_ratio,
- aom_bit_depth_t bit_depth);
+ int qindex, double rate_target_ratio,
+ aom_bit_depth_t bit_depth);
int av1_frame_type_qdelta(const struct AV1_COMP *cpi, int rf_level, int q);
void av1_rc_update_framerate(struct AV1_COMP *cpi);
void av1_rc_set_gf_interval_range(const struct AV1_COMP *const cpi,
- RATE_CONTROL *const rc);
+ RATE_CONTROL *const rc);
void av1_set_target_rate(struct AV1_COMP *cpi);
diff --git a/av1/encoder/rd.h b/av1/encoder/rd.h
index 40f4c99..46acf97 100644
--- a/av1/encoder/rd.h
+++ b/av1/encoder/rd.h
@@ -133,24 +133,22 @@
void av1_initialize_rd_consts(struct AV1_COMP *cpi);
-void av1_initialize_me_consts(struct AV1_COMP *cpi, MACROBLOCK *x,
- int qindex);
+void av1_initialize_me_consts(struct AV1_COMP *cpi, MACROBLOCK *x, int qindex);
void av1_model_rd_from_var_lapndz(unsigned int var, unsigned int n,
- unsigned int qstep, int *rate,
- int64_t *dist);
+ unsigned int qstep, int *rate, int64_t *dist);
int av1_get_switchable_rate(const struct AV1_COMP *cpi,
- const MACROBLOCKD *const xd);
+ const MACROBLOCKD *const xd);
int av1_raster_block_offset(BLOCK_SIZE plane_bsize, int raster_block,
- int stride);
+ int stride);
-int16_t *av1_raster_block_offset_int16(BLOCK_SIZE plane_bsize,
- int raster_block, int16_t *base);
+int16_t *av1_raster_block_offset_int16(BLOCK_SIZE plane_bsize, int raster_block,
+ int16_t *base);
YV12_BUFFER_CONFIG *av1_get_scaled_ref_frame(const struct AV1_COMP *cpi,
- int ref_frame);
+ int ref_frame);
void av1_init_me_luts(void);
@@ -159,16 +157,16 @@
#endif
void av1_get_entropy_contexts(BLOCK_SIZE bsize, TX_SIZE tx_size,
- const struct macroblockd_plane *pd,
- ENTROPY_CONTEXT t_above[16],
- ENTROPY_CONTEXT t_left[16]);
+ const struct macroblockd_plane *pd,
+ ENTROPY_CONTEXT t_above[16],
+ ENTROPY_CONTEXT t_left[16]);
void av1_set_rd_speed_thresholds(struct AV1_COMP *cpi);
void av1_set_rd_speed_thresholds_sub8x8(struct AV1_COMP *cpi);
-void av1_update_rd_thresh_fact(int (*fact)[MAX_MODES], int rd_thresh,
- int bsize, int best_mode_index);
+void av1_update_rd_thresh_fact(int (*fact)[MAX_MODES], int rd_thresh, int bsize,
+ int best_mode_index);
static INLINE int rd_less_than_thresh(int64_t best_rd, int thresh,
int thresh_fact) {
@@ -176,7 +174,7 @@
}
void av1_mv_pred(struct AV1_COMP *cpi, MACROBLOCK *x, uint8_t *ref_y_buffer,
- int ref_y_stride, int ref_frame, BLOCK_SIZE block_size);
+ int ref_y_stride, int ref_frame, BLOCK_SIZE block_size);
static INLINE void set_error_per_bit(MACROBLOCK *x, int rdmult) {
x->errorperbit = rdmult >> RD_EPB_SHIFT;
@@ -184,13 +182,13 @@
}
void av1_setup_pred_block(const MACROBLOCKD *xd,
- struct buf_2d dst[MAX_MB_PLANE],
- const YV12_BUFFER_CONFIG *src, int mi_row,
- int mi_col, const struct scale_factors *scale,
- const struct scale_factors *scale_uv);
+ struct buf_2d dst[MAX_MB_PLANE],
+ const YV12_BUFFER_CONFIG *src, int mi_row, int mi_col,
+ const struct scale_factors *scale,
+ const struct scale_factors *scale_uv);
int av1_get_intra_cost_penalty(int qindex, int qdelta,
- aom_bit_depth_t bit_depth);
+ aom_bit_depth_t bit_depth);
#ifdef __cplusplus
} // extern "C"
diff --git a/av1/encoder/rdopt.h b/av1/encoder/rdopt.h
index 6097b42..f319079 100644
--- a/av1/encoder/rdopt.h
+++ b/av1/encoder/rdopt.h
@@ -27,23 +27,23 @@
struct RD_COST;
void av1_rd_pick_intra_mode_sb(struct AV1_COMP *cpi, struct macroblock *x,
- struct RD_COST *rd_cost, BLOCK_SIZE bsize,
- PICK_MODE_CONTEXT *ctx, int64_t best_rd);
+ struct RD_COST *rd_cost, BLOCK_SIZE bsize,
+ PICK_MODE_CONTEXT *ctx, int64_t best_rd);
unsigned int av1_get_sby_perpixel_variance(AV1_COMP *cpi,
- const struct buf_2d *ref,
- BLOCK_SIZE bs);
+ const struct buf_2d *ref,
+ BLOCK_SIZE bs);
#if CONFIG_AOM_HIGHBITDEPTH
unsigned int av1_high_get_sby_perpixel_variance(AV1_COMP *cpi,
- const struct buf_2d *ref,
- BLOCK_SIZE bs, int bd);
+ const struct buf_2d *ref,
+ BLOCK_SIZE bs, int bd);
#endif
void av1_rd_pick_inter_mode_sb(struct AV1_COMP *cpi,
- struct TileDataEnc *tile_data,
- struct macroblock *x, int mi_row, int mi_col,
- struct RD_COST *rd_cost, BLOCK_SIZE bsize,
- PICK_MODE_CONTEXT *ctx, int64_t best_rd_so_far);
+ struct TileDataEnc *tile_data,
+ struct macroblock *x, int mi_row, int mi_col,
+ struct RD_COST *rd_cost, BLOCK_SIZE bsize,
+ PICK_MODE_CONTEXT *ctx, int64_t best_rd_so_far);
void av1_rd_pick_inter_mode_sb_seg_skip(
struct AV1_COMP *cpi, struct TileDataEnc *tile_data, struct macroblock *x,
@@ -56,11 +56,11 @@
int av1_active_edge_sb(struct AV1_COMP *cpi, int mi_row, int mi_col);
void av1_rd_pick_inter_mode_sub8x8(struct AV1_COMP *cpi,
- struct TileDataEnc *tile_data,
- struct macroblock *x, int mi_row,
- int mi_col, struct RD_COST *rd_cost,
- BLOCK_SIZE bsize, PICK_MODE_CONTEXT *ctx,
- int64_t best_rd_so_far);
+ struct TileDataEnc *tile_data,
+ struct macroblock *x, int mi_row, int mi_col,
+ struct RD_COST *rd_cost, BLOCK_SIZE bsize,
+ PICK_MODE_CONTEXT *ctx,
+ int64_t best_rd_so_far);
#ifdef __cplusplus
} // extern "C"
diff --git a/av1/encoder/resize.h b/av1/encoder/resize.h
index a7b02c7..4457262 100644
--- a/av1/encoder/resize.h
+++ b/av1/encoder/resize.h
@@ -20,46 +20,46 @@
#endif
void av1_resize_plane(const uint8_t *const input, int height, int width,
- int in_stride, uint8_t *output, int height2, int width2,
- int out_stride);
+ int in_stride, uint8_t *output, int height2, int width2,
+ int out_stride);
void av1_resize_frame420(const uint8_t *const y, int y_stride,
- const uint8_t *const u, const uint8_t *const v,
- int uv_stride, int height, int width, uint8_t *oy,
- int oy_stride, uint8_t *ou, uint8_t *ov,
- int ouv_stride, int oheight, int owidth);
+ const uint8_t *const u, const uint8_t *const v,
+ int uv_stride, int height, int width, uint8_t *oy,
+ int oy_stride, uint8_t *ou, uint8_t *ov,
+ int ouv_stride, int oheight, int owidth);
void av1_resize_frame422(const uint8_t *const y, int y_stride,
- const uint8_t *const u, const uint8_t *const v,
- int uv_stride, int height, int width, uint8_t *oy,
- int oy_stride, uint8_t *ou, uint8_t *ov,
- int ouv_stride, int oheight, int owidth);
+ const uint8_t *const u, const uint8_t *const v,
+ int uv_stride, int height, int width, uint8_t *oy,
+ int oy_stride, uint8_t *ou, uint8_t *ov,
+ int ouv_stride, int oheight, int owidth);
void av1_resize_frame444(const uint8_t *const y, int y_stride,
- const uint8_t *const u, const uint8_t *const v,
- int uv_stride, int height, int width, uint8_t *oy,
- int oy_stride, uint8_t *ou, uint8_t *ov,
- int ouv_stride, int oheight, int owidth);
+ const uint8_t *const u, const uint8_t *const v,
+ int uv_stride, int height, int width, uint8_t *oy,
+ int oy_stride, uint8_t *ou, uint8_t *ov,
+ int ouv_stride, int oheight, int owidth);
#if CONFIG_AOM_HIGHBITDEPTH
void av1_highbd_resize_plane(const uint8_t *const input, int height, int width,
- int in_stride, uint8_t *output, int height2,
- int width2, int out_stride, int bd);
+ int in_stride, uint8_t *output, int height2,
+ int width2, int out_stride, int bd);
void av1_highbd_resize_frame420(const uint8_t *const y, int y_stride,
- const uint8_t *const u, const uint8_t *const v,
- int uv_stride, int height, int width,
- uint8_t *oy, int oy_stride, uint8_t *ou,
- uint8_t *ov, int ouv_stride, int oheight,
- int owidth, int bd);
+ const uint8_t *const u, const uint8_t *const v,
+ int uv_stride, int height, int width,
+ uint8_t *oy, int oy_stride, uint8_t *ou,
+ uint8_t *ov, int ouv_stride, int oheight,
+ int owidth, int bd);
void av1_highbd_resize_frame422(const uint8_t *const y, int y_stride,
- const uint8_t *const u, const uint8_t *const v,
- int uv_stride, int height, int width,
- uint8_t *oy, int oy_stride, uint8_t *ou,
- uint8_t *ov, int ouv_stride, int oheight,
- int owidth, int bd);
+ const uint8_t *const u, const uint8_t *const v,
+ int uv_stride, int height, int width,
+ uint8_t *oy, int oy_stride, uint8_t *ou,
+ uint8_t *ov, int ouv_stride, int oheight,
+ int owidth, int bd);
void av1_highbd_resize_frame444(const uint8_t *const y, int y_stride,
- const uint8_t *const u, const uint8_t *const v,
- int uv_stride, int height, int width,
- uint8_t *oy, int oy_stride, uint8_t *ou,
- uint8_t *ov, int ouv_stride, int oheight,
- int owidth, int bd);
+ const uint8_t *const u, const uint8_t *const v,
+ int uv_stride, int height, int width,
+ uint8_t *oy, int oy_stride, uint8_t *ou,
+ uint8_t *ov, int ouv_stride, int oheight,
+ int owidth, int bd);
#endif // CONFIG_AOM_HIGHBITDEPTH
#ifdef __cplusplus
diff --git a/av1/encoder/segmentation.h b/av1/encoder/segmentation.h
index 418dac6..c1491ca 100644
--- a/av1/encoder/segmentation.h
+++ b/av1/encoder/segmentation.h
@@ -23,9 +23,9 @@
void av1_disable_segmentation(struct segmentation *seg);
void av1_disable_segfeature(struct segmentation *seg, int segment_id,
- SEG_LVL_FEATURES feature_id);
+ SEG_LVL_FEATURES feature_id);
void av1_clear_segdata(struct segmentation *seg, int segment_id,
- SEG_LVL_FEATURES feature_id);
+ SEG_LVL_FEATURES feature_id);
// The values given for each segment can be either deltas (from the default
// value chosen for the frame) or absolute values.
@@ -38,7 +38,7 @@
// abs_delta = SEGMENT_DELTADATA (deltas) abs_delta = SEGMENT_ABSDATA (use
// the absolute values given).
void av1_set_segment_data(struct segmentation *seg, signed char *feature_data,
- unsigned char abs_delta);
+ unsigned char abs_delta);
void av1_choose_segmap_coding_method(AV1_COMMON *cm, MACROBLOCKD *xd);
diff --git a/av1/encoder/subexp.h b/av1/encoder/subexp.h
index d8142ba..85732ee 100644
--- a/av1/encoder/subexp.h
+++ b/av1/encoder/subexp.h
@@ -21,21 +21,20 @@
struct aom_writer;
void av1_write_prob_diff_update(struct aom_writer *w, aom_prob newp,
- aom_prob oldp);
+ aom_prob oldp);
void av1_cond_prob_diff_update(struct aom_writer *w, aom_prob *oldp,
- const unsigned int ct[2]);
+ const unsigned int ct[2]);
int av1_prob_diff_update_savings_search(const unsigned int *ct, aom_prob oldp,
- aom_prob *bestp, aom_prob upd);
+ aom_prob *bestp, aom_prob upd);
int av1_prob_diff_update_savings_search_model(const unsigned int *ct,
- const aom_prob *oldp,
- aom_prob *bestp, aom_prob upd,
- int stepsize);
+ const aom_prob *oldp,
+ aom_prob *bestp, aom_prob upd,
+ int stepsize);
-int av1_cond_prob_diff_update_savings(aom_prob *oldp,
- const unsigned int ct[2]);
+int av1_cond_prob_diff_update_savings(aom_prob *oldp, const unsigned int ct[2]);
#ifdef __cplusplus
} // extern "C"
#endif
diff --git a/av1/encoder/tokenize.h b/av1/encoder/tokenize.h
index 3ab8193..6b4c5c1 100644
--- a/av1/encoder/tokenize.h
+++ b/av1/encoder/tokenize.h
@@ -52,7 +52,7 @@
struct ThreadData;
void av1_tokenize_sb(struct AV1_COMP *cpi, struct ThreadData *td,
- TOKENEXTRA **t, int dry_run, BLOCK_SIZE bsize);
+ TOKENEXTRA **t, int dry_run, BLOCK_SIZE bsize);
extern const int16_t *av1_dct_value_cost_ptr;
/* TODO: The Token field should be broken out into a separate char array to
@@ -66,7 +66,7 @@
extern const int av1_cat6_high10_high_cost[256];
extern const int av1_cat6_high12_high_cost[1024];
static INLINE int av1_get_cost(int16_t token, EXTRABIT extrabits,
- const int *cat6_high_table) {
+ const int *cat6_high_table) {
if (token != CATEGORY6_TOKEN)
return av1_extra_bits[token].cost[extrabits >> 1];
return av1_cat6_low_cost[(extrabits >> 1) & 0xff] +
@@ -86,8 +86,7 @@
}
#endif // CONFIG_AOM_HIGHBITDEPTH
-static INLINE void av1_get_token_extra(int v, int16_t *token,
- EXTRABIT *extra) {
+static INLINE void av1_get_token_extra(int v, int16_t *token, EXTRABIT *extra) {
if (v >= CAT6_MIN_VAL || v <= -CAT6_MIN_VAL) {
*token = CATEGORY6_TOKEN;
if (v >= CAT6_MIN_VAL)
diff --git a/av1/encoder/treewriter.h b/av1/encoder/treewriter.h
index 38ab5a6..533e7d9 100644
--- a/av1/encoder/treewriter.h
+++ b/av1/encoder/treewriter.h
@@ -19,8 +19,8 @@
#endif
void av1_tree_probs_from_distribution(aom_tree tree,
- unsigned int branch_ct[/* n - 1 */][2],
- const unsigned int num_events[/* n */]);
+ unsigned int branch_ct[/* n - 1 */][2],
+ const unsigned int num_events[/* n */]);
struct av1_token {
int value;
@@ -30,8 +30,8 @@
void av1_tokens_from_tree(struct av1_token *, const aom_tree_index *);
static INLINE void av1_write_tree(aom_writer *w, const aom_tree_index *tree,
- const aom_prob *probs, int bits, int len,
- aom_tree_index i) {
+ const aom_prob *probs, int bits, int len,
+ aom_tree_index i) {
do {
const int bit = (bits >> --len) & 1;
aom_write(w, bit, probs[i >> 1]);
@@ -40,8 +40,8 @@
}
static INLINE void av1_write_token(aom_writer *w, const aom_tree_index *tree,
- const aom_prob *probs,
- const struct av1_token *token) {
+ const aom_prob *probs,
+ const struct av1_token *token) {
av1_write_tree(w, tree, probs, token->value, token->len, 0);
}
diff --git a/test/active_map_refresh_test.cc b/test/active_map_refresh_test.cc
index 88b7a7e..5ec5987 100644
--- a/test/active_map_refresh_test.cc
+++ b/test/active_map_refresh_test.cc
@@ -124,6 +124,6 @@
}
AV1_INSTANTIATE_TEST_CASE(ActiveMapRefreshTest,
- ::testing::Values(::libaom_test::kRealTime),
- ::testing::Range(5, 6));
+ ::testing::Values(::libaom_test::kRealTime),
+ ::testing::Range(5, 6));
} // namespace
diff --git a/test/active_map_test.cc b/test/active_map_test.cc
index d29d3fb..42b45cc 100644
--- a/test/active_map_test.cc
+++ b/test/active_map_test.cc
@@ -82,6 +82,6 @@
}
AV1_INSTANTIATE_TEST_CASE(ActiveMapTest,
- ::testing::Values(::libaom_test::kRealTime),
- ::testing::Range(0, 6));
+ ::testing::Values(::libaom_test::kRealTime),
+ ::testing::Range(0, 6));
} // namespace
diff --git a/test/aq_segment_test.cc b/test/aq_segment_test.cc
index e74bf97..b81ea51 100644
--- a/test/aq_segment_test.cc
+++ b/test/aq_segment_test.cc
@@ -105,7 +105,7 @@
}
AV1_INSTANTIATE_TEST_CASE(AqSegmentTest,
- ::testing::Values(::libaom_test::kRealTime,
- ::libaom_test::kOnePassGood),
- ::testing::Range(3, 9));
+ ::testing::Values(::libaom_test::kRealTime,
+ ::libaom_test::kOnePassGood),
+ ::testing::Range(3, 9));
} // namespace
diff --git a/test/arf_freq_test.cc b/test/arf_freq_test.cc
index c734e53..d5f4623 100644
--- a/test/arf_freq_test.cc
+++ b/test/arf_freq_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include "third_party/googletest/src/include/gtest/gtest.h"
#include "test/codec_factory.h"
@@ -218,14 +217,14 @@
INSTANTIATE_TEST_CASE_P(
DISABLED_AV1, ArfFreqTest,
::testing::Combine(
- ::testing::Values(static_cast<const libaom_test::CodecFactory *>(
- &libaom_test::kAV1)),
+ ::testing::Values(
+ static_cast<const libaom_test::CodecFactory *>(&libaom_test::kAV1)),
::testing::ValuesIn(kTestVectors), ::testing::ValuesIn(kEncodeVectors),
::testing::ValuesIn(kMinArfVectors)));
#endif // CONFIG_AV1_ENCODER
#else
AV1_INSTANTIATE_TEST_CASE(ArfFreqTest, ::testing::ValuesIn(kTestVectors),
- ::testing::ValuesIn(kEncodeVectors),
- ::testing::ValuesIn(kMinArfVectors));
+ ::testing::ValuesIn(kEncodeVectors),
+ ::testing::ValuesIn(kMinArfVectors));
#endif // CONFIG_AOM_HIGHBITDEPTH
} // namespace
diff --git a/test/av1_dct_test.cc b/test/av1_dct_test.cc
index 5e079a7..79280dd 100644
--- a/test/av1_dct_test.cc
+++ b/test/av1_dct_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <math.h>
#include <stdlib.h>
#include <new>
@@ -87,7 +86,7 @@
typedef std::tr1::tuple<FdctFunc, FdctFuncRef, int, int> FdctParam;
class AV1FwdTxfm : public TransTestBase,
- public ::testing::TestWithParam<FdctParam> {
+ public ::testing::TestWithParam<FdctParam> {
public:
virtual void SetUp() {
fwd_txfm_ = GET_PARAM(0);
diff --git a/test/av1_inv_txfm_test.cc b/test/av1_inv_txfm_test.cc
index 9c432cf..c46ab29 100644
--- a/test/av1_inv_txfm_test.cc
+++ b/test/av1_inv_txfm_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <math.h>
#include <stdlib.h>
#include <string.h>
@@ -91,7 +90,7 @@
typedef std::tr1::tuple<IdctFunc, IdctFuncRef, int, int> IdctParam;
class AV1InvTxfm : public TransTestBase,
- public ::testing::TestWithParam<IdctParam> {
+ public ::testing::TestWithParam<IdctParam> {
public:
virtual void SetUp() {
fwd_txfm_ = GET_PARAM(0);
diff --git a/test/avg_test.cc b/test/avg_test.cc
index 954cd94..40dd086 100644
--- a/test/avg_test.cc
+++ b/test/avg_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <limits.h>
#include <stdio.h>
#include <string.h>
diff --git a/test/boolcoder_test.cc b/test/boolcoder_test.cc
index bb360a3..87b3b4b 100644
--- a/test/boolcoder_test.cc
+++ b/test/boolcoder_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <math.h>
#include <stdlib.h>
#include <string.h>
diff --git a/test/borders_test.cc b/test/borders_test.cc
index 27bce57..2bfcbd7 100644
--- a/test/borders_test.cc
+++ b/test/borders_test.cc
@@ -82,5 +82,5 @@
}
AV1_INSTANTIATE_TEST_CASE(BordersTest,
- ::testing::Values(::libaom_test::kTwoPassGood));
+ ::testing::Values(::libaom_test::kTwoPassGood));
} // namespace
diff --git a/test/codec_factory.h b/test/codec_factory.h
index 1c5718e..c88dcd2 100644
--- a/test/codec_factory.h
+++ b/test/codec_factory.h
@@ -79,7 +79,7 @@
: Decoder(cfg, deadline) {}
AV1Decoder(aom_codec_dec_cfg_t cfg, const aom_codec_flags_t flag,
- unsigned long deadline) // NOLINT
+ unsigned long deadline) // NOLINT
: Decoder(cfg, flag, deadline) {}
protected:
@@ -95,7 +95,7 @@
class AV1Encoder : public Encoder {
public:
AV1Encoder(aom_codec_enc_cfg_t cfg, unsigned long deadline,
- const unsigned long init_flags, TwopassStatsStore* stats)
+ const unsigned long init_flags, TwopassStatsStore* stats)
: Encoder(cfg, deadline, init_flags, stats) {}
protected:
@@ -150,12 +150,12 @@
const libaom_test::AV1CodecFactory kAV1;
-#define AV1_INSTANTIATE_TEST_CASE(test, ...) \
+#define AV1_INSTANTIATE_TEST_CASE(test, ...) \
INSTANTIATE_TEST_CASE_P( \
- AV1, test, \
+ AV1, test, \
::testing::Combine( \
::testing::Values(static_cast<const libaom_test::CodecFactory*>( \
- &libaom_test::kAV1)), \
+ &libaom_test::kAV1)), \
__VA_ARGS__))
#else
#define AV1_INSTANTIATE_TEST_CASE(test, ...)
diff --git a/test/convolve_test.cc b/test/convolve_test.cc
index b082e53..12142c4 100644
--- a/test/convolve_test.cc
+++ b/test/convolve_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <string.h>
#include "third_party/googletest/src/include/gtest/gtest.h"
diff --git a/test/cpu_speed_test.cc b/test/cpu_speed_test.cc
index e4c7523..f09880d 100644
--- a/test/cpu_speed_test.cc
+++ b/test/cpu_speed_test.cc
@@ -133,7 +133,7 @@
}
AV1_INSTANTIATE_TEST_CASE(CpuSpeedTest,
- ::testing::Values(::libaom_test::kTwoPassGood,
- ::libaom_test::kOnePassGood),
- ::testing::Range(0, 3));
+ ::testing::Values(::libaom_test::kTwoPassGood,
+ ::libaom_test::kOnePassGood),
+ ::testing::Range(0, 3));
} // namespace
diff --git a/test/datarate_test.cc b/test/datarate_test.cc
index 05c0946..c4b0e10 100644
--- a/test/datarate_test.cc
+++ b/test/datarate_test.cc
@@ -897,9 +897,9 @@
}
AV1_INSTANTIATE_TEST_CASE(DatarateTestAV1Large,
- ::testing::Values(::libaom_test::kOnePassGood,
- ::libaom_test::kRealTime),
- ::testing::Range(2, 7));
+ ::testing::Values(::libaom_test::kOnePassGood,
+ ::libaom_test::kRealTime),
+ ::testing::Range(2, 7));
/* AV1 does not support multiple layers yet.
AV1_INSTANTIATE_TEST_CASE(DatarateOnePassCbrSvc,
diff --git a/test/dct16x16_test.cc b/test/dct16x16_test.cc
index fb754e0..64f912a 100644
--- a/test/dct16x16_test.cc
+++ b/test/dct16x16_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <math.h>
#include <stdlib.h>
#include <string.h>
@@ -806,14 +805,14 @@
&aom_idct16x16_256_add_sse2, 0, AOM_BITS_8)));
INSTANTIATE_TEST_CASE_P(
SSE2, Trans16x16HT,
- ::testing::Values(make_tuple(&av1_fht16x16_sse2,
- &av1_iht16x16_256_add_sse2, 0, AOM_BITS_8),
- make_tuple(&av1_fht16x16_sse2,
- &av1_iht16x16_256_add_sse2, 1, AOM_BITS_8),
- make_tuple(&av1_fht16x16_sse2,
- &av1_iht16x16_256_add_sse2, 2, AOM_BITS_8),
- make_tuple(&av1_fht16x16_sse2,
- &av1_iht16x16_256_add_sse2, 3, AOM_BITS_8)));
+ ::testing::Values(make_tuple(&av1_fht16x16_sse2, &av1_iht16x16_256_add_sse2,
+ 0, AOM_BITS_8),
+ make_tuple(&av1_fht16x16_sse2, &av1_iht16x16_256_add_sse2,
+ 1, AOM_BITS_8),
+ make_tuple(&av1_fht16x16_sse2, &av1_iht16x16_256_add_sse2,
+ 2, AOM_BITS_8),
+ make_tuple(&av1_fht16x16_sse2, &av1_iht16x16_256_add_sse2,
+ 3, AOM_BITS_8)));
#endif // HAVE_SSE2 && !CONFIG_AOM_HIGHBITDEPTH && !CONFIG_EMULATE_HARDWARE
#if HAVE_SSE2 && CONFIG_AOM_HIGHBITDEPTH && !CONFIG_EMULATE_HARDWARE
@@ -830,14 +829,12 @@
AOM_BITS_8)));
INSTANTIATE_TEST_CASE_P(
SSE2, Trans16x16HT,
- ::testing::Values(make_tuple(&av1_fht16x16_sse2, &av1_iht16x16_256_add_c,
- 0, AOM_BITS_8),
- make_tuple(&av1_fht16x16_sse2, &av1_iht16x16_256_add_c,
- 1, AOM_BITS_8),
- make_tuple(&av1_fht16x16_sse2, &av1_iht16x16_256_add_c,
- 2, AOM_BITS_8),
- make_tuple(&av1_fht16x16_sse2, &av1_iht16x16_256_add_c,
- 3, AOM_BITS_8)));
+ ::testing::Values(
+ make_tuple(&av1_fht16x16_sse2, &av1_iht16x16_256_add_c, 0, AOM_BITS_8),
+ make_tuple(&av1_fht16x16_sse2, &av1_iht16x16_256_add_c, 1, AOM_BITS_8),
+ make_tuple(&av1_fht16x16_sse2, &av1_iht16x16_256_add_c, 2, AOM_BITS_8),
+ make_tuple(&av1_fht16x16_sse2, &av1_iht16x16_256_add_c, 3,
+ AOM_BITS_8)));
// Optimizations take effect at a threshold of 3155, so we use a value close to
// that to test both branches.
INSTANTIATE_TEST_CASE_P(
@@ -859,13 +856,11 @@
0, AOM_BITS_8)));
INSTANTIATE_TEST_CASE_P(
MSA, Trans16x16HT,
- ::testing::Values(make_tuple(&av1_fht16x16_msa, &av1_iht16x16_256_add_msa,
- 0, AOM_BITS_8),
- make_tuple(&av1_fht16x16_msa, &av1_iht16x16_256_add_msa,
- 1, AOM_BITS_8),
- make_tuple(&av1_fht16x16_msa, &av1_iht16x16_256_add_msa,
- 2, AOM_BITS_8),
- make_tuple(&av1_fht16x16_msa, &av1_iht16x16_256_add_msa,
- 3, AOM_BITS_8)));
+ ::testing::Values(
+ make_tuple(&av1_fht16x16_msa, &av1_iht16x16_256_add_msa, 0, AOM_BITS_8),
+ make_tuple(&av1_fht16x16_msa, &av1_iht16x16_256_add_msa, 1, AOM_BITS_8),
+ make_tuple(&av1_fht16x16_msa, &av1_iht16x16_256_add_msa, 2, AOM_BITS_8),
+ make_tuple(&av1_fht16x16_msa, &av1_iht16x16_256_add_msa, 3,
+ AOM_BITS_8)));
#endif // HAVE_MSA && !CONFIG_AOM_HIGHBITDEPTH && !CONFIG_EMULATE_HARDWARE
} // namespace
diff --git a/test/dct32x32_test.cc b/test/dct32x32_test.cc
index 56c6777..e2ca5c7 100644
--- a/test/dct32x32_test.cc
+++ b/test/dct32x32_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <math.h>
#include <stdlib.h>
#include <string.h>
diff --git a/test/decode_api_test.cc b/test/decode_api_test.cc
index b1adee4..d62fced 100644
--- a/test/decode_api_test.cc
+++ b/test/decode_api_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include "third_party/googletest/src/include/gtest/gtest.h"
#include "./aom_config.h"
diff --git a/test/decode_perf_test.cc b/test/decode_perf_test.cc
index 0a1f67d..7035e30 100644
--- a/test/decode_perf_test.cc
+++ b/test/decode_perf_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <string>
#include "test/codec_factory.h"
#include "test/decode_test_driver.h"
@@ -258,5 +257,5 @@
}
AV1_INSTANTIATE_TEST_CASE(AV1NewEncodeDecodePerfTest,
- ::testing::Values(::libaom_test::kTwoPassGood));
+ ::testing::Values(::libaom_test::kTwoPassGood));
} // namespace
diff --git a/test/decode_test_driver.cc b/test/decode_test_driver.cc
index 59fabb9..529f75f 100644
--- a/test/decode_test_driver.cc
+++ b/test/decode_test_driver.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include "third_party/googletest/src/include/gtest/gtest.h"
#include "test/codec_factory.h"
diff --git a/test/denoiser_sse2_test.cc b/test/denoiser_sse2_test.cc
index c60c828..bf0bdcd 100644
--- a/test/denoiser_sse2_test.cc
+++ b/test/denoiser_sse2_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <math.h>
#include <stdlib.h>
#include <string.h>
diff --git a/test/divu_small_test.cc b/test/divu_small_test.cc
index be37f57..ea6da47 100644
--- a/test/divu_small_test.cc
+++ b/test/divu_small_test.cc
@@ -34,8 +34,9 @@
TEST(Daala, TestDIVUuptoMAX) {
for (int d = 1; d <= OD_DIVU_DMAX; d++) {
for (uint32_t x = 1; x <= 1000000; x++) {
- GTEST_ASSERT_EQ(x/d, OD_DIVU_SMALL(x, d)) << "x=" << x << " d=" << d <<
- " x/d=" << (x/d) << " != " << OD_DIVU_SMALL(x, d);
+ GTEST_ASSERT_EQ(x / d, OD_DIVU_SMALL(x, d))
+ << "x=" << x << " d=" << d << " x/d=" << (x / d)
+ << " != " << OD_DIVU_SMALL(x, d);
}
}
}
@@ -45,8 +46,9 @@
for (int d = 1; d < OD_DIVU_DMAX; d++) {
for (int i = 0; i < 1000000; i++) {
uint32_t x = rnd.Rand31();
- GTEST_ASSERT_EQ(x/d, OD_DIVU_SMALL(x, d)) << "x=" << x << " d=" << d <<
- " x/d=" << (x/d) << " != " << OD_DIVU_SMALL(x, d);
+ GTEST_ASSERT_EQ(x / d, OD_DIVU_SMALL(x, d))
+ << "x=" << x << " d=" << d << " x/d=" << (x / d)
+ << " != " << OD_DIVU_SMALL(x, d);
}
}
}
diff --git a/test/encode_api_test.cc b/test/encode_api_test.cc
index f0d6eb1..49fac27 100644
--- a/test/encode_api_test.cc
+++ b/test/encode_api_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include "third_party/googletest/src/include/gtest/gtest.h"
#include "./aom_config.h"
diff --git a/test/encode_perf_test.cc b/test/encode_perf_test.cc
index f269b9b..732e2a1 100644
--- a/test/encode_perf_test.cc
+++ b/test/encode_perf_test.cc
@@ -185,5 +185,5 @@
}
AV1_INSTANTIATE_TEST_CASE(AV1EncodePerfTest,
- ::testing::Values(::libaom_test::kRealTime));
+ ::testing::Values(::libaom_test::kRealTime));
} // namespace
diff --git a/test/encode_test_driver.cc b/test/encode_test_driver.cc
index 0261780..d9fd88f 100644
--- a/test/encode_test_driver.cc
+++ b/test/encode_test_driver.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <string>
#include "third_party/googletest/src/include/gtest/gtest.h"
diff --git a/test/encoder_parms_get_to_decoder.cc b/test/encoder_parms_get_to_decoder.cc
index 9da13f8..74fb3f3 100644
--- a/test/encoder_parms_get_to_decoder.cc
+++ b/test/encoder_parms_get_to_decoder.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include "third_party/googletest/src/include/gtest/gtest.h"
#include "test/codec_factory.h"
@@ -146,6 +145,6 @@
}
AV1_INSTANTIATE_TEST_CASE(AvxEncoderParmsGetToDecoder,
- ::testing::ValuesIn(kAV1EncodeParameterSet),
- ::testing::ValuesIn(kAV1EncodePerfTestVectors));
+ ::testing::ValuesIn(kAV1EncodeParameterSet),
+ ::testing::ValuesIn(kAV1EncodePerfTestVectors));
} // namespace
diff --git a/test/end_to_end_test.cc b/test/end_to_end_test.cc
index 1623087..49853f2 100644
--- a/test/end_to_end_test.cc
+++ b/test/end_to_end_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include "third_party/googletest/src/include/gtest/gtest.h"
#include "test/codec_factory.h"
@@ -177,16 +176,16 @@
INSTANTIATE_TEST_CASE_P(
DISABLED_AV1, EndToEndTestLarge,
::testing::Combine(
- ::testing::Values(static_cast<const libaom_test::CodecFactory *>(
- &libaom_test::kAV1)),
+ ::testing::Values(
+ static_cast<const libaom_test::CodecFactory *>(&libaom_test::kAV1)),
::testing::ValuesIn(kEncodingModeVectors),
::testing::ValuesIn(kTestVectors),
::testing::ValuesIn(kCpuUsedVectors)));
#endif // CONFIG_AV1_ENCODER
#else
AV1_INSTANTIATE_TEST_CASE(EndToEndTestLarge,
- ::testing::ValuesIn(kEncodingModeVectors),
- ::testing::ValuesIn(kTestVectors),
- ::testing::ValuesIn(kCpuUsedVectors));
+ ::testing::ValuesIn(kEncodingModeVectors),
+ ::testing::ValuesIn(kTestVectors),
+ ::testing::ValuesIn(kCpuUsedVectors));
#endif // CONFIG_AOM_HIGHBITDEPTH
} // namespace
diff --git a/test/error_block_test.cc b/test/error_block_test.cc
index 0233ffc..b5b0e8c 100644
--- a/test/error_block_test.cc
+++ b/test/error_block_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <cmath>
#include <cstdlib>
#include <string>
@@ -161,18 +160,18 @@
#if CONFIG_USE_X86INC
int64_t wrap_av1_highbd_block_error_8bit_c(const tran_low_t *coeff,
- const tran_low_t *dqcoeff,
- intptr_t block_size, int64_t *ssz,
- int bps) {
+ const tran_low_t *dqcoeff,
+ intptr_t block_size, int64_t *ssz,
+ int bps) {
assert(bps == 8);
return av1_highbd_block_error_8bit_c(coeff, dqcoeff, block_size, ssz);
}
#if HAVE_SSE2
int64_t wrap_av1_highbd_block_error_8bit_sse2(const tran_low_t *coeff,
- const tran_low_t *dqcoeff,
- intptr_t block_size,
- int64_t *ssz, int bps) {
+ const tran_low_t *dqcoeff,
+ intptr_t block_size, int64_t *ssz,
+ int bps) {
assert(bps == 8);
return av1_highbd_block_error_8bit_sse2(coeff, dqcoeff, block_size, ssz);
}
@@ -192,9 +191,9 @@
#if HAVE_AVX
int64_t wrap_av1_highbd_block_error_8bit_avx(const tran_low_t *coeff,
- const tran_low_t *dqcoeff,
- intptr_t block_size, int64_t *ssz,
- int bps) {
+ const tran_low_t *dqcoeff,
+ intptr_t block_size, int64_t *ssz,
+ int bps) {
assert(bps == 8);
return av1_highbd_block_error_8bit_avx(coeff, dqcoeff, block_size, ssz);
}
diff --git a/test/error_resilience_test.cc b/test/error_resilience_test.cc
index 6cfdf40..15c2dfb 100644
--- a/test/error_resilience_test.cc
+++ b/test/error_resilience_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include "third_party/googletest/src/include/gtest/gtest.h"
#include "test/codec_factory.h"
#include "test/encode_test_driver.h"
@@ -574,5 +573,5 @@
// SVC-related tests don't run for AV1 since SVC is not supported.
AV1_INSTANTIATE_TEST_CASE(ErrorResilienceTestLarge, ONE_PASS_TEST_MODES,
- ::testing::Values(false));
+ ::testing::Values(false));
} // namespace
diff --git a/test/ethread_test.cc b/test/ethread_test.cc
index e0ef7db..57aef6f 100644
--- a/test/ethread_test.cc
+++ b/test/ethread_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <string>
#include <vector>
#include "third_party/googletest/src/include/gtest/gtest.h"
@@ -127,7 +126,7 @@
}
AV1_INSTANTIATE_TEST_CASE(AVxEncoderThreadTest,
- ::testing::Values(::libaom_test::kTwoPassGood,
- ::libaom_test::kOnePassGood),
- ::testing::Range(1, 3));
+ ::testing::Values(::libaom_test::kTwoPassGood,
+ ::libaom_test::kOnePassGood),
+ ::testing::Range(1, 3));
} // namespace
diff --git a/test/fdct4x4_test.cc b/test/fdct4x4_test.cc
index 0c32ad6..00c7989 100644
--- a/test/fdct4x4_test.cc
+++ b/test/fdct4x4_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <math.h>
#include <stdlib.h>
#include <string.h>
@@ -481,8 +480,7 @@
make_tuple(&av1_fht4x4_sse2, &av1_iht4x4_16_add_sse2, 0, AOM_BITS_8),
make_tuple(&av1_fht4x4_sse2, &av1_iht4x4_16_add_sse2, 1, AOM_BITS_8),
make_tuple(&av1_fht4x4_sse2, &av1_iht4x4_16_add_sse2, 2, AOM_BITS_8),
- make_tuple(&av1_fht4x4_sse2, &av1_iht4x4_16_add_sse2, 3,
- AOM_BITS_8)));
+ make_tuple(&av1_fht4x4_sse2, &av1_iht4x4_16_add_sse2, 3, AOM_BITS_8)));
#endif // HAVE_SSE2 && !CONFIG_AOM_HIGHBITDEPTH && !CONFIG_EMULATE_HARDWARE
#if HAVE_SSE2 && CONFIG_AOM_HIGHBITDEPTH && !CONFIG_EMULATE_HARDWARE
diff --git a/test/fdct8x8_test.cc b/test/fdct8x8_test.cc
index bc939d0..dffc306 100644
--- a/test/fdct8x8_test.cc
+++ b/test/fdct8x8_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <math.h>
#include <stdlib.h>
#include <string.h>
@@ -690,8 +689,7 @@
make_tuple(&av1_fht8x8_sse2, &av1_iht8x8_64_add_sse2, 0, AOM_BITS_8),
make_tuple(&av1_fht8x8_sse2, &av1_iht8x8_64_add_sse2, 1, AOM_BITS_8),
make_tuple(&av1_fht8x8_sse2, &av1_iht8x8_64_add_sse2, 2, AOM_BITS_8),
- make_tuple(&av1_fht8x8_sse2, &av1_iht8x8_64_add_sse2, 3,
- AOM_BITS_8)));
+ make_tuple(&av1_fht8x8_sse2, &av1_iht8x8_64_add_sse2, 3, AOM_BITS_8)));
#endif // HAVE_SSE2 && !CONFIG_AOM_HIGHBITDEPTH && !CONFIG_EMULATE_HARDWARE
#if HAVE_SSE2 && CONFIG_AOM_HIGHBITDEPTH && !CONFIG_EMULATE_HARDWARE
diff --git a/test/idct8x8_test.cc b/test/idct8x8_test.cc
index 1feca58..b0c5b48 100644
--- a/test/idct8x8_test.cc
+++ b/test/idct8x8_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <math.h>
#include <stdlib.h>
#include <string.h>
diff --git a/test/idct_test.cc b/test/idct_test.cc
index 0d0f1aa..009f4b0 100644
--- a/test/idct_test.cc
+++ b/test/idct_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include "./aom_config.h"
#include "./aom_rtcd.h"
diff --git a/test/intrapred_test.cc b/test/intrapred_test.cc
index 8a321fb..ad65bee 100644
--- a/test/intrapred_test.cc
+++ b/test/intrapred_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <string>
#include "third_party/googletest/src/include/gtest/gtest.h"
diff --git a/test/lossless_test.cc b/test/lossless_test.cc
index 0408477..bc492b4 100644
--- a/test/lossless_test.cc
+++ b/test/lossless_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include "third_party/googletest/src/include/gtest/gtest.h"
#include "./aom_config.h"
@@ -121,6 +120,6 @@
}
AV1_INSTANTIATE_TEST_CASE(LosslessTest,
- ::testing::Values(::libaom_test::kOnePassGood,
- ::libaom_test::kTwoPassGood));
+ ::testing::Values(::libaom_test::kOnePassGood,
+ ::libaom_test::kTwoPassGood));
} // namespace
diff --git a/test/lpf_8_test.cc b/test/lpf_8_test.cc
index ffab935..e42494c 100644
--- a/test/lpf_8_test.cc
+++ b/test/lpf_8_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <cmath>
#include <cstdlib>
#include <string>
diff --git a/test/partial_idct_test.cc b/test/partial_idct_test.cc
index 130d4ad..adb151e 100644
--- a/test/partial_idct_test.cc
+++ b/test/partial_idct_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <math.h>
#include <stdlib.h>
#include <string.h>
diff --git a/test/quantize_test.cc b/test/quantize_test.cc
index ddf1e05..c72dd2d 100644
--- a/test/quantize_test.cc
+++ b/test/quantize_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <math.h>
#include <stdlib.h>
#include <string.h>
diff --git a/test/resize_test.cc b/test/resize_test.cc
index 400ccb0..a36c18e 100644
--- a/test/resize_test.cc
+++ b/test/resize_test.cc
@@ -527,12 +527,12 @@
}
AV1_INSTANTIATE_TEST_CASE(ResizeTest,
- ::testing::Values(::libaom_test::kRealTime));
+ ::testing::Values(::libaom_test::kRealTime));
AV1_INSTANTIATE_TEST_CASE(ResizeInternalTest,
- ::testing::Values(::libaom_test::kOnePassBest));
+ ::testing::Values(::libaom_test::kOnePassBest));
AV1_INSTANTIATE_TEST_CASE(ResizeRealtimeTest,
- ::testing::Values(::libaom_test::kRealTime),
- ::testing::Range(5, 9));
+ ::testing::Values(::libaom_test::kRealTime),
+ ::testing::Range(5, 9));
AV1_INSTANTIATE_TEST_CASE(ResizeCspTest,
- ::testing::Values(::libaom_test::kRealTime));
+ ::testing::Values(::libaom_test::kRealTime));
} // namespace
diff --git a/test/sad_test.cc b/test/sad_test.cc
index 7e39ee8..1064667 100644
--- a/test/sad_test.cc
+++ b/test/sad_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <string.h>
#include <limits.h>
#include <stdio.h>
diff --git a/test/subtract_test.cc b/test/subtract_test.cc
index 6d3eb6e..1a45ebf 100644
--- a/test/subtract_test.cc
+++ b/test/subtract_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include "third_party/googletest/src/include/gtest/gtest.h"
#include "./av1_rtcd.h"
diff --git a/test/superframe_test.cc b/test/superframe_test.cc
index d0c7371..ec0d9fe 100644
--- a/test/superframe_test.cc
+++ b/test/superframe_test.cc
@@ -59,8 +59,7 @@
const uint8_t marker = buffer[pkt->data.frame.sz - 1];
const int frames = (marker & 0x7) + 1;
const int mag = ((marker >> 3) & 3) + 1;
- const unsigned int index_sz =
- 2 + mag * (frames - is_av1_style_superframe_);
+ const unsigned int index_sz = 2 + mag * (frames - is_av1_style_superframe_);
if ((marker & 0xe0) == 0xc0 && pkt->data.frame.sz >= index_sz &&
buffer[pkt->data.frame.sz - index_sz] == marker) {
// frame is a superframe. strip off the index.
diff --git a/test/svc_test.cc b/test/svc_test.cc
index 7d1e4b3..44f0be2 100644
--- a/test/svc_test.cc
+++ b/test/svc_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <string>
#include "third_party/googletest/src/include/gtest/gtest.h"
#include "test/codec_factory.h"
diff --git a/test/tile_independence_test.cc b/test/tile_independence_test.cc
index 113f820..3602f70 100644
--- a/test/tile_independence_test.cc
+++ b/test/tile_independence_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <cstdio>
#include <cstdlib>
#include <string>
diff --git a/test/variance_test.cc b/test/variance_test.cc
index c677f38..57cee7d 100644
--- a/test/variance_test.cc
+++ b/test/variance_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <cstdlib>
#include <new>
diff --git a/test/y4m_test.cc b/test/y4m_test.cc
index 32897f5..c4755f7 100644
--- a/test/y4m_test.cc
+++ b/test/y4m_test.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include <string>
#include "third_party/googletest/src/include/gtest/gtest.h"
diff --git a/webmdec.cc b/webmdec.cc
index 924a493..da5c05b 100644
--- a/webmdec.cc
+++ b/webmdec.cc
@@ -9,7 +9,6 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/
-
#include "./webmdec.h"
#include <cstring>