I now have 1.0.0-rc3 built from source. I've tested that I can transcode an 8kHz mono file to the alaw codec:
Code: Select all
./vlc -vvv -I "dummy" source.wav --sout='#transcode{acodec=alaw,ab=16,channels=1,samplerate=8000}:duplicate{dst=rtp{dst=192.168.0.2,port-audio=1234}}'
This works correctly; I can listen to the received stream and I can see the correct codec in UDP packets in Wireshark.
When I try to transcode to G.726 I get a segmentation fault. Here's the command line:
Code: Select all
./vlc -vvv -I "dummy" source.wav --sout='#transcode{acodec=g726,ab=16,channels=1,samplerate=8000}:duplicate{dst=rtp{dst=192.168.0.2,port-audio=1234}}'
Here's the (truncated) output of VLC:
Code: Select all
[0x82b3b80] main stream out debug: set config option: sout-transcode-acodec to g726
[0x82b3b80] main stream out debug: set config option: sout-transcode-ab to 16
[0x82b3b80] main stream out debug: set config option: sout-transcode-channels to 1
[0x82b3b80] main stream out debug: set config option: sout-transcode-samplerate to 8000
[0x82b3b80] stream_out_transcode stream out debug: codec audio=g726 8000Hz 1 channels 16Kb/s
(stuff omitted)
[0x82b0b38] main stream output debug: adding a new sout input (sout_input:0x82b8728)
[0x82b3b80] stream_out_transcode stream out debug: creating audio transcoding from fcc=`s16l' to fcc=`g726'
[0x82c7ee8] main decoder debug: looking for decoder module: 26 candidates
[0x82c7ee8] araw decoder debug: samplerate:8000Hz channels:1 bits/sample:16
[0x82c7ee8] main decoder debug: using decoder module "araw"
[0x82c7ee8] main decoder debug: TIMER module_need() : 5.798 ms - Total 5.798 ms / 1 intvls (Avg 5.798 ms)
[0x82c8848] main encoder debug: looking for encoder module: 6 candidates
[0x82c8848] avcodec encoder debug: libavcodec initialized (interface 0x341e02)
[0x82c8848] avcodec encoder debug: found encoder G.726 ADPCM Audio
(stuff omitted)
[0x82b74b8] stream_out_rtp stream out debug: sdp=
v=0
o=(stuff omitted)
s=Unnamed
i=N/A
c=IN IP4 192.168.0.2
t=0 0
a=tool:vlc 1.0.0-rc3
a=recvonly
a=type:broadcast
a=charset:UTF-8
m=audio 1234 RTP/AVP 96
b=AS:16
b=RR:0
a=rtpmap:96 G726-16/8000
[0x82b5cc0] stream_out_duplicate stream out debug: - added for output 0
[0x82afb48] main input debug: Decoder buffering done in 55 ms
Segmentation fault
A GDB backtrace shows this:
Code: Select all
#0 0x02f3b5d3 in g726_encode_frame (avctx=0x9cb4730, dst=0xb6b54008 "U@@",
buf_size=335896, data=0x9cb5830) at libavcodec/g726.c:357
#1 0x02cc1738 in avcodec_encode_audio (avctx=0x9cb4730, buf=0xb6b54008 "U@@",
buf_size=384000, samples=0x2) at libavcodec/utils.c:510
#2 0x02cbb297 in EncodeAudio (p_enc=0x9cb07c0, p_aout_buf=0x9cb0f88)
at ../../../../modules/codec/avcodec/encoder.c:1088
#3 0x001291f2 in Send (p_stream=0x9c99080, id=0x9ca9f80, p_buffer=0x9c9a5a0)
at ../../../modules/stream_out/transcode.c:1345
#4 0x003d53fd in sout_InputSendBuffer (p_input=0x9c9b8d0, p_buffer=0x9c9a5a0)
at ../../src/stream_output/stream_output.c:277
#5 0x003667bf in DecoderProcess (p_dec=0x9ca41c8,
p_block=<value optimized out>) at ../../src/input/decoder.c:1628
#6 0x00367448 in DecoderThread (p_this=0x9ca41c8)
at ../../src/input/decoder.c:887
#7 0x003bb5e7 in thread_entry (data=0x9c98c10)
at ../../src/misc/threads.c:1061
#8 0x00d2046b in start_thread () from /lib/libpthread.so.0
#9 0x00c77dbe in clone () from /lib/libc.so.6
Hopefully lots of detail there. Any ideas?