blob: f74973e9ebf771032b3739bf9962354a586a0a26 [file] [log] [blame]
Cheng Cheneee8b552021-05-04 13:57:55 -07001/*
2 * Copyright (c) 2021, Alliance for Open Media. All rights reserved
3 *
4 * 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.
10 */
11
12#ifndef AOM_AV1_ENCODER_EXTERNAL_PARTITION_H_
13#define AOM_AV1_ENCODER_EXTERNAL_PARTITION_H_
14
15#include <stdbool.h>
16
17#include "aom/aom_codec.h"
18#include "aom/aom_external_partition.h"
19
20#ifdef __cplusplus
21extern "C" {
22#endif
23/*!\cond */
24
25typedef struct ExtPartController {
26 int ready;
Cheng Chenc0480112021-05-18 17:54:15 -070027 int test_mode;
Cheng Cheneee8b552021-05-04 13:57:55 -070028 aom_ext_part_config_t config;
29 aom_ext_part_model_t model;
30 aom_ext_part_funcs_t funcs;
31} ExtPartController;
32
33aom_codec_err_t av1_ext_part_create(aom_ext_part_funcs_t funcs,
34 aom_ext_part_config_t config,
35 ExtPartController *ext_part_controller);
36
37aom_codec_err_t av1_ext_part_init(ExtPartController *ext_part_controller);
38
39aom_codec_err_t av1_ext_part_delete(ExtPartController *ext_part_controller);
40
41bool av1_ext_part_get_partition_decision(ExtPartController *ext_part_controller,
42 aom_partition_decision_t *decision);
43
44bool av1_ext_part_send_partition_stats(ExtPartController *ext_part_controller,
45 const aom_partition_stats_t *stats);
46
47bool av1_ext_part_send_features(ExtPartController *ext_part_controller,
48 const aom_partition_features_t *features);
49
Cheng Chenebfcfac2021-08-16 17:15:40 -070050aom_ext_part_decision_mode_t av1_get_ext_part_decision_mode(
51 const ExtPartController *ext_part_controller);
52
Cheng Cheneee8b552021-05-04 13:57:55 -070053/*!\endcond */
54#ifdef __cplusplus
55} // extern "C"
56#endif
57
58#endif // AOM_AV1_ENCODER_EXTERNAL_PARTITION_H_