· [Java论坛][安全论坛][数据库论坛][操作系统论坛]
· [访谈] 网银安全系列访谈之:惊心动魄网银故事
· [热点专题] 网银安全系列 3G上网卡巡礼
· [订阅IT技术周刊][IT资源下载专区][病毒求助专区]
· [热点] 跨站脚本十二问 四步防范Conficker
· [热点] Windows 7 RC版公开下载 憾缺中文版

Ubuntu Linux系统下声卡独占的解决方法

发布时间:2008.06.06 05:39     来源:赛迪网    作者:sixth

A much better way of getting esd to work with non-esd-aware apps is to make alsa use its software mixer.

让alsa用它自己的软件混合器一个更好的方法来让esd和不是esd识别的应用程序在一起工作

$ sudo /etc/init.d/alsa-utils stop $ sudo gedit /var/lib/alsa/asound.state

(add the following text verbatim to the start of this file)

$ sudo /etc/init.d/alsa-utils start

# This text should be added to the beginning of

# /var/lib/alsa/asound.state. You only need to add

# it once -- it is saved across reboots.

pcm.asymed {

type asym

playback.pcm dmix

capture.pcm dsnoop

}

pcm.default {

type plug

slave.pcm asymed

}

pcm.dmix {

type dmix

ipc_key 5678293

ipc_key_add_uid yes

slave {

pcm 'hw:0,0'

period_time 0

period_size 128

buffer_size 2048

format S16_LE

rate 48000

}

}

pcm.dsnoop {

type dsnoop

ipc_key 5778293

ipc_key_add_uid yes

slave {

pcm 'hw:0,0'

period_time 0

period_size 128

buffer_size 2048

format S16_LE

rate 48000

}

}

Now as many programs as you want can all use the sound card simultaneously, both the output and the microphone! ESD-aware apps can use ESD, other apps will still work fine.

现在,你可以让你想要的软件全部同时使用声卡, 不管是输出还是和麦克风!ESD识别的应用程序可以使用ESD,另外的应用程序也一样可以正常工作.

One notable misfeature of ESD is that it often ruins the A/V sync when playing videos. After setting up the software mixer, you might find it useful to turn esd off altogether (in tthe Sound control panel uncheck "Enable Software Mixing"). Now, especially with GStreamer 0.10, your movies should have perfect A/V sync.

一个ESD很显着的不好的特性就是在播放视频的时候它会破坏在音频与视频的同步.在设定好软件混合器以後, 你可能会发觉把esd关闭会有些帮助(在音频控制面板里边反选"开启software mixing'). 现在, 特别是在GStreamer 0.10下, 你的电影应该不会有音频和视频不同步发生了. It's a shame that software mixing isn't enabled on Ubuntu by default. software mixing在ubuntu的预设里边不是开启的.

按照这个设置好之后并没有马上生效。

(责任编辑:云子)


[ 发表评论 ] 字体[  ] [ 打印 ] [ 进入博客 ] [ 进入论坛 ]  [ 推荐给朋友 ]
  相关文章
· Linux下安装Realplayer不能播放启动问题 (06-05) · 关于Linux和Windows文件路径的解决办法 (06-05)
· 让Amarok支持RealyPlayer的所有媒体格式 (06-04) · 在Fedora 9下面配置ISATAP IPV6 tunnel (06-04)
· 本地ISO或光盘作Fedora软件源进行软件管理 (06-04) · Fedora Linux系统下挂载U盘和Windows盘 (06-04)
· 在Linux系统下批量改变文件名字的大小写 (06-04) · 用VNC连接Linux操作系统服务器配置方法 (06-04)
· Linux下通过Samba添加Windows共享打印机 (06-04) · 第一个Linux病毒是在哪一年哪个地方爆出 (06-04)
  客户需求反馈表
* 姓  名:
更多资料  了解方案  认识厂商
* 单位名称:
* 联系电话:
* 电子邮件:
资讯 通信 IT产品 IT技术 信息化
2009第七届中国电脑商年会直播
·创业投资系列访谈:产业..
·特别策划:视频网站系列..
·专题:网游虚拟货币新规..
专题:6月上市手机新品回顾及7月新机展望
·2009年中国电信业信息化..
·专题:把iPhone 3GS“解..
·WAPI重启国际标准进程 ..
专题:09年中盘点-联想春季打印机新品回顾
·InfoComm 2009 视听与集..
·网游背后的故事 网游服..
·[专题]联想ThinkPad T40..
BizSpark:微软为技术创业企业点燃火花
·社区活动:我的IT求知生..
·访谈:内网安全2009系列..
·安全访谈:网银安全之Sa..