Page 1 of 1

Can VLC stream the input from the soundcard ?

Posted: 17 Feb 2010 14:38
by dihfg
I tried to solve this by myself but did not succeed (still a newbee on streams).
The situation I think is not unusual: there is the PC running on Ubuntu 9.10, the audio output from a FM-Tuner is connected to the soundcard's LINE IN. Ok, I can hear the music. Now I want to stream it on my WLAN. Is this possible using VLC? If f so, how have I to configure VLC that it accepts the soundcard as an input for the output stream. The wizard (VLC 1.0.2) seems to accept only files or a netstream as input source.
Can an expert give me an advice how to proceed?
HG

Re: Can VLC stream the input from the soundcard ?

Posted: 17 Feb 2010 17:44
by Rémi Denis-Courmont
The input is alsa://<name of the alsa device>

Re: Can VLC stream the input from the soundcard ?

Posted: 19 Feb 2010 18:59
by dihfg
For two days now tried to get this running, alas no success.
On the command line:
vlc -vv alsa://hw:0,2 --sout '#standard{access=http,mux=ogg,dst=192.168.0.100:8080}'
resulted in
"no access_demux module matching "file" could be loaded" although
"main input debug: `alsa://hw:0,2' successfully opened"
VLC opens ,but no streaming!

I tried this on Windows XP and it worked nearly "out of the box".
What should I do to stream the line-in signal in a linux environment? Is there something wrong with my command line input?
Any ideas?
Hubert

Re: Can VLC stream the input from the soundcard ?

Posted: 20 Feb 2010 09:49
by Rémi Denis-Courmont
I am quite sure that this does not work on Windows either. You need to transcode to some codec that ogg can multiplex.

Re: Can VLC stream the input from the soundcard ?

Posted: 20 Feb 2010 18:10
by dihfg
I am quite sure that this does not work on Windows either. You need to transcode to some codec that ogg can multiplex.
No, it worked on Windows! The reason is that VLC's Windows-GUI is different from the GUI in Linux. While Win-GUI scans devices and allows to choose a soundcard AND an input for the stream, the Linux GUI offers this merely for dedicated video-devices (which are not connected, of course).
Nevertheless after some more hours of experimenting I finally found the solution for Linux by using the commands that the Win-GUI displays as a last step before you start the stream. There it reads:
:sout=#transcode{vcodec=h264,vb=800,scale=1,acodec=mp4a,ab=128,channels=2,samplerate=44100}:std{access=http,mux=ts,dst=192.168.0.100:8080}
I adopted it for the Linux command line and this WORKED:
vlc -vvv alsa://hw:0,0 --sout '#transcode{acodec=mpga,ab=128,channels=2,samplerate=44100}:std{access=http,mux=ts,dst=192.168.0.100:8080}'

Thank you for your assistance, without your advice to use alsa://<device-name> i would not have succeeded.
Best wishes,
dihfg

Re: Can VLC stream the input from the soundcard ?

Posted: 24 May 2010 12:33
by bishal
How can I find out which hardware device my onboard sound card is using? Like:
alsa://
alsa://hw:0,0

Re: Can VLC stream the input from the soundcard ?

Posted: 18 Dec 2013 22:00
by Geremia
Yes, I'd like to know this, too, so I can record both my mic and the soundcard's output simultaneously.