Menu

#22 rare resampling error

1.0
open
nobody
None
2023-02-02
2023-01-27
Anonymous
No

Hello
I am using code similar to yours to extract audio from movie files while dropping the sampling frequency to 10KHz

In 99% of the cases things go smoothly, however in a small minority of videos (I have seen it in AVI and MKV), the output PCM is either "slow motion" or "fast motion", meaning that the playback speed is turned down or up, sounding "funny". The slow/fastness is quite severe, at least 4 times slower compared to normal

I have examined the source streams and couldn't find a problem or difference
do you have any ideas what could go wrong?

thanks
nikos
https://www.zabkat.com/blog/uncompressed-audio-MP3.htm

Discussion

  • yamamoto2002

    yamamoto2002 - 2023-01-29

    I don't downsample PCM files to 10kHz so I don't know about your problem, sorry. I experienced the resampler glitch when 44.1kHz upsample to 768kHz and comversion process simply failed

     
  • Anonymous

    Anonymous - 2023-02-02

    thanks for your reply.
    It's strange, because if you use the windows 10 automatic resampler (ie. don't use the resampler object at all, just set the desired MF_MT_AUDIO_SAMPLES_PER_SECOND on the partial type fed to IMFSourceReader::SetCurrentMediaType to convert the output) then it works fine, so it's not the codecs, just the resampler object setup

    to add more to the confusion, on windows 7 where the resampler object is the ONLY way to downsample, everything works fine on the same media files that fail on windows 10 !?

     
  • yamamoto2002

    yamamoto2002 - 2023-02-02

    Maybe it is another glitch of operating system and it will be self healed with future Windows update... I'm waiting to fix the bug of query function of USB transfer speed :)

     

Anonymous
Anonymous

Add attachments
Cancel