From owner-svn-ports-all@freebsd.org Sat Apr 16 17:17:14 2016 Return-Path: Delivered-To: svn-ports-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5C10EB10589; Sat, 16 Apr 2016 17:17:14 +0000 (UTC) (envelope-from rakuco@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 16B9611A3; Sat, 16 Apr 2016 17:17:14 +0000 (UTC) (envelope-from rakuco@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u3GHHDaZ058028; Sat, 16 Apr 2016 17:17:13 GMT (envelope-from rakuco@FreeBSD.org) Received: (from rakuco@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u3GHHD33058026; Sat, 16 Apr 2016 17:17:13 GMT (envelope-from rakuco@FreeBSD.org) Message-Id: <201604161717.u3GHHD33058026@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: rakuco set sender to rakuco@FreeBSD.org using -f From: Raphael Kubo da Costa Date: Sat, 16 Apr 2016 17:17:13 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r413463 - in head/multimedia/qt5-multimedia: . files X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 16 Apr 2016 17:17:14 -0000 Author: rakuco Date: Sat Apr 16 17:17:12 2016 New Revision: 413463 URL: https://svnweb.freebsd.org/changeset/ports/413463 Log: Add patch to fix underrun errors in the ALSA plugin. The ALSA plugin doesn't suspend the ALSA device when the ::suspend() method is called. This results in underrun errors when it's resumed. In ALSA, stopping a pcm doesn't close it, so the ALSA stop/start functions map to the QAudioInput suspend/resume functions. PR: 208598 Submitted by: shurd MFH: 2016Q2 Added: head/multimedia/qt5-multimedia/files/patch-git_9047d9b (contents, props changed) Modified: head/multimedia/qt5-multimedia/Makefile Modified: head/multimedia/qt5-multimedia/Makefile ============================================================================== --- head/multimedia/qt5-multimedia/Makefile Sat Apr 16 17:09:17 2016 (r413462) +++ head/multimedia/qt5-multimedia/Makefile Sat Apr 16 17:17:12 2016 (r413463) @@ -2,6 +2,7 @@ PORTNAME= multimedia DISTVERSION= ${QT5_VERSION} +PORTREVISION= 1 CATEGORIES= multimedia PKGNAMEPREFIX= qt5- Added: head/multimedia/qt5-multimedia/files/patch-git_9047d9b ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/multimedia/qt5-multimedia/files/patch-git_9047d9b Sat Apr 16 17:17:12 2016 (r413463) @@ -0,0 +1,36 @@ +commit 9047d9b84e9d94d193e77abd81f5980eff77d73a +Author: Stephen Hurd +Date: Thu Apr 14 19:11:01 2016 -0700 + + ALSA: Call snd_pcm_drain() on suspend + + The ALSA plugin previously didn't suspend the ALSA device when the + ::suspend() method is called. This results in underrun errors when + it's resumed. + + In ALSA, stopping a pcm doesn't close it, so the ALSA stop/start + functions map to the QAudioInput suspend/resume functions. + + Change-Id: I2507065a1b7472af29eef70c531b9f6e8e5b3072 + Reviewed-by: Christian Stromme + +--- src/plugins/alsa/qalsaaudioinput.cpp ++++ src/plugins/alsa/qalsaaudioinput.cpp +@@ -701,6 +701,7 @@ qint64 QAlsaAudioInput::processedUSecs() const + void QAlsaAudioInput::suspend() + { + if(deviceState == QAudio::ActiveState||resuming) { ++ snd_pcm_drain(handle); + timer->stop(); + deviceState = QAudio::SuspendedState; + emit stateChanged(deviceState); +--- src/plugins/alsa/qalsaaudiooutput.cpp ++++ src/plugins/alsa/qalsaaudiooutput.cpp +@@ -673,6 +673,7 @@ QAudioFormat QAlsaAudioOutput::format() const + void QAlsaAudioOutput::suspend() + { + if(deviceState == QAudio::ActiveState || deviceState == QAudio::IdleState || resuming) { ++ snd_pcm_drain(handle); + timer->stop(); + deviceState = QAudio::SuspendedState; + errorState = QAudio::NoError;