X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavcodec%2Fhevc.h;h=333ea4634b4ab986b9897d45db7740b9b8fe3211;hb=18f4fa251b0eb36392839f5bf6180f280dc04d8d;hp=959cd58d189a35f13054ad89e3a5211cf56d0c83;hpb=c67b449bebbe0b35c73b203683e77a0a649bc765;p=ffmpeg diff --git a/libavcodec/hevc.h b/libavcodec/hevc.h index 959cd58d189..333ea4634b4 100644 --- a/libavcodec/hevc.h +++ b/libavcodec/hevc.h @@ -78,7 +78,6 @@ */ #define SAMPLE(tab, x, y) ((tab)[(y) * s->sps->width + (x)]) #define SAMPLE_CTB(tab, x, y) ((tab)[(y) * min_cb_width + (x)]) -#define SAMPLE_CBF(tab, x, y) ((tab)[((y) & ((1<nal_unit_type == NAL_IDR_W_RADL || s->nal_unit_type == NAL_IDR_N_LP) #define IS_BLA(s) (s->nal_unit_type == NAL_BLA_W_RADL || s->nal_unit_type == NAL_BLA_W_LP || \ @@ -523,7 +522,6 @@ typedef struct HEVCPPS { int *ctb_addr_ts_to_rs; ///< CtbAddrTSToRS int *tile_id; ///< TileId int *tile_pos_rs; ///< TilePosRS - int *min_cb_addr_zs; ///< MinCbAddrZS int *min_tb_addr_zs; ///< MinTbAddrZS } HEVCPPS; @@ -545,6 +543,8 @@ typedef struct SliceHeader { uint8_t colour_plane_id; ///< RPS coded in the slice header itself is stored here + int short_term_ref_pic_set_sps_flag; + int short_term_ref_pic_set_size; ShortTermRPS slice_rps; const ShortTermRPS *short_term_rps; LongTermRPS long_term_rps; @@ -607,10 +607,6 @@ typedef struct CodingUnit { enum PredMode pred_mode; ///< PredMode enum PartMode part_mode; ///< PartMode - uint8_t rqt_root_cbf; - - uint8_t pcm_flag; - // Inferred parameters uint8_t intra_split_flag; ///< IntraSplitFlag uint8_t max_trafo_depth; ///< MaxTrafoDepth @@ -623,7 +619,7 @@ typedef struct Mv { } Mv; typedef struct MvField { - Mv mv[2]; + DECLARE_ALIGNED(4, Mv, mv)[2]; int8_t ref_idx[2]; int8_t pred_flag[2]; uint8_t is_intra; @@ -647,15 +643,6 @@ typedef struct PredictionUnit { uint8_t intra_pred_mode_c; } PredictionUnit; -typedef struct TransformTree { - uint8_t cbf_cb[MAX_TRANSFORM_DEPTH][MAX_CU_SIZE * MAX_CU_SIZE]; - uint8_t cbf_cr[MAX_TRANSFORM_DEPTH][MAX_CU_SIZE * MAX_CU_SIZE]; - uint8_t cbf_luma; - - // Inferred parameters - uint8_t inter_split_flag; -} TransformTree; - typedef struct TransformUnit { int cu_qp_delta; @@ -689,6 +676,9 @@ typedef struct HEVCFrame { AVBufferRef *rpl_tab_buf; AVBufferRef *rpl_buf; + AVBufferRef *hwaccel_priv_buf; + void *hwaccel_picture_private; + /** * A sequence counter, so that old frames are output first * after a POC reset @@ -707,6 +697,9 @@ typedef struct HEVCNAL { int size; const uint8_t *data; + + int raw_size; + const uint8_t *raw_data; } HEVCNAL; struct HEVCContext; @@ -731,7 +724,6 @@ typedef struct HEVCLocalContext { GetBitContext gb; CABACContext cc; - TransformTree tt; int8_t qp_y; int8_t curr_qp_y; @@ -752,8 +744,13 @@ typedef struct HEVCLocalContext { PredictionUnit pu; NeighbourAvailable na; - uint8_t slice_or_tiles_left_boundary; - uint8_t slice_or_tiles_up_boundary; +#define BOUNDARY_LEFT_SLICE (1 << 0) +#define BOUNDARY_LEFT_TILE (1 << 1) +#define BOUNDARY_UPPER_SLICE (1 << 2) +#define BOUNDARY_UPPER_TILE (1 << 3) + /* properties of the boundary of the current CTB for the purposes + * of the deblocking filter */ + int boundary_flags; } HEVCLocalContext; typedef struct HEVCContext { @@ -807,7 +804,6 @@ typedef struct HEVCContext { VideoDSPContext vdsp; BswapDSPContext bdsp; int8_t *qp_y_tab; - uint8_t *split_cu_flag; uint8_t *horizontal_bs; uint8_t *vertical_bs; @@ -860,6 +856,11 @@ typedef struct HEVCContext { int frame_packing_arrangement_type; int content_interpretation_type; int quincunx_subsampling; + + /** display orientation */ + int sei_display_orientation_present; + int sei_anticlockwise_rotation; + int sei_hflip, sei_vflip; } HEVCContext; int ff_hevc_decode_short_term_rps(HEVCContext *s, ShortTermRPS *rps, @@ -978,9 +979,7 @@ void ff_hevc_luma_mv_mvp_mode(HEVCContext *s, int x0, int y0, void ff_hevc_set_qPy(HEVCContext *s, int xC, int yC, int xBase, int yBase, int log2_cb_size); void ff_hevc_deblocking_boundary_strengths(HEVCContext *s, int x0, int y0, - int log2_trafo_size, - int slice_or_tiles_up_boundary, - int slice_or_tiles_left_boundary); + int log2_trafo_size); int ff_hevc_cu_qp_delta_sign_flag(HEVCContext *s); int ff_hevc_cu_qp_delta_abs(HEVCContext *s); void ff_hevc_hls_filter(HEVCContext *s, int x, int y);