| 6 | * tree. An additional intellectual property rights grant can be found |
| 7 | * in the file PATENTS. All contributing project authors may |
| 8 | * be found in the AUTHORS file in the root of the source tree. |
| 9 | */ |
| 10 |
| 11 | /*!\file |
| 12 | * \brief Describes the TPL stats descriptor and associated operations |
| 13 | * |
| 14 | */ |
| 15 | #ifndef VPX_VPX_VPX_TPL_H_ |
| 16 | #define VPX_VPX_VPX_TPL_H_ |
| 17 |
| 18 | #include "./vpx_integer.h" |
| 19 | #include "./vpx_codec.h" |
| 20 |
| 21 | #ifdef __cplusplus |
| 22 | extern "C" { |
| 23 | #endif |
| 24 |
| 25 | /*!\brief Current ABI version number |
| 26 | * |
| 27 | * \internal |
| 28 | * If this file is altered in any way that changes the ABI, this value |
| 29 | * must be bumped. Examples include, but are not limited to, changing |
| 30 | * types, removing or reassigning enums, adding/removing/rearranging |
| 31 | * fields to structures |
| 32 | */ |
| 33 | #define VPX_TPL_ABI_VERSION 5 /**<\hideinitializer*/ |
| 34 |
| 35 | /*!\brief Temporal dependency model stats for each block before propagation */ |
| 36 | typedef struct VpxTplBlockStats { |
| 37 | int16_t row; /**< Pixel row of the top left corner */ |
| 38 | int16_t col; /**< Pixel col of the top left corner */ |
| 39 | int64_t intra_cost; /**< Intra cost */ |
| 40 | int64_t inter_cost; /**< Inter cost */ |
| 41 | int16_t mv_r; /**< Motion vector row in pixel */ |
| 42 | int16_t mv_c; /**< Motion vector col in pixel */ |
| 43 | int64_t srcrf_rate; /**< Rate from source ref frame */ |
| 44 | int64_t srcrf_dist; /**< Distortion from source ref frame */ |
| 45 | int64_t pred_error; /**< Prediction error */ |
| 46 | int64_t inter_pred_err; /**< Inter prediction error */ |
| 47 | int64_t intra_pred_err; /**< Intra prediction error */ |
| 48 | int ref_frame_index; /**< Ref frame index in the ref frame buffer */ |
| 49 | } VpxTplBlockStats; |
| 50 |
| 51 | /*!\brief Temporal dependency model stats for each frame before propagation */ |
| 52 | typedef struct VpxTplFrameStats { |
| 53 | int frame_width; /**< Frame width */ |
| 54 | int frame_height; /**< Frame height */ |
| 55 | int num_blocks; /**< Number of blocks. Size of block_stats_list */ |
| 56 | VpxTplBlockStats *block_stats_list; /**< List of tpl stats for each block */ |
| 57 | } VpxTplFrameStats; |
| 58 |
| 59 | /*!\brief Temporal dependency model stats for each GOP before propagation */ |
| 60 | typedef struct VpxTplGopStats { |
| 61 | int size; /**< GOP size, also the size of frame_stats_list. */ |
| 62 | VpxTplFrameStats *frame_stats_list; /**< List of tpl stats for each frame */ |
| 63 | } VpxTplGopStats; |
| 64 |
| 65 | #ifdef __cplusplus |
| 66 | } // extern "C" |
| 67 | #endif |
| 68 |
| 69 | #endif // VPX_VPX_VPX_TPL_H_ |
| 70 |