🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: pl.comp.os.linux.programowanie
Article #72732

Re: Jak odczytać i zmienić systemową głośność?

#72732
From: Borneq
Date: Mon, 13 Jul 2015 06:31
14 lines
1623 bytes
W dniu 2015-07-13 o 07:06, Borneq pisze:
> Mam program w Javie, który przez JNI będzie wołał DLL w C++ która będzie
> zmieniała systemową głośność. Dla Windows znalazłem to. Dla Linuxa jest
> informacja że jest biblioteka ALSA. Czy dołączyć ją jakoś do mojej DLL,

Jest biblioteka Cross-Platform o nazwie PortAudio, tam jest funkcja:
/*
Px_OpenMixer() returns a mixer which will work with the given PortAudio
audio device. Pass 0 as the index for the first (default) mixer.
*/
PxMixer *Px_OpenMixer( void *pa_stream, int i );

Tylko nie wiem, co za strumień trzeba podać, bo przy zmianie głośności 
nie potrzeba żadnego strumienia.
Technical Details
Message-ID: <mnvm08$oa6$1@node1.news.atman.pl>
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!agh.edu.pl!news.agh.edu.pl!newsfeed2.atman.pl!newsfeed.atman.pl!.POSTED!not-for-mail
References: <mnvh06$dc6$1@node2.news.atman.pl>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!agh.edu.pl!news.agh.edu.pl!newsfeed2.atman.pl!newsfeed.atman.pl!.POSTED!not-for-mail
From: Borneq <borneq@antyspam.hidden.pl>
Newsgroups: pl.comp.os.linux.programowanie
Subject: Re: Jak odczytać i
 zmienić systemową głośność?
Date: Mon, 13 Jul 2015 08:31:36 +0200
Organization: ATMAN - ATM S.A.
Lines: 15
Message-ID: <mnvm08$oa6$1@node1.news.atman.pl>
References: <mnvh06$dc6$1@node2.news.atman.pl>
NNTP-Posting-Host: 91.239.205.105
Mime-Version: 1.0
X-Trace: node1.news.atman.pl 1436769096 24902 91.239.205.105 (13 Jul 2015 06:31:36 GMT)
X-Complaints-To: usenet@atman.pl
NNTP-Posting-Date: Mon, 13 Jul 2015 06:31:36 +0000 (UTC)
User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0
In-Reply-To: <mnvh06$dc6$1@node2.news.atman.pl>
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit