Commit graph

18 commits

Author SHA1 Message Date
Hans Petter Selasky
e66a5ac7ef audio/alsa-plugins: Fix more oss_pointer() calculation bugs.
Correctly set the water level based on min_avail to avoid infinite
polling loops.

Applications tested: chrome, musescore, aplay and arecord .

PR:		261767
Approved by:	pi (implicit)
2022-02-08 10:15:40 +01:00
Hans Petter Selasky
472a942f9c audio/alsa-plugins: Fix two bugs in ALSA OSS backend.
When computing the oss_pointer() return value, use the application
pointer value as reference, so that ALSA audio applications at any
time don't read/write more audio data than is possible. Following the
cyclic DMA pointer is not a good idea, because it doesn't account for
under- or overruns and this quickly leads to a situation where some
applications may want to write more data, ending in infinite loops.

The SNDCTL_DSP_GET space ioctls operate on buffer fragments. Any
size less than bi.fragsize is reported as zero bytes. Don't set the
water level less than bi.fragsize, because it leads to infinite
polling the way ALSA PCM is working.

Approved by: pi (implicit)
2022-01-30 15:54:47 +01:00
Hans Petter Selasky
fedba31a63 audio/alsa-plugins: Try to cleanup ALSA-OSS backend patch.
Approved by: pi (implicit)
2022-01-29 18:56:52 +01:00
Hans Petter Selasky
2738adad73 audio/alsa-plugins: Merge ALSA-OSS patches to simplify future patching.
Approved by: pi (implicit)
2022-01-29 18:56:52 +01:00
Dag-Erling Smørgrav
a4ab68d2ff audio/alsa-plugins: Switch master site to GitHub.
The original distfiles are getting hard to come by for some reason, so
switch to pulling source tarballs directly from GitHub.  Replace
patches that apply to generated files with patches that apply to their
sources.
2021-10-13 15:14:24 +00:00
Jan Beich
a185384bd9 audio/alsa-plugins: move r505839 to the correct file
files/alsa-plugins.patch contains an assortment of FreeBSD-specific
improvements that may not work on alternative OSS implementations.
So, restore the ability to exclude the patch for debugging.
2019-12-03 04:33:21 +00:00
Jan Beich
a3f26bc3b9 audio/alsa-plugins: regen via "make makepatch" 2019-12-03 04:33:06 +00:00
Hans Petter Selasky
38b2315add Fix issues with ALSA OSS backend for firefox and chrome.
1) When read() or write() fails due to EAGAIN because no buffer is available or
   buffer is full, return 0 instead of failure. Else clients may simply close
   the device and re-open it instantly chopping the audio.
2) Implement OSS delay function to fix an issue with negative delays.
3) Use at least 16ms of HW buffer by default to avoid jitter.

Approved by:	pi, jbeich
2019-07-04 15:46:15 +00:00
Mathieu Arnold
9fa9eb9ac7 Cleanup patches, a* categories.
Rename them to follow the make makepatch naming, and regenerate them.

With hat:	portmgr
Sponsored by:	Absolight
2016-07-26 16:51:15 +00:00
Jan Beich
49190875e4 audio/alsa-*: update to 1.1.1
Changes:	http://www.alsa-project.org/main/index.php/Changes_v1.1.0_v1.1.1
ABI:		https://people.freebsd.org/~jbeich/compat_reports/alsa-lib/1.1.0_to_1.1.1/compat_report.html
2016-04-01 20:44:23 +00:00
Jan Beich
261593e7c5 audio/alsa-plugins: prepare for ffmpeg 3.0 update
Obtained from:	upstream
2016-02-27 19:51:47 +00:00
John Marino
46b7762a82 audio/alsa-(lib|plugins|utils): Upgrade version 1.0.27.2 => 1.0.28
Also switch maintainership to submitter with blessing of former
maintainer.  Other changes include:

  * fix for bug 191190
  * Use new options syntax
  * Proper detection of PYTHON and FFMPEG
  * fix leftovers
  * strip libraries to satisfy stage-qa
  * conf: alias surround stuff to pcm.default
  * lib: split patches and refactor
  * utils: rename XMLTO to MANPAGES

PR:		191524
Submitted by:	Jan Beich
Approved by:	former maintainer (Aragon Gouveia)
2014-08-09 15:20:35 +00:00
Florian Smeets
50cfc58f27 - ALSA now supports playing HTML5 audio with 32-bit sample format [1]
after being converted from float as passed by firefox/libcubeb [2]
- Restore behavior from r296140 while adding alignment options in case
  of issues. This should make things slightly less broken and add more
  sample formats. [1]
- Some apps (e.g. linux-firefox with ports/169896) don't check with ALSA
  which sample formats are supported and just feed whatever they like,
  assuming the underlying device supports it.
  While here also fix mixer device for OSS plugin. It should be /dev/dsp
  according to 4Front OSS wiki. The only works with ARIFF_OSS enabled
  but the volume is reset on close(). audio/oss doesn't work either way:
  the new (OSSv4) way to control mixer is via SNDCTL_MIX_* ioctls. [2]

PR:		ports/183861 [1]
PR:		ports/184006 [2]
Submitted by:	Jan Beich <jbeich@tormail.org>
Approved by:	maintainer timeout
2013-12-14 14:41:17 +00:00
William Grzybowski
98bfd02249 audio/alsa-plugins: fix build with newer ffmpeg
- Fix build with newer ffmpeg

Reported by:	Kevin Oberman <rkoberman gmail.com>
Approved by:	portmgr (bapt, implicit)
2013-10-23 00:30:15 +00:00
Florian Smeets
d3c505e600 - update to 1.0.26 [1]
- use newly added alphasort() instead of LGPLv2.1+ patch
- fix async handler [2]
- fix implicit declarations of calloc/free [3]
- disable ARIFF_OSS option by default, except 7.x [4]
- add 3 more mirrors from alsa wiki + gentoo as a backup
- move alsa mirrors to bsd.sites.mk

Changes:	http://www.alsa-project.org/main/index.php/Changes_v1.0.25_v1.0.26
PR:		ports/171601 [1]
PR:		ports/169770 [2]
PR:		ports/170457 [3]
PR:		ports/170473 [4]
Obtained from:	PkgSrc [2]
Submitted by:	Jan Beich <jbeich@tormail.org>
Approved by:	maintainer
2012-10-04 17:04:44 +00:00
Sunpoet Po-Chuan Hsieh
a28a1142b4 - Update to 1.0.25
- Convert to new options framework
- alsa-plugins:
  - Add option: ARIFF_OSS for FreeBSD-specific patch
  - Revert ports/165247 per regression in ports/169767
  - Unbreak arcam-av and usb_stream plugins
- While I'm here, pet portlint by removing ABI version number from LIB_DEPENDS

Changes:	http://www.alsa-project.org/main/index.php/Changes_v1.0.24_v1.0.25
		http://www.alsa-project.org/main/index.php/Changes_v1.0.23_v1.0.24
PR:		ports/169841
Submitted by:	Jan Beich <jbeich@tormail.org> (maintainer)
2012-07-20 03:03:56 +00:00
Chris Rees
59632ff58f Since r221388 and its MFCs SNDCTL_DSP_GETIPTR should work correctly
on FreeBSD and should not require any quirks/workarounds.
In fact they seem to be harmful now and result in sound outages.

PR:		ports/165247
Submitted by:	avg
Submitted by:	Aragon Gouveia <aragon@phat.za.net> (maintainer)
2012-05-07 15:23:52 +00:00
Dima Panov
4070922aac - New port: audio/alsa-plugins Compatibility layer for ALSA support
PR:		145965
Submitted by:	Aragon Gouveia <aragon AT phat.za.net>
2010-06-05 12:46:16 +00:00