blob: 8689cec27c3f1853c06981964b2802e7aaad6a4b [file] [log] [blame]
Yaowu Xuc27fc142016-08-22 16:08:15 -07001/*
Yaowu Xu2ab7ff02016-09-02 12:04:54 -07002 * Copyright (c) 2016, Alliance for Open Media. All rights reserved
Yaowu Xuc27fc142016-08-22 16:08:15 -07003 *
Yaowu Xu2ab7ff02016-09-02 12:04:54 -07004 * This source code is subject to the terms of the BSD 2 Clause License and
5 * the Alliance for Open Media Patent License 1.0. If the BSD 2 Clause License
6 * was not distributed with this source code in the LICENSE file, you can
7 * obtain it at www.aomedia.org/license/software. If the Alliance for Open
8 * Media Patent License 1.0 was not distributed with this source code in the
9 * PATENTS file, you can obtain it at www.aomedia.org/license/patent.
Yaowu Xuc27fc142016-08-22 16:08:15 -070010 */
11
Yaowu Xuf883b422016-08-30 14:01:10 -070012#ifndef AV1_ENCODER_ENCODEMV_H_
13#define AV1_ENCODER_ENCODEMV_H_
Yaowu Xuc27fc142016-08-22 16:08:15 -070014
15#include "av1/encoder/encoder.h"
16
17#ifdef __cplusplus
18extern "C" {
19#endif
20
Yaowu Xuf883b422016-08-30 14:01:10 -070021void av1_entropy_mv_init(void);
Yaowu Xuc27fc142016-08-22 16:08:15 -070022
Thomas Davies599395e2017-07-21 18:02:48 +010023#if !CONFIG_NEW_MULTISYMBOL
Jingning Hanfd0cf162016-09-30 10:33:50 -070024void av1_write_nmv_probs(AV1_COMMON *cm, int usehp, aom_writer *w,
Yaowu Xuf883b422016-08-30 14:01:10 -070025 nmv_context_counts *const counts);
Thomas Davies599395e2017-07-21 18:02:48 +010026#endif
Yaowu Xuc27fc142016-08-22 16:08:15 -070027
Yaowu Xuf883b422016-08-30 14:01:10 -070028void av1_encode_mv(AV1_COMP *cpi, aom_writer *w, const MV *mv, const MV *ref,
Thomas9ac55082016-09-23 18:04:17 +010029 nmv_context *mvctx, int usehp);
Yaowu Xuc27fc142016-08-22 16:08:15 -070030
Yaowu Xuf883b422016-08-30 14:01:10 -070031void av1_build_nmv_cost_table(int *mvjoint, int *mvcost[2],
Alex Conversed5d9b6c2017-05-23 15:23:45 -070032 const nmv_context *mvctx,
33 MvSubpelPrecision precision);
Yaowu Xuc27fc142016-08-22 16:08:15 -070034
Yaowu Xuf883b422016-08-30 14:01:10 -070035void av1_update_mv_count(ThreadData *td);
Yaowu Xuc27fc142016-08-22 16:08:15 -070036
Alex Converse28744302017-04-13 14:46:22 -070037#if CONFIG_INTRABC
38void av1_encode_dv(aom_writer *w, const MV *mv, const MV *ref,
39 nmv_context *mvctx);
40#endif // CONFIG_INTRABC
41
Yaowu Xuc27fc142016-08-22 16:08:15 -070042#ifdef __cplusplus
43} // extern "C"
44#endif
45
Yaowu Xuf883b422016-08-30 14:01:10 -070046#endif // AV1_ENCODER_ENCODEMV_H_