Fix empty force_key_frames value

This commit is contained in:
Jan Stabenow 2023-04-18 08:59:12 +02:00
parent f333d7fe95
commit e4676fded7
No known key found for this signature in database
GPG Key ID: 9C22DD65A9AAF133
2 changed files with 6 additions and 2 deletions

View File

@ -4,6 +4,8 @@
- Add Add stream key field and protocol detection to RTMP publication service
- Add Chinese (simplified) translation (thanks to Huyg0180110559)
- Fix empty force_key_frames value
- Fix Fix Icecast publication service
- Fix imprint, terms and credit without share ([#525](https://github.com/datarhei/restreamer/issues/529))
- Fix proxy error on the playersite ([#525](https://github.com/datarhei/restreamer/issues/525))
- Fix saving RTMP advanced options ([#518](https://github.com/datarhei/restreamer/issues/518))

View File

@ -91,8 +91,6 @@ function createMapping(settings, stream, skills) {
`${settings.num_capture_buffers}`,
'-num_output_buffers',
`${settings.num_output_buffers}`,
'-force_key_frames',
`${settings.force_key_frames}`,
'-b:v',
`${settings.bitrate}k`,
'-maxrate',
@ -112,6 +110,10 @@ function createMapping(settings, stream, skills) {
'2048',
];
if (settings.force_key_frames !== '') {
local.push('-force_key_frames', `${settings.force_key_frames}`);
}
if (settings.gop !== 'auto') {
local.push('-g', `${Math.round(parseInt(settings.fps) * parseInt(settings.gop)).toFixed(0)}`);
local.push('-keyint_min', `${parseInt(settings.fps)}`);