#ifndef AOM_AV1_ENCODER_GLOBAL_MOTION_H_
#define AOM_AV1_ENCODER_GLOBAL_MOTION_H_
#include "aom/aom_integer.h"
#include "aom_dsp/flow_estimation/flow_estimation.h"
#include "aom_util/aom_pthread.h"
#include "av1/encoder/enc_enums.h"
#ifdef __cplusplus
extern "C" {
#endif
#define RANSAC_NUM_MOTIONS …
#define GM_MAX_REFINEMENT_STEPS …
#define MAX_DIRECTIONS …
FrameDistPair;
GlobalMotionData;
GlobalMotionJobInfo;
AV1GlobalMotionSync;
void av1_convert_model_to_params(const double *params,
WarpedMotionParams *model);
static const double erroradv_tr = …;
static const double erroradv_prod_tr = …;
static const double erroradv_early_tr = …;
int av1_is_enough_erroradvantage(double best_erroradvantage, int params_cost);
void av1_compute_feature_segmentation_map(uint8_t *segment_map, int width,
int height, int *inliers,
int num_inliers);
int64_t av1_segmented_frame_error(int use_hbd, int bd, const uint8_t *ref,
int ref_stride, uint8_t *dst, int dst_stride,
int p_width, int p_height,
uint8_t *segment_map, int segment_map_stride);
int64_t av1_warp_error(WarpedMotionParams *wm, int use_hbd, int bd,
const uint8_t *ref, int ref_width, int ref_height,
int ref_stride, uint8_t *dst, int dst_stride, int p_col,
int p_row, int p_width, int p_height, int subsampling_x,
int subsampling_y, int64_t best_error,
uint8_t *segment_map, int segment_map_stride);
int64_t av1_refine_integerized_param(
WarpedMotionParams *wm, TransformationType wmtype, int use_hbd, int bd,
uint8_t *ref, int r_width, int r_height, int r_stride, uint8_t *dst,
int d_width, int d_height, int d_stride, int n_refinements,
int64_t ref_frame_error, uint8_t *segment_map, int segment_map_stride);
#ifdef __cplusplus
}
#endif
#endif