Ticket #1104: mythtv_mm_mad.1.patch
File mythtv_mm_mad.1.patch, 1.1 KB (added by , 16 years ago) |
---|
-
mythmusic/mythmusic/maddecoder.cpp
469 469 left = synth.pcm.samples[0]; 470 470 right = synth.pcm.samples[1]; 471 471 472 freq = frame.header.samplerate;473 channels = MAD_NCHANNELS(&frame.header);474 bitrate = frame.header.bitrate / 1000;472 long newfreq = frame.header.samplerate; 473 long newchannels = MAD_NCHANNELS(&frame.header); 474 long newbitrate = frame.header.bitrate / 1000; 475 475 476 476 if (output()) 477 477 { 478 output()->Reconfigure(16, channels, freq, false /*AC3/DTS passthru*/); 479 output()->SetSourceBitrate(bitrate); 478 if ((newfreq != freq) || (newchannels != channels)) 479 { 480 freq = newfreq; 481 channels = newchannels; 482 output()->Reconfigure(16, channels, freq, false /*AC3/DTS passthru*/); 483 } 484 if (newbitrate != bitrate) 485 { 486 bitrate = newbitrate; 487 output()->SetSourceBitrate(bitrate); 488 } 480 489 } 481 490 482 491 while (samples--)