feat: 支持在线升级功能

This commit is contained in:
mofeng-git
2026-02-11 19:41:19 +08:00
parent 60b294e0ab
commit 934dc48208
36 changed files with 945 additions and 100 deletions

View File

@@ -127,8 +127,7 @@ impl VideoFrameAdapter {
// Inject cached SPS/PPS before IDR when missing
if is_keyframe && (!has_sps || !has_pps) {
if let (Some(sps), Some(pps)) = (self.h264_sps.as_ref(), self.h264_pps.as_ref())
{
if let (Some(sps), Some(pps)) = (self.h264_sps.as_ref(), self.h264_pps.as_ref()) {
let mut out = Vec::with_capacity(8 + sps.len() + pps.len() + data.len());
out.extend_from_slice(&[0, 0, 0, 1]);
out.extend_from_slice(sps);