Commit graph

231 commits

Author SHA1 Message Date
Christopher Snowhill
92d29e7acf Cog Audio: Now preserves already resampled output when switching output formats 2022-01-13 19:43:18 -08:00
Christopher Snowhill
ee509b6e13 Cog Audio: Remove unnecessary preprocessor macro for RetroArch code 2022-01-13 18:01:12 -08:00
Christopher Snowhill
73348b1616 Cog Audio: Implement play position skip ahead when output format changes, based on how much converter output is being discarded 2022-01-12 23:17:07 -08:00
Christopher Snowhill
52b17bd4d8 Cog Audio: Implement virtual ring buffer function to read buffered bytes count 2022-01-12 23:16:13 -08:00
Christopher Snowhill
d1b519d59d Cog Audio: Only declare end of stream on read when previous node has declared end of stream and the buffer has actually run empty. This prevents the case where the buffer may terminate early due to the read pointer hitting the end of the ring buffer and wrapping. 2022-01-12 23:15:23 -08:00
Christopher Snowhill
ec7ac74fcd Cog Audio: Fix input chain to reset its buffers when seeking properly 2022-01-12 23:13:49 -08:00
Christopher Snowhill
cc134ce293 Cog Audio: Converter node actually pauses when it is being reconfigured, and resets its buffer when the output format is changed 2022-01-12 23:13:00 -08:00
Christopher Snowhill
b0f5a37e85 Cog Audio: Only proceed to the next track when the current track has actually finished 2022-01-12 21:53:58 -08:00
Christopher Snowhill
5fef62dd03 Cog Audio: Implemented device output and input file format changing support 2022-01-12 21:31:22 -08:00
Christopher Snowhill
9feaffc92d Cog Audio: Made RetroArch resampler safer 2022-01-12 18:45:43 -08:00
Christopher Snowhill
8664bacc60 Core Audio output: Correctly terminate output when requested to stop, preventing a case where multiple outputs were draining the playback buffer at once 2022-01-12 16:04:41 -08:00
Christopher Snowhill
2633e713a3 Cog Audio: Remove seek mess from previous commit 2022-01-12 16:03:49 -08:00
Christopher Snowhill
f1d70aaa54 Cog Audio: Add explanatory comment to source code 2022-01-12 03:36:27 -08:00
Christopher Snowhill
84d445cffe Cog Audio: Fix converter so that seeking on startup playback position resume works properly 2022-01-12 03:01:55 -08:00
Christopher Snowhill
16402f9982 RetroArch resampler: Stub out code we don't need, reducing code size 2022-01-12 03:01:55 -08:00
Christopher Snowhill
3b125c0440 Cog Audio: Improve virtual ring buffer class 2022-01-11 22:50:18 -08:00
Christopher Snowhill
a76f3c3476 Cog Audio: Reorder project files 2022-01-11 22:48:50 -08:00
Christopher Snowhill
f8e3b0e1ee Core Audio output: Some more minor changes 2022-01-11 22:06:41 -08:00
Christopher Snowhill
557e0bd399 Core Audio output: Fix so it stops properly 2022-01-11 20:38:17 -08:00
Christopher Snowhill
91c3feac2e Cog Audio converter: Fix handling signed versus unsigned for 8 bit samples 2022-01-11 19:37:47 -08:00
Christopher Snowhill
f44e4e793b Cog Audio converter: Fix end of track flush and extrapolation 2022-01-11 19:37:17 -08:00
Christopher Snowhill
ed882e25cb Cog Audio: Resampler now extrapolates into latency padding for better gapless playback 2022-01-11 18:19:30 -08:00
Christopher Snowhill
7d4841b1c6 Core Audio output: Don't upmix unless output device requests it by default 2022-01-11 18:18:38 -08:00
Christopher Snowhill
ee05fe9e44 Core Audio output: Add sanity checking for supported formats, and support 64 bit float input data, in case anything actually uses that 2022-01-11 17:09:06 -08:00
Christopher Snowhill
4dd46a1b5b Core Audio output: Fix output stopping properly 2022-01-11 07:52:44 -08:00
Christopher Snowhill
72210c67e4 Replaced AudioQueue output with AUAudioUnit 2022-01-11 07:06:40 -08:00
Christopher Snowhill
c4c9a741ef Replaced AudioToolbox converter process with homebrew solution, using the RetroArch sinc resampler 2022-01-11 04:09:19 -08:00
Christopher Snowhill
dfe92ffedc Audio Player: Fix so ReplayGain isn't reset on seek 2021-12-28 21:05:25 -08:00
Christopher Snowhill
841481599e Audio Player: Minor change 2021-12-28 21:04:46 -08:00
Christopher Snowhill
c1c21ec84f Hopefully fix glitching on seeking 2021-12-28 16:04:16 -08:00
Christopher Snowhill
486352ea72 Core Audio output: Enforce some minimum quality settings 2021-12-28 15:41:31 -08:00
Christopher Snowhill
ba3746fcff Remove blank line 2021-12-28 15:40:53 -08:00
Christopher Snowhill
476dd913b2 Audio player: Attempt to fix queue issues. There are still remaining issues if a single short track queues repeatedly and the user changes tracks manually. 2021-12-28 15:40:26 -08:00
Christopher Snowhill
38c530043d Output converter: Add more upmixing modes 2021-12-28 15:39:23 -08:00
Christopher Snowhill
b13235ec5f Fix 6.1 stereo downmix mapping 2021-12-28 00:10:44 -08:00
Christopher Snowhill
258a56a276 Audio Output: Implement more upmixing modes, and correct some upmixing behavior 2021-12-28 00:09:57 -08:00
Christopher Snowhill
ad3058c4f3 Audio Queue: Better handle a lot of short files playing in a row, so files don't get skipped, and so the player doesn't get overburdened starting new files 2021-12-27 23:21:48 -08:00
Christopher Snowhill
e2bca8f93b OpenMPT: Correctly OS version gate the OpenMPT plugins, and add an interface for any other plugin to use, should it ever become necessary 2021-12-27 17:46:09 -08:00
Christopher Snowhill
25a43a9083 Audio Output: Fix converter to always emit trailing samples on end of track 2021-12-27 17:04:16 -08:00
Christopher Snowhill
8e895c88c0 Core Audio output: Properly apply or remove default device change listener when switching preferences between the 'System Default Device' setting and manually setting the device to the current default 2021-12-26 21:33:28 -08:00
Christopher Snowhill
8435416cd7 Core Audio output: Default device setting now tracks system device changes, and output assigns a speaker mapping depending on the channel count 2021-12-26 21:27:26 -08:00
Christopher Snowhill
378aaf23ae Clean up several CFStringRef leaks 2021-12-26 18:08:53 -08:00
Christopher Snowhill
d2e480ace5 Core Audio output: Properly support switching output devices 2021-12-26 17:16:16 -08:00
Christopher Snowhill
917b7457b6 Made resume playback on startup so that seeking operation is entirely atomic with starting playback, so the new seeking behavior doesn't have the potential to crash the player 2021-12-26 04:35:54 -08:00
Christopher Snowhill
1cc34ea7d4 Audio Output: Made converter cleanup atomic, to wait on any threads that are still running 2021-12-26 04:34:33 -08:00
Christopher Snowhill
8d7cd6cc93 Multi Input plugin: Correctly forward register and remove observer callbacks to the actual decoder in use 2021-12-26 02:01:53 -08:00
Christopher Snowhill
dfeca7aa97 Seeking now takes the true nuclear approach to output, and should no longer have glitches 2021-12-26 02:01:02 -08:00
Christopher Snowhill
d22ee14a36 Audio Output: Take a more nuclear approach to output resetting when seeking 2021-12-25 23:41:45 -08:00
Christopher Snowhill
1278b64afd Audio Output: Fixed converter so it won't loop endlessly when it either reaches the end of a stream or is otherwise supposed to terminate 2021-12-25 22:47:17 -08:00
Christopher Snowhill
5246731189 Core Audio: Overhauled audio output to use AudioQueue instead of AudioUnit, fixed downmixing to mono, and implemented upmixing mono or other formats to more channels if the device requests them 2021-12-25 22:32:43 -08:00