• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2016, 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_STATS_RATE_HIST_H_
13 #define AOM_STATS_RATE_HIST_H_
14 
15 #include "aom/aom_encoder.h"
16 
17 #ifdef __cplusplus
18 extern "C" {
19 #endif
20 
21 struct rate_hist;
22 
23 struct rate_hist *init_rate_histogram(const aom_codec_enc_cfg_t *cfg,
24                                       const aom_rational_t *fps);
25 
26 void destroy_rate_histogram(struct rate_hist *hist);
27 
28 void update_rate_histogram(struct rate_hist *hist,
29                            const aom_codec_enc_cfg_t *cfg,
30                            const aom_codec_cx_pkt_t *pkt);
31 
32 void show_q_histogram(const int counts[64], int max_buckets);
33 
34 void show_rate_histogram(struct rate_hist *hist, const aom_codec_enc_cfg_t *cfg,
35                          int max_buckets);
36 
37 #ifdef __cplusplus
38 }  // extern "C"
39 #endif
40 
41 #endif  // AOM_STATS_RATE_HIST_H_
42