开发者

How to control master volume in linux/c++?

Specifically, I'm using Fedora 13 but I believe the code would be similar across any Gnome-ish flavor of Linux. I just need to be able to adjust the master volume using C++, and accomplish the exact same effect开发者_运维知识库 as if I had moved the slider up and down on the speaker icon in the "system tray." What's the best and easiest way to code this?


You just have to use the Alsa library. Or you could cheat and subprocess the amixer program.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜