mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-02-03 13:02:29 +00:00
va: h264enc: Make AUD the first NAL unit
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/2796>
This commit is contained in:
parent
e3e98da727
commit
d11a0d04ec
1 changed files with 6 additions and 6 deletions
|
@ -2702,6 +2702,12 @@ _encode_one_frame (GstVaH264Enc * self, GstVideoCodecFrame * gst_frame)
|
||||||
|
|
||||||
frame = _enc_frame (gst_frame);
|
frame = _enc_frame (gst_frame);
|
||||||
|
|
||||||
|
if (self->prop.aud) {
|
||||||
|
if ((self->packed_headers & VA_ENC_PACKED_HEADER_RAW_DATA)
|
||||||
|
&& !_add_aud (self, frame))
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
/* Repeat the SPS for IDR. */
|
/* Repeat the SPS for IDR. */
|
||||||
if (frame->poc == 0) {
|
if (frame->poc == 0) {
|
||||||
VAEncSequenceParameterBufferH264 sequence;
|
VAEncSequenceParameterBufferH264 sequence;
|
||||||
|
@ -2739,12 +2745,6 @@ _encode_one_frame (GstVaH264Enc * self, GstVideoCodecFrame * gst_frame)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (self->prop.aud) {
|
|
||||||
if ((self->packed_headers & VA_ENC_PACKED_HEADER_RAW_DATA)
|
|
||||||
&& !_add_aud (self, frame))
|
|
||||||
return FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Non I frame, construct reference list. */
|
/* Non I frame, construct reference list. */
|
||||||
if (frame->type != GST_H264_I_SLICE) {
|
if (frame->type != GST_H264_I_SLICE) {
|
||||||
GstVaH264EncFrame *vaf;
|
GstVaH264EncFrame *vaf;
|
||||||
|
|
Loading…
Reference in a new issue