How can I concatenate two mp3 files with different bit rates

Posted by Scott on Stack Overflow See other posts from Stack Overflow or by Scott
Published on 2010-12-13T01:30:53Z Indexed on 2011/01/10 15:54 UTC
Read the original article Hit count: 205

Filed under:
|
|
|

I have FFmpeg installed on my linux web server. When I execute the following code, I have intermittent results.

I think I have figured out that the MP3s do not compile when they have different bitrates.

exec ('cat '. $pair['source_file'] . ' ' . $pair['translated_word_file'] . '>' . $temp_mp3);

I might have found some articles online that reference taking them apart and then bundling them back together at a consistent bitrates.

I have confirmed that this won't really work with basic "cat" function and that "sox" can be used IF they have the same sample rate.

The issue now becomes "What is the best way to get them to the same sample rate?"

© Stack Overflow or respective owner

Related posts about php

Related posts about linux