[mythtv] [mythtv-commits] Ticket #1849: [9996] breaks audiowhenusing time stretching

Mark Spieth mark at dclabs.com.au
Wed May 24 02:55:12 UTC 2006


> On Wed, 2006-05-24 at 09:06 +1000, Mark Spieth wrote:
>> > #1849: [9996] breaks audio when using time stretching
>> > Reporter:  Cougar <cougar at random.ee>  |       Owner:  ijr
>> > [9996] breaks audio (adds distortion) when changing time stretch. After
>> > that only closing player (playback) and restarting helps. Resetting
>> > timestretch to 1.00 doesn't help. The problem exists also in [9999].
>> > [9995] was OK. This change came in from #1104
>> >
>> > What CPU is this with?
>> >
>> > I tested with both AMD64 & pentium4, bcs of the MMX code.
>> >
>> > Does enabling/disabling MMX help?
>> >
>> > Are you using passthru? DTS? AC3? Does disabling it help?
>> >
>>
>> there are quite a few people using this who have not reported any sort of
>> problems like this.
>> there was an issue during switching over to timestretch quite a while ago
>> but this was resolved.
>
> I think his complaint is with the soundtouch resync, not your patch.
>
> The reason I asked about passthru was because of the change in
> SoundTouch::putSamples(). That change is intended to get rid of
> that click/thunk sound you sometimes get when you switch to and
> from 1.0 time-stretch. But I could also see it throwing off an
> AC3/DTS decoder because the intermediate blocks the AC3/DTS
> signature might be there but the data could be corrupted by the
> resampling.
>

this is not true. it is only going to help if you use the rate transposer. 
rate is samplerate not tempo change.
I'd put that bit back in. what he was trying to solve is the case where the 
rate was >1.0 since the rate transposer is used differently than the other 
case.
the rate transposer is not needed in our case.
also note the dangling else after the comment close. not that it affects 
function.
havent check this thoroughly yet but the ratetransposer at 1.0 seems do some 
things when it shouldnt and thus use more cpu.
put back that section and all should be well.
also not sure about 1.0f comparison if that needs to be rubbery.
cougar you could test this quite easily. SoundTouch.cpp around line 298 or 
just do a diff.

mark



More information about the mythtv-dev mailing list