Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Recording audio from pulseaudio output monitor results in stretched audio:

  • The audio falls out of sync as it moves slower than the video
    • I've checked, the video is in sync, it's the audio that's the problem
  • The audio pitch is lower as it's been stretched.
  • This only happens with the output monitor, microphones are synced perfectly
  • Debian sid

Demo code:

avconv -f pulse -i alsa_output.pci-0000_00_1b.0.analog-stereo.monitor -acodec copy out.wav

Where alsa[...]monitor is the name of the monitor of audio output as defined in pactl list

The speed difference between video and audio is almost exactly the same ratio as the difference between the 48000 Hz that avconv automatically chooses as the stream frequency and the 44100 Hz that pactl list short sources says it's supposed to be.

Adding the -ar 44100 flag to avconv makes no difference, the audio is still stretched wrong.

share|improve this question
up vote 0 down vote accepted

Apparently pulseaudio doesn't know what it wants. It tells everyone it's using 48khz when it's really using 44.1khz.

The fix:

Uncomment default-sample-rate = 44100 in /etc/pulse/daemon.conf and set it to 48000

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .