| View previous topic :: View next topic |
| Author |
Message |
funkoolow
Joined: 29 Sep 2009 Posts: 7
|
Posted: Tue Sep 04, 2012 2:13 pm Post subject: grab & stream audio played from vlc on desktop |
|
|
hi all,
i'm getting mad at this, i need to stream the WHOLE audio played on the machine by a desktop user via vlc, mplayer or whatever.
I've already been able to set up the streaming from a playlist or from line input using icecast2 + ices2 and all went fine. What seems impossible is grabbing the whole soundcard output...
my cfg follows (for the ices-alsa that correctly streams mic input but excludes audio played by vlc)
icecast.xml
| Code: |
<icecast>
<limits>
<clients>100</clients>
<sources>2</sources>
<threadpool>5</threadpool>
<queue-size>524288</queue-size>
<client-timeout>30</client-timeout>
<header-timeout>15</header-timeout>
<source-timeout>10</source-timeout>
<burst-on-connect>1</burst-on-connect>
<burst-size>65535</burst-size>
</limits>
<authentication>
<source-password>mypw</source-password>
<relay-password>mypw</relay-password>
<admin-user>admin</admin-user>
<admin-password>mypw</admin-password>
</authentication>
<hostname>localhost</hostname>
<listen-socket>
<port>8000</port>
</listen-socket>
<fileserve>1</fileserve>
<paths>
<basedir>/usr/share/icecast2</basedir>
<logdir>/var/log/icecast2</logdir>
<webroot>/usr/share/icecast2/web</webroot>
<adminroot>/usr/share/icecast2/admin</adminroot>
<alias source="/" dest="/status.xsl"/>
</paths>
<logging>
<accesslog>access.log</accesslog>
<errorlog>error.log</errorlog>
<loglevel>4</loglevel> <!-- 4 Debug, 3 Info, 2 Warn, 1 Error -->
<logsize>10000</logsize> <!-- Max size of a logfile -->
</logging>
<security>
<chroot>0</chroot>
<changeowner>
<user>icecast2</user>
<group>icecast</group>
</changeowner>
</security>
<mount>
<mount-name>/playlist.ogg</mount-name>
<max-listeners>5</max-listeners>
</mount>
<mount>
<mount-name>/live.ogg</mount-name>
<max-listeners>7</max-listeners>
<dump-file>/tmp/test.ogg</dump-file>
<fallback-mount>/playlist.ogg</fallback-mount>
<fallback-override>1</fallback-override>
</mount>
</icecast>
|
ices.xml
| Code: |
<?xml version="1.0"?>
<ices>
<background>0</background>
<logpath>/var/log/ices</logpath>
<logfile>ices.log</logfile>
<logsize>2048</logsize>
<loglevel>4</loglevel>
<consolelog>0</consolelog>
<stream>
<metadata>
<name>Example stream name</name>
<genre>Example genre</genre>
<description>A short description of your stream</description>
<url>http://mysite.org</url>
</metadata>
<input>
<module>alsa</module>
<param name="rate">48000</param>
<param name="channels">2</param>
<param name="device">hw:0,0</param>
<param name="metadata">1</param>
<param name="metadatafilename">test</param>
</input>
<instance>
<hostname>localhost</hostname>
<port>8000</port>
<password>mypw</password>
<mount>/live.ogg</mount>
<yp>1</yp>
<encode>
<quality>0</quality>
<samplerate>22050</samplerate>
<channels>1</channels>
</encode>
<downmix>1</downmix>
<resample>
<in-rate>48000</in-rate>
<out-rate>22050</out-rate>
</resample>
</instance>
</stream>
</ices> |
i've already tried messing on alsamixer, but even if the capture is on mix the stream remains silent. but as said before all seems to be functional since the line input is played.
thanks in advance to anyone able to help |
|
| Back to top |
|
 |
karlH Code Warrior

Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Tue Sep 04, 2012 5:28 pm Post subject: |
|
|
your description would indicate a mixer issue, or maybe pulseaudio is involved. If alsa only then check for the capture toggle, capture slider, input source or similar controls.
karl. |
|
| Back to top |
|
 |
funkoolow
Joined: 29 Sep 2009 Posts: 7
|
|
| Back to top |
|
 |
karlH Code Warrior

Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Tue Sep 04, 2012 6:01 pm Post subject: |
|
|
I've no idea what sound device you are using, what are the controls that are available. eg what is reported with
amixer -c 0 scontents
karl. |
|
| Back to top |
|
 |
funkoolow
Joined: 29 Sep 2009 Posts: 7
|
Posted: Tue Sep 04, 2012 7:04 pm Post subject: |
|
|
here's the output of yout command
| Code: |
Simple mixer control 'Master',0
Capabilities: pswitch pswitch-joined penum
Playback channels: Mono
Mono: Playback [on]
Simple mixer control 'Master Mono',0
Capabilities: pvolume pvolume-joined pswitch pswitch-joined penum
Playback channels: Mono
Limits: Playback 0 - 31
Mono: Playback 31 [100%] [0.00dB] [on]
Simple mixer control 'PCM',0
Capabilities: pvolume pswitch pswitch-joined penum
Playback channels: Front Left - Front Right
Limits: Playback 0 - 31
Mono:
Front Left: Playback 31 [100%] [0.00dB] [on]
Front Right: Playback 31 [100%] [0.00dB] [on]
Simple mixer control 'Surround',0
Capabilities: pvolume pswitch penum
Playback channels: Front Left - Front Right
Limits: Playback 0 - 31
Mono:
Front Left: Playback 31 [100%] [0.00dB] [off]
Front Right: Playback 31 [100%] [0.00dB] [off]
Simple mixer control 'Surround Jack Mode',0
Capabilities: enum
Items: 'Shared' 'Independent'
Item0: 'Shared'
Simple mixer control 'Center',0
Capabilities: pvolume pvolume-joined pswitch pswitch-joined penum
Playback channels: Mono
Limits: Playback 0 - 31
Mono: Playback 31 [100%] [0.00dB] [off]
Simple mixer control 'LFE',0
Capabilities: pvolume pvolume-joined pswitch pswitch-joined penum
Playback channels: Mono
Limits: Playback 0 - 31
Mono: Playback 31 [100%] [0.00dB] [off]
Simple mixer control 'Line',0
Capabilities: pvolume pswitch pswitch-joined cswitch cswitch-exclusive penum
Capture exclusive group: 0
Playback channels: Front Left - Front Right
Capture channels: Front Left - Front Right
Limits: Playback 0 - 31
Front Left: Playback 31 [100%] [12.00dB] [on] Capture [off]
Front Right: Playback 31 [100%] [12.00dB] [on] Capture [off]
Simple mixer control 'CD',0
Capabilities: pvolume pswitch pswitch-joined cswitch cswitch-exclusive penum
Capture exclusive group: 0
Playback channels: Front Left - Front Right
Capture channels: Front Left - Front Right
Limits: Playback 0 - 31
Front Left: Playback 31 [100%] [12.00dB] [on] Capture [off]
Front Right: Playback 31 [100%] [12.00dB] [on] Capture [off]
Simple mixer control 'Mic',0
Capabilities: pvolume pvolume-joined pswitch pswitch-joined cswitch cswitch-exclusive penum
Capture exclusive group: 0
Playback channels: Mono
Capture channels: Front Left - Front Right
Limits: Playback 0 - 31
Mono: Playback 31 [100%] [12.00dB] [on]
Front Left: Capture [off]
Front Right: Capture [off]
Simple mixer control 'Mic Boost (+20dB)',0
Capabilities: pswitch pswitch-joined penum
Playback channels: Mono
Mono: Playback [off]
Simple mixer control 'Mic Select',0
Capabilities: enum
Items: 'Mic1' 'Mic2'
Item0: 'Mic1'
Simple mixer control 'Video',0
Capabilities: pvolume pswitch pswitch-joined cswitch cswitch-exclusive penum
Capture exclusive group: 0
Playback channels: Front Left - Front Right
Capture channels: Front Left - Front Right
Limits: Playback 0 - 31
Front Left: Playback 31 [100%] [12.00dB] [on] Capture [off]
Front Right: Playback 31 [100%] [12.00dB] [on] Capture [off]
Simple mixer control 'Phone',0
Capabilities: pvolume pvolume-joined pswitch pswitch-joined cswitch cswitch-exclusive penum
Capture exclusive group: 0
Playback channels: Mono
Capture channels: Front Left - Front Right
Limits: Playback 0 - 31
Mono: Playback 31 [100%] [12.00dB] [on]
Front Left: Capture [off]
Front Right: Capture [off]
Simple mixer control 'IEC958',0
Capabilities: pswitch pswitch-joined cswitch cswitch-joined penum
Playback channels: Mono
Capture channels: Mono
Mono: Playback [off] Capture [off]
Simple mixer control 'IEC958 Capture Monitor',0
Capabilities: pswitch pswitch-joined penum
Playback channels: Mono
Mono: Playback [off]
Simple mixer control 'IEC958 Capture Valid',0
Capabilities: pswitch pswitch-joined penum
Playback channels: Mono
Mono: Playback [off]
Simple mixer control 'IEC958 Output',0
Capabilities: pswitch pswitch-joined penum
Playback channels: Mono
Mono: Playback [off]
Simple mixer control 'IEC958 Playback AC97-SPSA',0
Capabilities: volume volume-joined penum
Playback channels: Mono
Capture channels: Mono
Limits: 0 - 3
Mono: 3 [100%]
Simple mixer control 'IEC958 Playback Source',0
Capabilities: enum
Items: 'Analog' 'Digital'
Item0: 'Analog'
Simple mixer control 'PC Speaker',0
Capabilities: pvolume pvolume-joined pswitch pswitch-joined penum
Playback channels: Mono
Limits: Playback 0 - 15
Mono: Playback 15 [100%] [0.00dB] [on]
Simple mixer control 'Aux',0
Capabilities: pvolume pswitch pswitch-joined cswitch cswitch-exclusive penum
Capture exclusive group: 0
Playback channels: Front Left - Front Right
Capture channels: Front Left - Front Right
Limits: Playback 0 - 31
Front Left: Playback 31 [100%] [12.00dB] [on] Capture [off]
Front Right: Playback 31 [100%] [12.00dB] [on] Capture [off]
Simple mixer control 'Mono Output Select',0
Capabilities: enum
Items: 'Mix' 'Mic'
Item0: 'Mix'
Simple mixer control 'Capture',0
Capabilities: cvolume cswitch cswitch-joined penum
Capture channels: Front Left - Front Right
Limits: Capture 0 - 15
Front Left: Capture 2 [13%] [3.00dB] [on]
Front Right: Capture 2 [13%] [3.00dB] [on]
Simple mixer control 'Mix',0
Capabilities: cswitch cswitch-exclusive penum
Capture exclusive group: 0
Capture channels: Front Left - Front Right
Front Left: Capture [on]
Front Right: Capture [on]
Simple mixer control 'Mix Mono',0
Capabilities: cswitch cswitch-exclusive penum
Capture exclusive group: 0
Capture channels: Front Left - Front Right
Front Left: Capture [off]
Front Right: Capture [off]
Simple mixer control 'Channel Mode',0
Capabilities: enum
Items: '2ch' '4ch' '6ch'
Item0: '2ch'
Simple mixer control 'External Amplifier',0
Capabilities: pswitch pswitch-joined penum
Playback channels: Mono
Mono: Playback [off]
Simple mixer control 'Input Source Select',0
Capabilities: enum
Items: 'Input1' 'Input2'
Item0: 'Input1'
Simple mixer control 'Input Source Select',1
Capabilities: enum
Items: 'Input1' 'Input2'
Item0: 'Input1'
|
|
|
| Back to top |
|
 |
funkoolow
Joined: 29 Sep 2009 Posts: 7
|
Posted: Tue Sep 04, 2012 7:07 pm Post subject: |
|
|
and other outputs just in case
| Code: |
# lspci
00:00.0 Host bridge: VIA Technologies, Inc. VT8375 [KM266/KL266] Host Bridge
00:01.0 PCI bridge: VIA Technologies, Inc. VT8633 [Apollo Pro266 AGP]
00:09.0 Ethernet controller: 3Com Corporation 3c905C-TX/TX-M [Tornado] (rev 78)
00:10.0 USB Controller: VIA Technologies, Inc. VT82xxxxx UHCI USB 1.1 Controller (rev 80)
00:10.1 USB Controller: VIA Technologies, Inc. VT82xxxxx UHCI USB 1.1 Controller (rev 80)
00:10.2 USB Controller: VIA Technologies, Inc. VT82xxxxx UHCI USB 1.1 Controller (rev 80)
00:10.3 USB Controller: VIA Technologies, Inc. USB 2.0 (rev 82)
00:11.0 ISA bridge: VIA Technologies, Inc. VT8235 ISA Bridge
00:11.1 IDE interface: VIA Technologies, Inc. VT82C586A/B/VT82C686/A/B/VT823x/A/C PIPC Bus Master IDE (rev 06)
00:11.5 Multimedia audio controller: VIA Technologies, Inc. VT8233/A/8235/8237 AC97 Audio Controller (rev 50)
00:12.0 Ethernet controller: VIA Technologies, Inc. VT6102 [Rhine-II] (rev 74)
01:00.0 VGA compatible controller: Silicon Integrated Systems [SiS] 315PRO PCI/AGP VGA Display Adapter
# lsmod | grep snd
snd_wavefront 33066 0
snd_via82xx 20058 1
snd_cs4236 25514 0
snd_wss_lib 23410 2 snd_wavefront,snd_cs4236
snd_opl3_lib 8966 2 snd_wavefront,snd_cs4236
snd_hwdep 5412 2 snd_wavefront,snd_opl3_lib
snd_ac97_codec 100646 1 snd_via82xx
ac97_bus 1002 1 snd_ac97_codec
snd_pcm_oss 35308 0
snd_mixer_oss 13746 1 snd_pcm_oss
snd_mpu401 5123 0
snd_pcm 70694 6 snd_via82xx,snd_cs4236,snd_wss_lib,snd_ac97_codec,snd_pcm_oss
snd_page_alloc 7076 3 snd_via82xx,snd_wss_lib,snd_pcm
snd_mpu401_uart 5617 4 snd_wavefront,snd_via82xx,snd_cs4236,snd_mpu401
snd_seq_dummy 1338 0
snd_seq_oss 26722 0
snd_seq_midi 4557 0
snd_rawmidi 19056 3 snd_wavefront,snd_mpu401_uart,snd_seq_midi
snd_seq_midi_event 6003 2 snd_seq_oss,snd_seq_midi
snd_seq 47263 6 snd_seq_dummy,snd_seq_oss,snd_seq_midi,snd_seq_midi_event
snd_timer 19130 4 snd_wss_lib,snd_opl3_lib,snd_pcm,snd_seq
snd_seq_device 5700 6 snd_opl3_lib,snd_seq_dummy,snd_seq_oss,snd_seq_midi,snd_rawmidi,snd_seq
snd 54244 18 snd_wavefront,snd_via82xx,snd_cs4236,snd_wss_lib,snd_opl3_lib,snd_hwdep,snd_ac97_codec,snd_pcm_oss,snd_mixer_oss,snd_mpu401 snd_pcm,snd_mpu401_uart,snd_seq_oss,snd_rawmidi,snd_seq,snd_timer,snd_seq_device
gameport 9089 3 snd_via82xx,ns558
soundcore 6620 1 snd
|
[/code] |
|
| Back to top |
|
 |
karlH Code Warrior

Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Tue Sep 04, 2012 8:23 pm Post subject: |
|
|
looks like a number of the entries there have Capture set to off, Line, CD, Mic. What exactly are you wanting to capture?
karl. |
|
| Back to top |
|
 |
funkoolow
Joined: 29 Sep 2009 Posts: 7
|
Posted: Tue Sep 04, 2012 8:52 pm Post subject: |
|
|
| Possibly the whole output being played (that's why I selected "Mix" for capturing), is this possible? on alsamixer i cannot select more than one source for capturing... |
|
| Back to top |
|
 |
karlH Code Warrior

Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Wed Sep 05, 2012 12:58 am Post subject: |
|
|
if it's the case that only one of those can be set then ok, you may need to check into those individual settings to see what exactly they control, eg http://alsa.opensrc.org/Realtek_ALC650 describes 'IEC958 Playback AC97-SPSA' which may be indirectly affecting you. Have you tried capturing from CD or one of the other inputs?
karl. |
|
| Back to top |
|
 |
funkoolow
Joined: 29 Sep 2009 Posts: 7
|
Posted: Wed Sep 05, 2012 8:23 am Post subject: |
|
|
the only one i'm sure is working is the mic1, for which i can hear an external source playin when plugged on the soundcard plug. Can't try the cd (none available), and even aux or line seems to be not functional.
Do you think it's an issue specifically related to the chipset? if so i would try to set up some virtualboxes, thanks anyway for your great support |
|
| Back to top |
|
 |
karlH Code Warrior

Joined: 13 Jun 2005 Posts: 5476 Location: UK
|
Posted: Wed Sep 05, 2012 10:21 am Post subject: |
|
|
There always seems to be quirks with chipsets whether intentional or not so you could have a look specifically for capture on your specific chipset. Sometimes these less commonly know mixer setting can have effects just as passing arguments for the modules when they load.
Obviously arecord or ices will have a problem if the mixer is not set up quite right.
karl. |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2002 phpBB Group subRebel style by ktauber
|