Commit graph

478 commits

Author SHA1 Message Date
Bill Currie
d9ab3a1f54 Move the config file/command line parsing into qargs.c
I don't like the COM prefix, but it will do for now.
2011-09-11 14:57:05 +09:00
Bill Currie
a71acc9ae5 Move the essential init code into Sys_Init(). 2011-09-11 14:56:47 +09:00
Bill Currie
da7ddc35c0 Fix the segaults when trying to use snd_disk.
It's output is still bogus (and it writes to the current directory!), but
at least the plugin can be used without any nasty issues.
2011-09-10 12:07:18 +09:00
Bill Currie
a426dacc8a Add a missing \n 2011-09-09 17:43:48 +09:00
Bill Currie
881d4babce Fix some undefined symbols in snd_alsa.c.
Serves me right for testing with only my debug build :P
2011-09-08 18:10:09 +09:00
Bill Currie
2ae33a753a Support non-interleaved mmap sound.
Unfortuanately, I can't test this properly as I don't have any such
hardware, but as the code is mosly an edited copy of the interleaved code,
any errors should be easy to fix.
2011-09-07 17:00:57 +09:00
Bill Currie
a8ea3aaad9 Allow dma sound targets to specify an xfer function. 2011-09-07 17:00:18 +09:00
Bill Currie
9ffa1f410a Detect the silent death of the jack client thread.
When jackd gets an unhandled xrun, it stops all processing but neglects to
tell the client about it. Thus, add a bit of a watchdog function to
s_update() and assume the client thread is dead if there's no sign of life
after one second. No more hanging on exit.
2011-09-07 15:16:27 +09:00
Bill Currie
f75b0a611b Some compile fixes for OpenBSD 2011-08-25 22:35:20 +09:00
Bill Currie
c1a60551ae Clean up default rate setting and add explicit support for 48kHz. 2011-08-11 17:22:14 +09:00
Bill Currie
5feb0454ca Add and use SYS_SND for both sound and cd debug prints. 2011-08-11 17:20:33 +09:00
Bill Currie
28610c08e3 Do not try to build testsound when not building sound libs. 2011-07-30 15:03:19 +09:00
Bill Currie
9ccd570105 Fix a problem with linking FLAC libs. 2011-07-23 21:37:34 +09:00
Bill Currie
efa0105748 Rename some headers to fix doxygen warnings. 2011-07-23 15:58:45 +09:00
Antti Harri
358a844a42 Implement --version-info configure switch to override QuakeForge
library versioning. From Lasse Collin, thanks!
2011-07-09 01:23:36 +03:00
Bill Currie
47201137d5 Make the default cd plugin configurable.
The default default is file, but now distribution maintainers can change it
if necessary.
2011-06-04 17:19:18 +09:00
Antti Harri
8d1bd58ade snd_dma.c fixes for non-power-of-two values. From Jacob Meuser. 2011-06-04 09:47:15 +03:00
Antti Harri
67c7796c0b Change default music backend from OGG to CD. 2011-05-31 00:05:35 +03:00
Bill Currie
74a7e07dfc Use AM_CFLAGS instead of CFLAGS.
CFLAGS is meant to be reserved for the user.
2011-05-10 12:44:44 +09:00
Bill Currie
f17b1275ea Undo an accidental commit. 2011-05-10 11:48:38 +09:00
Bill Currie
77ccf8a824 Build the audio libs before the test dir. 2011-05-10 11:32:38 +09:00
Bill Currie
f7a95ec2f4 Move the test program into its own directory.
This is to avoid issues with -prefer-pic (really need to clean things up
properly).
2011-05-10 11:25:12 +09:00
Bill Currie
70783e4bd5 Disable all sound calls if jack could not be contacted.
This fixes the file handle leak when jack is unavailable.
2010-12-25 20:31:14 +09:00
Jeff Teunissen
9defba8d92 Get rid of plugin versioning (again).
automake needs -avoid-version to be in Makefile.am, otherwise it doesn't
make libtool do the right thing...or something. My head hurts. ;)
2010-12-25 04:45:39 -05:00
Bill Currie
ce64227a71 Fix for debian wildmidi.
This might break lenny :/
2010-12-24 17:33:09 +09:00
Bill Currie
de04e1b602 Lots of win32 (mingw cross) build fixes.
HTTP (curl) support is missing, but everything else builds.
2010-12-23 11:40:16 +09:00
Bill Currie
889bbd364e Explicitly link testsound against libQFutil. 2010-12-18 22:21:55 +09:00
Bill Currie
765807def0 Make sdl's sound parameters easy to tweak. 2010-12-15 18:48:25 +09:00
Bill Currie
d265bbf011 Support any sample rate. 2010-12-15 18:48:25 +09:00
Bill Currie
df65679028 Remove support for alsa 0.9.
It's way obsolete and I doubt we'll ever need it again. I do wonder what to
do abut sun, sgi etc.
2010-12-15 18:48:25 +09:00
Ragnvald Maartmann-Moe IV
843823de84 testsound depends on libQFutil 2010-12-10 17:07:06 +09:00
Bill Currie
185e21e4e4 Tweak some developer cvar usage. 2010-11-27 16:53:17 +09:00
Bill Currie
8c4fe2f844 Rename Sys_DPrintf to Sys_MaskPrintf.
We now have finer runtime control over what gets printed. Need to do a
SYS_DEV audit, creating new masks as apropriate.
2010-11-26 16:19:26 +09:00
Bill Currie
1dfb914c46 fix an oopsie (rebase!!) 2010-11-21 14:25:32 +09:00
Bill Currie
4cec187465 zixthree's wav file patch
Wav file were not read correctly when encoutering most chunk type beside the ones used by QuakeForge.

This patch will fix the riff loader code so that unused but defined chunk are skipped. Most wav files should now be loaded correctly fixing some silent sound effect.

Also fixed a typo in wav loader and reordered wav validity check so that format is checked first. The data chunk could be inexistant on some weird format and so an invalid format is a more helpful error text.

! Fix: Skip unsupported chunk in riff loader instead of rejecting riff file.
! Fix: typo in Microsoft name.
! Fix: ordering of wav validity to enable more helpful error text.
2010-11-21 14:18:15 +09:00
Bill Currie
99e87b092b zixthree's stereo swap patch.
Modified slightly for formatting and cleaner swapping.
2010-11-21 14:09:23 +09:00
Bill Currie
15b423cbe7 Track 0 is used to stop the BGM 2010-11-20 14:32:27 +09:00
Bill Currie
37fb8d22da Don't open a streamed sfx when there's no sound driver.
This happens when qf fails to connect to jackd (possibly other times).
There is probably a better solution to the problem, but not opening a
stream when the sample rate is reported as 0 definitely fixes the inifinite
recursion in read_samples().
2010-11-14 20:46:29 +09:00
Bill Currie
f666f8d27a Get the lib dependency for testsound right.
No need for $(top_builddir) when the lib is in the same directory. Fixes
parallel builds.
2010-09-25 23:07:06 +09:00
Bill Currie
5a6e66b23e hopefully, correct plugin linking options
how we got away with this for so long is beyond me, but it seems libtool
really wants -rpath even for plugins (otherwise it refuses to install them)
2010-08-21 13:01:35 +09:00
Bill Currie
1442273a8f more opaque correctness 2010-08-20 12:58:37 +09:00
Bill Currie
4449f10c0a get alsa and sdl working, though sdl seems to be mono only 2010-08-15 05:15:47 +00:00
Bill Currie
bc4a3e79dc d'oh, bogus $ 2010-08-14 02:48:53 +00:00
Bill Currie
81ac779b7f forgot to add libsamplerate to the default renderer 2010-08-14 02:38:19 +00:00
Bill Currie
cc697236e5 bah, forgot that libsamplerate doesn't check for errors 2010-08-13 01:48:48 +00:00
Bill Currie
54fc922f6c better error checking while reading streamed data 2010-08-13 01:48:20 +00:00
Bill Currie
ce5658416d add support for up to 8 channels in sound effect files
The sounds are down-mixed to 2 channels (qf does not (yet) support more than
2 channel output), but this allows pretty much anything to be used for a
source of music. Only 5.1 (6 channel), stereo and mono have been tested, but
the others should work (any issues would be mis-interpretation/implementation
of the channel layout).
2010-08-12 02:28:27 +00:00
Bill Currie
b1620616b9 reset the "resampler" when seeking 2010-08-11 23:47:31 +00:00
Bill Currie
22e8698827 resampling now works
However, no fallback for when libsamplerate is missing.
2010-08-11 23:47:03 +00:00
Bill Currie
1c985bc925 bah, forgot these 2010-08-11 23:46:28 +00:00