Lines Matching refs:seq_param
126 VAEncSequenceParameterBufferMPEG2 seq_param; member
260 find_frame_rate_code(const VAEncSequenceParameterBufferMPEG2 *seq_param) in find_frame_rate_code() argument
264 float frame_rate_value = seq_param->frame_rate * in find_frame_rate_code()
265 (seq_param->sequence_extension.bits.frame_rate_extension_d + 1) / in find_frame_rate_code()
266 (seq_param->sequence_extension.bits.frame_rate_extension_n + 1); in find_frame_rate_code()
281 const VAEncSequenceParameterBufferMPEG2 *seq_param, in sps_rbsp() argument
284 int frame_rate_code = find_frame_rate_code(seq_param); in sps_rbsp()
288 bitstream_put_ui(bs, seq_param->picture_width, 12); in sps_rbsp()
289 bitstream_put_ui(bs, seq_param->picture_height, 12); in sps_rbsp()
290 bitstream_put_ui(bs, seq_param->aspect_ratio_information, 4); in sps_rbsp()
292 …bitstream_put_ui(bs, (seq_param->bits_per_second + 399) / 400, 18); /* the low 18 bits of bit_rate… in sps_rbsp()
294 bitstream_put_ui(bs, seq_param->vbv_buffer_size, 10); in sps_rbsp()
303 bitstream_put_ui(bs, seq_param->sequence_extension.bits.profile_and_level_indication, 8); in sps_rbsp()
304 bitstream_put_ui(bs, seq_param->sequence_extension.bits.progressive_sequence, 1); in sps_rbsp()
305 bitstream_put_ui(bs, seq_param->sequence_extension.bits.chroma_format, 2); in sps_rbsp()
306 bitstream_put_ui(bs, seq_param->picture_width >> 12, 2); in sps_rbsp()
307 bitstream_put_ui(bs, seq_param->picture_height >> 12, 2); in sps_rbsp()
308 …bitstream_put_ui(bs, ((seq_param->bits_per_second + 399) / 400) >> 18, 12); /* bit_rate_extension … in sps_rbsp()
310 bitstream_put_ui(bs, seq_param->vbv_buffer_size >> 10, 8); in sps_rbsp()
311 bitstream_put_ui(bs, seq_param->sequence_extension.bits.low_delay, 1); in sps_rbsp()
312 bitstream_put_ui(bs, seq_param->sequence_extension.bits.frame_rate_extension_n, 2); in sps_rbsp()
313 bitstream_put_ui(bs, seq_param->sequence_extension.bits.frame_rate_extension_d, 5); in sps_rbsp()
320 bitstream_put_ui(bs, seq_param->gop_header.bits.time_code, 25); in sps_rbsp()
321 bitstream_put_ui(bs, seq_param->gop_header.bits.closed_gop, 1); in sps_rbsp()
322 bitstream_put_ui(bs, seq_param->gop_header.bits.broken_link, 1); in sps_rbsp()
329 pps_rbsp(const VAEncSequenceParameterBufferMPEG2 *seq_param, in pps_rbsp() argument
335 if (seq_param->sequence_extension.bits.chroma_format == CHROMA_FORMAT_420) in pps_rbsp()
387 build_packed_pic_buffer(const VAEncSequenceParameterBufferMPEG2 *seq_param, in build_packed_pic_buffer() argument
394 pps_rbsp(seq_param, pic_param, &bs); in build_packed_pic_buffer()
403 const VAEncSequenceParameterBufferMPEG2 *seq_param, in build_packed_seq_buffer() argument
409 sps_rbsp(ctx, seq_param, &bs); in build_packed_seq_buffer()
726 VAEncSequenceParameterBufferMPEG2 *seq_param) in mpeg2enc_init_sequence_parameter() argument
762 seq_param->intra_period = ctx->intra_period; in mpeg2enc_init_sequence_parameter()
763 seq_param->ip_period = ctx->ip_period; /* FIXME: ??? */ in mpeg2enc_init_sequence_parameter()
764 seq_param->picture_width = ctx->width; in mpeg2enc_init_sequence_parameter()
765 seq_param->picture_height = ctx->height; in mpeg2enc_init_sequence_parameter()
768 seq_param->bits_per_second = 1024 * ctx->bit_rate; /* use kbps as input */ in mpeg2enc_init_sequence_parameter()
770 seq_param->bits_per_second = 0x3FFFF * 400; in mpeg2enc_init_sequence_parameter()
772 seq_param->frame_rate = ctx->fps; in mpeg2enc_init_sequence_parameter()
773 seq_param->aspect_ratio_information = 1; in mpeg2enc_init_sequence_parameter()
774 seq_param->vbv_buffer_size = 3; /* B = 16 * 1024 * vbv_buffer_size */ in mpeg2enc_init_sequence_parameter()
776 seq_param->sequence_extension.bits.profile_and_level_indication = profile << 4 | level; in mpeg2enc_init_sequence_parameter()
777 seq_param->sequence_extension.bits.progressive_sequence = 1; /* progressive frame-pictures */ in mpeg2enc_init_sequence_parameter()
778 seq_param->sequence_extension.bits.chroma_format = CHROMA_FORMAT_420; /* 4:2:0 */ in mpeg2enc_init_sequence_parameter()
779 seq_param->sequence_extension.bits.low_delay = 0; /* FIXME */ in mpeg2enc_init_sequence_parameter()
780 seq_param->sequence_extension.bits.frame_rate_extension_n = 0; in mpeg2enc_init_sequence_parameter()
781 seq_param->sequence_extension.bits.frame_rate_extension_d = 0; in mpeg2enc_init_sequence_parameter()
783 seq_param->gop_header.bits.time_code = (1 << 12); /* bit12: marker_bit */ in mpeg2enc_init_sequence_parameter()
784 seq_param->gop_header.bits.closed_gop = 0; in mpeg2enc_init_sequence_parameter()
785 seq_param->gop_header.bits.broken_link = 0; in mpeg2enc_init_sequence_parameter()
945 mpeg2enc_init_sequence_parameter(ctx, &ctx->seq_param); in mpeg2enc_init()
959 mpeg2enc_time_code(VAEncSequenceParameterBufferMPEG2 *seq_param, in mpeg2enc_time_code() argument
962 int fps = (int)(seq_param->frame_rate + 0.5); in mpeg2enc_time_code()
1000 VAEncSequenceParameterBufferMPEG2 *seq_param = &ctx->seq_param; in mpeg2enc_update_sequence_parameter() local
1004 seq_param->gop_header.bits.time_code = mpeg2enc_time_code(seq_param, display_order); in mpeg2enc_update_sequence_parameter()
1089 VAEncSequenceParameterBufferMPEG2 *seq_param; in mpeg2enc_update_slice_parameter() local
1098 seq_param = &ctx->seq_param; in mpeg2enc_update_slice_parameter()
1099 width_in_mbs = (seq_param->picture_width + 15) / 16; in mpeg2enc_update_slice_parameter()
1100 height_in_mbs = (seq_param->picture_height + 15) / 16; in mpeg2enc_update_slice_parameter()
1150 length_in_bits = build_packed_seq_buffer(ctx, &ctx->seq_param, &packed_seq_buffer); in begin_picture()
1171 length_in_bits = build_packed_pic_buffer(&ctx->seq_param, &ctx->pic_param, &packed_pic_buffer); in begin_picture()
1193 VAEncSequenceParameterBufferMPEG2 *seq_param = &ctx->seq_param; in begin_picture() local
1197 sizeof(*seq_param), in begin_picture()
1199 seq_param, in begin_picture()