Commit Graph

3085 Commits (ab8154348e958d7e5602b811383593ae7bb186f4)

Author SHA1 Message Date
Christopher Snowhill 61a30c959c Bundled resources: Use NSBundle interface
These methods should use NSBundle, rather than CF* C functions

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-02-01 14:40:02 -08:00
Christopher Snowhill f3ddd69f63 libOpenMPT: Updated to version 0.6.1
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-30 15:19:56 -08:00
Christopher Snowhill ebb9c5b4f1 libOpenMPT Legacy: Updated to version 0.5.16
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-30 15:19:36 -08:00
Christopher Snowhill 9e42182928 Update Code of Conduct, remove placeholder
Oops, I should have scanned it for placeholders before uploading.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-30 14:38:49 -08:00
Christopher Snowhill 54ccad7c5d Volume Slider: Fix appearance of tooltip
Tooltip should appear on the left side when the volume bar is close to
the right side of the screen.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-30 14:05:12 -08:00
Christopher Snowhill fe67d1a6ea Adopt Contributor Covenant as code of conduct
From now on, all contributions, and all issues and pull requests posted,
must adhere to this document. I would like people to remain civil on my
project, if they possibly can. If they cannot, they will be ejected.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-30 13:47:30 -08:00
Christopher Snowhill 808710b881 Volume Control: Fix linear 100% range control
Range is now linear on 100%, like it should be.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-30 00:18:07 -08:00
Christopher Snowhill 476c88973b Ring Buffer: Replace virtual buffers
Replace individual virtual buffers with large _mm_malloc blocks at a
time, then dole out chunks of those buffers as the nodes need them.
Should reduce memory contention a little bit.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-29 21:32:59 -08:00
Christopher Snowhill 9e5a70c9ae Cog Audio: Dealt with a major retain cycle leak
This seals up a major memory leak of the playback state whenever a chain
is released on stop or on manual track change. CogAudioMulti was
retaining the input node due to its listeners, and InputNode was not
releasing the listeners when asked to stop running. This is fixed now.

Fixes #221

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-29 21:31:19 -08:00
Christopher Snowhill 77a079bd53 Mini Window: Fix saving and restoring position
Fixes #212

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-29 18:00:34 -08:00
Christopher Snowhill 1c3419580f Templates: Touched by Xcode
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-29 17:59:59 -08:00
Christopher Snowhill d2a8ccb098 Toolbar: Replace Randomize Playlist button again
Now with a slightly more appropriate icon for non-retina displays. I
still want to consider what to do with this, since it still looks a bit
blurry on 1x displays.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-29 17:45:41 -08:00
Christopher Snowhill 66f27b4e12 Spotlight Panel: Align all controls properly
Fixes #224

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-29 17:28:53 -08:00
Christopher Snowhill abffadef4e Equalizer: Prevent circular application of presets
This prevents the apply presets function from resaving the preset number
and retriggering itself repeatedly, which would cause a crash.

Fixes #223

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-29 17:27:10 -08:00
Christopher Snowhill e695e36599 Equalizer: Store custom presets on change
Store custom presets on value changes, on half second intervals, as the
listener observes the user changing the settings.

Fixes #222

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-29 17:21:43 -08:00
Christopher Snowhill 5184c8e48b Sparkle: Disable automatic updates when debugging
Disable automatic update checking on startup for debug builds. Prevents
a crash from occurring when it attempts to retrieve the version number.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-29 17:01:51 -08:00
Christopher Snowhill 7e5107d431 User Settings: Obey standards
Replace "midi.plugin" with "midiPlugin", as per the value naming
conventions that Apple set out. Migrate the old value if found.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-29 16:38:53 -08:00
Christopher Snowhill 85fd3836c0 Debug logging: Added logging of playback and tags
Added a logging method that indicates starting playback of a given URL,
and added a debug build only logging of every metadata load event.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-29 16:34:43 -08:00
Christopher Snowhill 326e9d5970 GME: Fix music playback with no fade from crashing
Only crashed with division by zero error on Intel, not on Apple Silicon.
Funny that. Sending the fix upstream, too.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-29 16:26:28 -08:00
Christopher Snowhill c5f9ffe87c
Merge pull request #220 from losnoco/nevack/linear-scale-for-volume-slider
Scale VolumeSlider linearly if volume is limited.
2022-01-29 15:40:34 -08:00
Dzmitry Neviadomski 050a3d3112 Scale VolumeSlider linearly if volume is limited.
Fixes #198
2022-01-29 05:57:19 +03:00
Christopher Snowhill 7be0ade7ce Ogg Vorbis and Opus: Fix 7.1ch file remapping
File channel remapping was incorrectly only working for 1-7 channel
files, not 8 channel files. Fixed that.

PLEASE NOTE: This will be my last commit and build for over a week, I
promised myself I would stop, and this is the last straw. These are the
last two, I promise. No more bug fixes this week, until at least the 7th
of February. Please, I'm begging you.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-27 23:04:19 -08:00
Christopher Snowhill d239b58ab1 HRIR Filter: Fix 7.0 downmix and WAV files
7.0 downmix was passing parameters to cblas_scopy backwards, and WAV
files report "host" endian, not "native".

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-27 23:02:04 -08:00
Christopher Snowhill 38c7fdafd0 Delete Gitlab CI config
We're not using Gitlab's CI anyway, and they don't offer free Mac
build bots at this time, either. It just keeps spamming me with build
failure notices every time I push commits to that mirror.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-27 22:23:19 -08:00
Christopher Snowhill 241b7b4b34 FFmpeg patches: Updated iTunes gapless patch
The patch is now updated to exactly what I sent to the ffmpeg-devel
mailing list for hopeful inclusion in the latest release of FFmpeg.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-27 19:31:15 -08:00
Christopher Snowhill f807cd8169 FFmpeg Input: Just-in-case change to file reader
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-27 14:49:33 -08:00
Christopher Snowhill 9caf704630 Equalizer: Better handle interpolating presets
The old quadra method was broken, too. Now it uses a simple linear
difference sliding scale for the extra points, which seems to work much
better for the 20 kHz band. And the 16 kHz band doesn't get predicted to
heck any more, either.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-27 14:30:14 -08:00
Christopher Snowhill 7c012b2714 MainMenu template: Touched by Xcode
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-27 14:29:08 -08:00
Christopher Snowhill 72c18ca960 Toolbar: Try second edition Randomize button
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-27 14:19:58 -08:00
Christopher Snowhill efc044ae33 Toolbar / Menu adjustments for equalizer, etc.
Added a keyboard shortcut for the equalizer menu item, added a user
contributed button for an equalizer toolbar button, and replaced the
randomize playlist button with something different from the same user.

I had to redo the randomize button, because template PDFs don't support
white cutout shapes, but instead need to be formatted as hollow spaces
in the paths. Naturally, I couldn't figure out how to do this with
Inkscape the right way, so I rendered the original to a 1024x1024
bitmap, then imported that into a new document and traced it. Meh. I
need a better icon anyway, but this looks okay on the toolbar for now.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-27 01:31:50 -08:00
Christopher Snowhill b0fca5127f SQLite Store: Fix updating track entries
Track entries are updated when files are added and their metadata is
later loaded. The refresh cycle was failing, because dbIndex was unset
in the new tracks, for some reason. Now it will set this when updating
the track item, assuming it read from the database in the first place.

This fixes metadata being loaded properly on adding tracks to the
playlist, as well as reloading track data manually.

Fixes #218, hopefully.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-27 00:11:14 -08:00
Christopher Snowhill 2e41e7c525 FFmpeg Input: Enable networking and HLS support...
... also disable use of AudioToolbox codecs, and use only bundled codecs
and libfdk-aac for AAC input. This is required for HLS at least, as
Apple's system codecs didn't really like the network streams that were
provided by HLS streaming stations.

Also reshuffle the input priorities between Core Audio input and FFmpeg
input, so that they were the way they were before I messed with things a
while back. This puts FFmpeg back at the top, using bundled codecs where
supported.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-27 00:11:14 -08:00
Christopher Snowhill 7f114bce0e FFmpeg libraries: Enable networking and HLS
Also disable AudioToolbox codecs, as they don't really like network
streaming so much. Use bundled codecs instead.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-27 00:11:14 -08:00
Christopher Snowhill 547de6cf08 M3U Playlist container input: Disable for HLS
The built-in M3U container parser should not be used for HLS playlists,
so they should end up in the playlist as-is, so that inputs can parse
them in real time.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-27 00:11:14 -08:00
Christopher Snowhill 2541633c17 Playlist Entry: Display full URL for remotes
For Playlist Entries that are not File URLs, return the full absolute
URL for path queries, so the playlist path column will show the full
URL instead of a useless reduced path string.

Fixes #214.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-27 00:11:14 -08:00
Christopher Snowhill cc2b27d43f Core Audio output: Potential shutdown fix
The thread wait on shutdown had the potential to lock up waiting for the
thread to shut down. Now it should at least spam the semaphores, so that
the thread should progress to shutdown a lot quicker.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-27 00:09:40 -08:00
Christopher Snowhill 3c35cf1037 MIDI Input: Fall back to system DLS Synth
If there's no configured SoundFont bank, or if the selected bank has
gone missing, and the user has configured the player to use the
FluidSynth driver, fall back to the system DLS Synthesizer, which has
its own Roland bank to fall back on if unconfigured.

Also, whether falling back, or already on an AU synthesizer, don't fail
if there's no bank configured or found. DLS doesn't explicitly require a
bank, and most other synthesizers of interest would not require a bank
either.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-27 00:09:40 -08:00
Christopher Snowhill fce851bfff Updated VGMStream to r1702-16-g2db8e56e
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-27 00:09:40 -08:00
Christopher Snowhill b53567edc5 Fix VGMStream so it handles EOF properly
The file prober in FFmpeg expects that when the read function reaches
end of file, it returns AVERROR_EOF, not zero. Otherwise, it will loop
endlessly until the process is terminated.

Fixes #217.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-27 00:09:40 -08:00
Christopher Snowhill 9edf4ddc49 Update credits: New patron
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-26 17:19:50 -08:00
Christopher Snowhill bbce6880d7 Core Audio output: Add a quick safety fix
Add a safety fix for pausing and shutting down, so that we don't call
into AUAudioUnit's stopHardware function unless the stream has already
been started by the output.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-26 15:42:28 -08:00
Christopher Snowhill ee7b7dad5f VGMStream: Add a bodge for PSF files
For some incredibly dumb reason, PSF files get into FFmpeg 5.0, then
just sit there and lock up, reading them forever and ever, doing nothing
useful. Add a bodge to detect PSF files by signature and ignore them in
the VGMStream container parser, and all other parts of VGMStream in Cog.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-26 15:40:44 -08:00
Christopher Snowhill 600c447531 Virtual Surround: Further cleanup
Quick changes I missed. Oops.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-26 01:03:12 -08:00
Christopher Snowhill 7b5925d7d2 Virtual Surround: General cleanup
This should fix some coding issues, and also fix some potential memory
leaks in the file verifier, assuming it didn't already release the
files it was pulling the stats from.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-26 01:00:28 -08:00
Christopher Snowhill e6b056d7ae Updated README.md
Added a link to a downloadable set of HRIR presets, borrowed from the
HeSuVi project, which is on SourceForge, but inside of an executable,
therefore possibly a pain to extract.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-26 00:33:03 -08:00
Christopher Snowhill 97b8ad0949 Update README regarding HRIR convolver
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-25 23:27:10 -08:00
Christopher Snowhill 778ac0699e Virtual Surround: Cleanup properly
The filter wasn't properly freeing its FFT setup state, and also was
unnecessarily null checking the pointers before passing them to the
aligned free function, which already does null checking.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-25 22:06:53 -08:00
Christopher Snowhill c7c3c82c18 Core Audio output: Change end of file timing
Reduce the timing at which an end of file notification is sent to the
main thread from 16384 bytes to 8192 bytes. This may help with playback
of a lot of really small files, and skipping tracks.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-25 21:55:08 -08:00
Christopher Snowhill 708c7dc721 Headphone Virtualization: Implement customization
Implement the ability to configure and select an HRIR preset to use with
the HRIR filter, or remove the preset. It will validate the file's
usefulness before setting it for the player to use.

Also, fixed back center channel filtering for 7.0 format audio.

Signed-off-by: Christopher Snowhill <kode54@gmail.com>
2022-01-25 21:30:33 -08:00
Christopher Snowhill bb029757fd
Headphone Virtualization: Fix an oops
The previous commit was not sound. Now it is.
2022-01-25 17:45:32 -08:00