We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1af512f commit 2b613f4Copy full SHA for 2b613f4
1 file changed
shared/media-playback/media-playback/media.c
@@ -348,7 +348,6 @@ void mp_media_next_audio(mp_media_t *m)
348
struct mp_decode *d = &m->a;
349
struct obs_source_audio audio = {0};
350
AVFrame *f = d->frame;
351
- int channels = f->ch_layout.nb_channels;
352
353
if (!mp_media_can_play_frame(m, d))
354
return;
@@ -361,7 +360,7 @@ void mp_media_next_audio(mp_media_t *m)
361
360
audio.data[i] = f->data[i];
362
363
audio.samples_per_sec = f->sample_rate * m->speed / 100;
364
- audio.speakers = convert_speaker_layout(channels);
+ audio.speakers = convert_speaker_layout(f->ch_layout.nb_channels);
365
audio.format = convert_sample_format(f->format);
366
audio.frames = f->nb_samples;
367
audio.timestamp = m->full_decode ? d->frame_pts
0 commit comments