d3d12: fix start code prevention in write_sei_nalu()

Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Reviewed by: Pohsiang (John) Hsu <pohhsu@microsoft.com>

Reviewed-by: Jesse Natalie <None>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33312>
This commit is contained in:
Pohsiang (John) Hsu 2024-12-09 17:16:27 -08:00 committed by Marge Bot
parent e8499f69a4
commit bf7edb9a2d

View file

@ -555,6 +555,8 @@ d3d12_video_nalu_writer_h264::write_sei_nalu(H264_SEI_MESSAGE sei_
assert(false);
}
sei_payload_bitstream.set_start_code_prevention(true);
switch (sei_message.payload_type)
{
case H264_SEI_SCALABILITY_INFO:
@ -618,8 +620,6 @@ d3d12_video_nalu_writer_h264::write_sei_nalu(H264_SEI_MESSAGE sei_
assert(false);
}
rbsp.set_start_code_prevention(true);
//
// Write payload_type to bitstream
//
@ -720,4 +720,4 @@ d3d12_video_nalu_writer_h264::write_slice_svc_prefix(const H264_SLICE_PREFIX_SVC
std::copy_n(&naluBytes[0], naluByteSize, &headerBitstream.data()[startDstIndex]);
writtenBytes = naluByteSize;
}
}