mirror of
https://github.com/obsproject/obs-studio.git
synced 2026-08-30 17:58:37 +08:00
obs-outputs: Include all audio encoder bitrates
When network optimizations are enabled, `new_socket_loop` is enabled, and an accurate total output bitrate is required. Include the audio bitrates in this calculation.
This commit is contained in:
@@ -1033,8 +1033,11 @@ static int init_send(struct rtmp_stream *stream)
|
||||
}
|
||||
}
|
||||
|
||||
obs_encoder_t *aencoder = obs_output_get_audio_encoder(context, 0);
|
||||
if (aencoder) {
|
||||
for (size_t i = 0; i < MAX_OUTPUT_AUDIO_ENCODERS; i++) {
|
||||
obs_encoder_t *aencoder = obs_output_get_audio_encoder(context, 0);
|
||||
if (!aencoder)
|
||||
continue;
|
||||
|
||||
obs_data_t *params = obs_encoder_get_settings(aencoder);
|
||||
if (params) {
|
||||
int bitrate = obs_data_get_int(params, "bitrate");
|
||||
|
||||
Reference in New Issue
Block a user