[asterisk-dev] Trying to improve "file convert" command

Pavel Troller patrol at sinus.cz
Thu Apr 2 12:31:46 CDT 2015


Hi!
  I'm disappointed with functionality of the "file convert" command. Its
results are very poor, at least in ast11. It looks that the conversion
is performed through something like slin8 or even alaw/ulaw. There is
a huge difference between listening to for example MP3Player() using
a G.722 codec and Playback() of the G.722 file prepared by "file convert"
from the same MP3 file.
  I was looking at res_convert.c. It's unbelievably simple :-). The trick
must be somewhere in the underlying functions. I tried to analyze them as
well but I never noticed anything like specification of the format used for
the conversion. It just reads frames from one file and writes them to the
other one. But which frames ? Who specifies the format ? I'm confused.
  I would like to implement a simple logic to choose proper "intermediate
format" according to the combination of input/output file types. A small
hint to push me forward would be greatly appreciated :-).
  With regards,
    Pavel



More information about the asterisk-dev mailing list