[feat] support FIR

This commit is contained in:
dijunkun
2025-03-07 18:36:55 +08:00
parent 19fc8cda89
commit de0386f08a
21 changed files with 247 additions and 32 deletions

View File

@@ -151,7 +151,7 @@ int NvidiaVideoEncoder::Encode(
}
VideoFrameType frame_type;
if (0 == seq_++ % 300) {
if (0 == seq_++ % key_frame_interval_) {
ForceIdr();
frame_type = VideoFrameType::kVideoFrameKey;
} else {
@@ -263,6 +263,7 @@ int NvidiaVideoEncoder::ResetEncodeResolution(unsigned int width,
frame_width_ = width;
frame_height_ = height;
LOG_WARN("Reset resolution to [{}x{}]", frame_width_, frame_height_);
NV_ENC_RECONFIGURE_PARAMS reconfig_params = {NV_ENC_RECONFIGURE_PARAMS_VER};
NV_ENC_INITIALIZE_PARAMS init_params = {NV_ENC_INITIALIZE_PARAMS_VER};