View Full Version : SSRC.exe
oof
8th December 2003, 18:06
I am not clear on how to use SSRC.exe to resample
WAV audio. There is a command line argument for output
sample rate but none for input rate or ratio.
The BeSweet command line when converting NTSC/PAL
has "-OTA 23976 25000" immediately before the SSRC command.
What does this do and what program/dll does it ?
Do we have to change the (reported) sample rate on the input file first?
INT 48000*(23976/25000) = 460334 and upsample to 48000 ?
I suppose DSPGuru knows this.
And just for curiosity how does a resample filter work ?
Do you have to make a FIR filter with a length = to the
Least Common Multiple of the 2 sample rates ?
KpeX
9th December 2003, 02:03
Resampling and frame rate conversion are two different things. SSRC does not do FRC afaik.
SSRC resamples, resampling is the process of recalculating sample points to change the number of samples per second. Yes, some rounding error is introduced unless the desired sample rate is an even multiple of the source sample rate. There is no way to specify input sample rate because SSRC reads the input sample rate.
FRC stretches audio itself by shrinking or stretching, you can think of this as speeding up or slowing down the audio. Obviously a change in pitch results. This is usually in order to synch with video. FRC in besweet is done by the besweet executable itself AFAIK.
oof
9th December 2003, 03:06
Thank you. I did not expect SSRC to do a frame rate
conversion because audio does not have frames.
Besweet does not deal with video and therefore
its reference to framerate conversion is a misnomer.
What it really does is an audio resample to match
a video FRC . I simply want to know
how to use SSRC to do this with arbitrary ratios.
"rounding error" ? I think that is a slight oversimplification.
So now I have to find out how to modify the headers in a WAV
file to change the reported sample rate.
KpeX
9th December 2003, 03:07
Well clearly you are the audio expert here. Do some searches and you'll see my opinion on referring to the framerate of audio. Good luck and cheers.
If I can ask, why not just do the FRC with beSweet?
oof
9th December 2003, 03:19
Didn't mean to ruffle feathers.
I might want to put it in a script or have another program execute it.
...and just general curiosity too.
What if a person wanted to resample an audio by some ratio
without having to know the actual sample rate ?
pacohaas
9th December 2003, 22:46
to use ssrc.exe, just run it from teh command-line and you'll see the options it has to offer, including different dithering methods, resampling, 2-pass normalizing, etc. If i remember correctly, the commandline for resampling is simply -r.
oof
10th December 2003, 00:01
I have done that. I am upset that the output will
not appear to be 48000.
So if I have a wav at 48000 from a PAL (25 fps ) video and want
to convert it to play with the video at 23.976
We have "ssrc -rate 50050 input.wav output.wav"
Now the wav has the wrong sample rate, even though the data is correct
I now have to go tell the wav that it's 48000.
I need a wav header editor
KpeX
10th December 2003, 00:46
I'm confused. Why are you trying to do FRC through resampling and changing the header? That'll probably cause major playback problems. Just use besweet with the FRC option, that's what it was designed for.
oof
10th December 2003, 01:20
It's become kind of a theoretical problem now.
You take a 48000 s/s wav resample and you end up with a
48000 s/s wav. How does besweet do it , given that it uses
SSRC and SSRC has no input sample rate argument ? Besweet must be feeding SSRC a wav whose sample rate is NOT 48000.
I'm just screwing around. I use Besweet all the time to do real work.
oof
10th December 2003, 03:18
OK thanks for your help. I have found the source
and will add another switch to override the input sampling rate
or better yet , add a switch to specify the Ratio which is what
I really wanted anyway.
e.g. "ssrc -ratio 1.042709 in.wav out.wav"
Wilbert
10th December 2003, 15:42
Look for wavefix to fix the header:
http://forum.doom9.org/search.php?s=&action=showresults&searchid=798051
Use google to find wavefix.exe.
oof
10th December 2003, 16:28
Thanks, I'll do that:)
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.