tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

inspection.h (2282B)


      1 /*
      2 * Copyright (c) 2017, 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 #ifndef AOM_AV1_DECODER_INSPECTION_H_
     12 #define AOM_AV1_DECODER_INSPECTION_H_
     13 
     14 #ifdef __cplusplus
     15 extern "C" {
     16 #endif  // __cplusplus
     17 
     18 #include "av1/common/seg_common.h"
     19 #if CONFIG_ACCOUNTING
     20 #include "av1/decoder/accounting.h"
     21 #endif
     22 
     23 #ifndef AOM_AOM_AOMDX_H_
     24 typedef void (*aom_inspect_cb)(void *decoder, void *data);
     25 #endif
     26 
     27 typedef struct insp_mv insp_mv;
     28 
     29 struct insp_mv {
     30  int16_t row;
     31  int16_t col;
     32 };
     33 
     34 typedef struct insp_mi_data insp_mi_data;
     35 
     36 struct insp_mi_data {
     37  insp_mv mv[2];
     38  int16_t ref_frame[2];
     39  int16_t mode;
     40  int16_t uv_mode;
     41  int16_t bsize;
     42  int16_t skip;
     43  int16_t segment_id;
     44  int16_t dual_filter_type;
     45  int16_t filter[2];
     46  int16_t tx_type;
     47  int16_t tx_size;
     48  int16_t cdef_level;
     49  int16_t cdef_strength;
     50  int16_t cfl_alpha_idx;
     51  int16_t cfl_alpha_sign;
     52  int16_t current_qindex;
     53  int16_t compound_type;
     54  int16_t motion_mode;
     55  int16_t intrabc;
     56  int16_t palette;
     57  int16_t uv_palette;
     58 };
     59 
     60 typedef struct insp_frame_data insp_frame_data;
     61 
     62 struct insp_frame_data {
     63 #if CONFIG_ACCOUNTING
     64  Accounting *accounting;
     65 #endif
     66  insp_mi_data *mi_grid;
     67  int16_t frame_number;
     68  int show_frame;
     69  int frame_type;
     70  int base_qindex;
     71  int mi_rows;
     72  int mi_cols;
     73  int tile_mi_rows;
     74  int tile_mi_cols;
     75  int16_t y_dequant[MAX_SEGMENTS][2];
     76  int16_t u_dequant[MAX_SEGMENTS][2];
     77  int16_t v_dequant[MAX_SEGMENTS][2];
     78  // TODO(negge): add per frame CDEF data
     79  int delta_q_present_flag;
     80  int delta_q_res;
     81  int show_existing_frame;
     82 };
     83 
     84 void ifd_init(insp_frame_data *fd, int frame_width, int frame_height);
     85 void ifd_clear(insp_frame_data *fd);
     86 int ifd_inspect(insp_frame_data *fd, void *decoder, int skip_not_transform);
     87 
     88 #ifdef __cplusplus
     89 }  // extern "C"
     90 #endif  // __cplusplus
     91 #endif  // AOM_AV1_DECODER_INSPECTION_H_