From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Sebastian H." Subject: Re: snd_mixer handle in two threads Date: Wed, 09 Jun 2010 18:59:11 +0200 Message-ID: <4C0FC85F.1000006@gmx.de> References: <4C0F919D.1040603@gmx.de> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail.gmx.net (mail.gmx.net [213.165.64.20]) by alsa0.perex.cz (Postfix) with SMTP id C1824103967 for ; Wed, 9 Jun 2010 18:58:49 +0200 (CEST) In-Reply-To: <4C0F919D.1040603@gmx.de> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: alsa-devel-bounces@alsa-project.org Errors-To: alsa-devel-bounces@alsa-project.org To: alsa-devel@alsa-project.org List-Id: alsa-devel@alsa-project.org Am 09.06.2010 15:05, schrieb Sebastian H.: > Hello again > > This is still about the alsamixer-qt4 application I working on. > > This time I wonder if a snd_mixer_t handle created with > snd_mixer_open ( ... ) can be used in two threads concurrently. > > One thread should be the main Qt4 GUI thread and the second thread > should only poll ( ... ) blocking for ALSA events on the shared > snd_mixer_t handle in accompany with > > snd_mixer_poll_descriptors_count ( ... ) > snd_mixer_poll_descriptors ( ... ) > snd_mixer_poll_descriptors_revents ( ... ) > > The second thread then will post Qt4 signals to the main thread > on occassion. Nevermind, QSocketNotifier solved the issue in a better way. Sebastian