24 #include <vdpau/vdpau.h>
42 rf->surface = VDP_INVALID_HANDLE;
43 rf->is_long_term = VDP_FALSE;
44 rf->top_is_reference = VDP_FALSE;
45 rf->bottom_is_reference = VDP_FALSE;
46 rf->field_order_cnt[0] = 0;
47 rf->field_order_cnt[1] = 0;
56 if (pic_structure == 0)
59 rf->surface = surface;
72 VdpPictureInfoH264 *info = &pic_ctx->info.h264;
75 VdpReferenceFrameH264 *rf = &info->referenceFrames[0];
76 #define H264_RF_COUNT FF_ARRAY_ELEMS(info->referenceFrames)
78 for (list = 0; list < 2; ++list) {
82 for (i = 0; i < ls; ++i) {
84 VdpReferenceFrameH264 *rf2;
85 VdpVideoSurface surface_ref;
93 rf2 = &info->referenceFrames[0];
95 if ((rf2->surface == surface_ref) &&
96 (rf2->is_long_term == pic->
long_ref) &&
97 (rf2->frame_idx == pic_frame_idx))
125 VdpPictureInfoH264 *info = &pic_ctx->info.h264;
126 #ifdef VDP_DECODER_PROFILE_H264_HIGH_444_PREDICTIVE
127 VdpPictureInfoH264Predictive *info2 = &pic_ctx->info.h264_predictive;
131 info->slice_count = 0;
139 info->mb_adaptive_frame_field_flag = h->
sps.
mb_aff && !info->field_pic_flag;
147 info->pic_init_qp_minus26 = h->
pps.
init_qp - 26;
148 info->num_ref_idx_l0_active_minus1 = h->
pps.
ref_count[0] - 1;
149 info->num_ref_idx_l1_active_minus1 = h->
pps.
ref_count[1] - 1;
155 #ifdef VDP_DECODER_PROFILE_H264_HIGH_444_PREDICTIVE
159 info->entropy_coding_mode_flag = h->
pps.
cabac;
165 sizeof(info->scaling_lists_4x4));
167 sizeof(info->scaling_lists_8x8[0]));
169 sizeof(info->scaling_lists_8x8[1]));
194 pic_ctx->info.h264.slice_count++;
220 profile = VDP_DECODER_PROFILE_H264_BASELINE;
223 #ifdef VDP_DECODER_PROFILE_H264_CONSTRAINED_BASELINE
224 profile = VDP_DECODER_PROFILE_H264_CONSTRAINED_BASELINE;
228 profile = VDP_DECODER_PROFILE_H264_MAIN;
231 profile = VDP_DECODER_PROFILE_H264_HIGH;
233 #ifdef VDP_DECODER_PROFILE_H264_EXTENDED
235 profile = VDP_DECODER_PROFILE_H264_EXTENDED;
241 profile = VDP_DECODER_PROFILE_H264_HIGH;
243 #ifdef VDP_DECODER_PROFILE_H264_HIGH_444_PREDICTIVE
247 profile = VDP_DECODER_PROFILE_H264_HIGH_444_PREDICTIVE;
255 level = VDP_DECODER_LEVEL_H264_1b;
261 .
name =
"h264_vdpau",
268 .frame_priv_data_size =
sizeof(
struct vdpau_picture_context),