Audio problem
Added by Victor Manuel over 3 years ago
Hi all.
I am having problems with the audio track not mapping in some channels from my iptv list.
I have converted the http links to pipe with this syntax according a post I found in this forum:
pipe:///usr/bin/ffmpeg -i http://urlofthestream -c copy -f mpegts pipe:1
but some HD channels come with no audio track, I have attached 2 examples, one with audio and other without it.
Could anybody point me to a clue of what could be happening?
If I upload the http iptv list to vlc or some other software, all channels have audio.
edit: The channels with no audio have AC3 audio tracks, the rest are MPEG2 , should I modify something in the syntax?
thank you in advance
withaudio.PNG (15.6 KB) withaudio.PNG | audio | ||
noaudio.PNG (16.1 KB) noaudio.PNG | no audio |
Replies (4)
RE: Audio problem - Added by Ron L over 3 years ago
Running the ffmpeg command in a terminal and piping the output to just a regular video player ffmpeg will show more info and might give a clue as to the issue.
/usr/bin/ffmpeg -i http://urlofthestream -c copy -f mpegts pipe:1 | mpv -
for example. One thing perhaps is you might need to use the map function to specify the correct audio stream.
Also, I'm not sure if this still applies but at one point it was suggested to me that the -mpegts_flags system_b switch be used for AC3 audio.
pipe:///usr/bin/ffmpeg -i http://urlofthestream -c copy -mpegts_flags system_b -f mpegts pipe:1
RE: Audio problem - Added by Victor Manuel over 3 years ago
First of all thanks for your reply.
This is what the terminal says:
ffmpeg version 2.7.1 Copyright (c) 2000-2015 the FFmpeg developers
built with gcc 4.9.3 (crosstool-NG 1.20.0) 20150311 (prerelease)
configuration: --prefix=/usr --incdir='${prefix}/include/ffmpeg' --arch=i686 --target-os=linux --cross-prefix=/usr/local/x86_64-pc-linux-gnu/bin/x86_64-pc-linux-gnu- --enable-cross-compile --enable-optimizations --enable-pic --enable-gpl --enable-shared --disable-static --enable-version3 --enable-nonfree --enable-libfaac --enable-encoders --enable-pthreads --disable-bzlib --disable-protocol=rtp --disable-muxer=image2 --disable-muxer=image2pipe --disable-swscale-alpha --disable-ffserver --disable-ffplay --disable-devices --disable-bzlib --disable-altivec --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libmp3lame --disable-vaapi --disable-decoder=amrnb --disable-decoder=ac3 --disable-decoder=ac3_fixed --disable-encoder=zmbv --disable-encoder=dca --disable-encoder=ac3 --disable-encoder=ac3_fixed --disable-encoder=eac3 --disable-decoder=dca --disable-decoder=eac3 --disable-decoder=truehd --cc=/usr/local/x86_64-pc-linux-gnu/bin/x86_64-pc-linux-gnu-ccache-gcc --enable-yasm --enable-libx264 --enable-encoder=libx264
libavutil 54. 27.100 / 54. 27.100
libavcodec 56. 41.100 / 56. 41.100
libavformat 56. 36.100 / 56. 36.100
libavdevice 56. 4.100 / 56. 4.100
libavfilter 5. 16.101 / 5. 16.101
libswscale 3. 1.101 / 3. 1.101
libswresample 1. 2.100 / 1. 2.100
libpostproc 53. 3.100 / 53. 3.100
[h264 @ 0x75b040] mmco: unref short failure
Input #0, mpegts, from 'http://url':
Duration: N/A, start: 4139.800600, bitrate: N/A
Program 1
Metadata:
service_name : Service01
service_provider: FFmpeg
Stream #0:0[0x100]: Video: h264 (High) ([27][0][0][0] / 0x001B), yuv420p(tv), 1920x1080 [SAR 1:1 DAR 16:9], 25 fps, 50 tbr, 90k tbn, 50 tbc
Stream #0:1[0x101](spa): Audio: ac3 ([129][0][0][0] / 0x0081), 48000 Hz, 5.1(side), 384 kb/s
Stream #0:2[0x102](spa,eng,esl,cat,eus): Subtitle: dvb_teletext ([6][0][0][0] / 0x0006)
Output #0, mpegts, to 'pipe:1':
Metadata:
encoder : Lavf56.36.100
Stream #0:0: Video: h264 ([27][0][0][0] / 0x001B), yuv420p, 1920x1080 [SAR 1:1 DAR 16:9], q=2-31, 25 fps, 50 tbr, 90k tbn, 25 tbc
Stream mapping:
Stream #0:0 -> #0:0 (copy)
-mpegts_flags system_b results on a FAIL when scanning services and the channel just don't play.
I have found in another thread to try putting the -acodec copy in the command like this
pipe:///usr/bin/ffmpeg -i http://urlofthestream -acodec copy -f mpegts pipe:1
And surprise! the channel has audio, although it freezes every 3 seconds in kodi.
So, I now have a latency problem instead of an audio problem.
I have not commented but my tvheadend is running on a synology NAS.
any suggestion to improve the performance?
thanks again
RE: Audio problem - Added by saen acro over 3 years ago
What happes if used as this:
ffmpeg -i "http://urlofthestream" -map 0 -c copy -f mpegts pipe:1
p.s.
isn't TVH accept stream directly via auto playlist option
RE: Audio problem - Added by Victor Manuel over 3 years ago
if I use
ffmpeg -i "http://urlofthestream" -map 0 -c copy -f mpegts pipe:1
it shows a lot of no sense symbols.
Captura.PNG (58.4 KB) Captura.PNG |