X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavcodec%2Fhevc.h;h=8420f38dc32220bb238195fbe8edeb12dc42ca40;hb=96cea6269ac378f848a054ba8cff532734653662;hp=a1e2e8469e63fe5a4fac34c2e307063871d9645d;hpb=02ea384abd8ef53a1e4654ab0c9e72e08141d751;p=ffmpeg diff --git a/libavcodec/hevc.h b/libavcodec/hevc.h index a1e2e8469e6..8420f38dc32 100644 --- a/libavcodec/hevc.h +++ b/libavcodec/hevc.h @@ -82,8 +82,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 || \ @@ -685,15 +683,6 @@ typedef struct PredictionUnit { uint8_t chroma_mode_c[4]; } 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 { DECLARE_ALIGNED(32, int16_t, coeffs[2][MAX_TB_SIZE * MAX_TB_SIZE]); int cu_qp_delta; @@ -719,6 +708,7 @@ typedef struct DBParams { #define HEVC_FRAME_FLAG_OUTPUT (1 << 0) #define HEVC_FRAME_FLAG_SHORT_REF (1 << 1) #define HEVC_FRAME_FLAG_LONG_REF (1 << 2) +#define HEVC_FRAME_FLAG_BUMPING (1 << 3) typedef struct HEVCFrame { AVFrame *frame; @@ -766,7 +756,6 @@ typedef struct HEVCLocalContext { GetBitContext gb; CABACContext cc; - TransformTree tt; int8_t qp_y; int8_t curr_qp_y; @@ -790,8 +779,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 { @@ -1016,6 +1010,8 @@ int ff_hevc_set_new_ref(HEVCContext *s, AVFrame **frame, int poc); */ int ff_hevc_output_frame(HEVCContext *s, AVFrame *frame, int flush); +void ff_hevc_bump_frame(HEVCContext *s); + void ff_hevc_unref_frame(HEVCContext *s, HEVCFrame *frame, int flags); void ff_hevc_set_neighbour_available(HEVCContext *s, int x0, int y0, @@ -1027,7 +1023,7 @@ void ff_hevc_luma_mv_mvp_mode(HEVCContext *s, int x0, int y0, int nPbW, int nPbH, int log2_cb_size, int part_idx, int merge_idx, MvField *mv, int mvp_lx_flag, int LX); -void ff_hevc_set_qPy(HEVCContext *s, int xC, int yC, int xBase, int yBase, +void ff_hevc_set_qPy(HEVCContext *s, int xBase, int yBase, int log2_cb_size); void ff_hevc_deblocking_boundary_strengths(HEVCContext *s, int x0, int y0, int log2_trafo_size);