Releasing sandbox access was incorrectly synchronizing on the object,
but still running code in the calling thread. It has been updated to
match the rest of the interface, which serializes all access through the
main thread only. This should prevent the sandbox from carrying stale
handles to already-released objects.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Must always remember to have xcode-select set to Xcode.app and not
the Command Line Tools when archiving the app myself, as otherwise
Xcode will fail to package the SceneKit objects into the resulting
bundle.
The code which looked up Sandbox handles for a given path had a bug
where it would re-add the handle to the in-memory cache storage even if
it already had just retrieved the current handle from the cache. I hope
this will fix the crashes which have been plaguing people adding a lot
of files to the playlist all at once from a single folder.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Update from 0e34925..fd7da37, with the following changes:
- C140: simplify update loop, add unbanked mode
- It resembles MAME's code more closely now.
- OKIM6258: make more tolerant against late writes
- enforce "discrete YM3438" mode for YM3438 VGMs
- Update emu2413 to v1.5.9
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Change upload script to use curl to upload to Bunny. The access
key is stored in the system keychain, with confirmation on access.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Remove shell script that was modifying the import path of a framework,
as we are no longer using libvorbis like that.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Add display name and category fields to project. Thanks, Apple, for
adding those to Xcode all of a sudden.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Synchronize with dispatches to the main thread instead of using
synchronization primitives. This prevents the main thread from
hanging another thread as a result of other threads entering the
sync block, then dispatching a callback to the main thread, which
also tries to lock on the sync block.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
All concurrency from other threads should pass through the viewContext's
performBlock or performBlockAndWait functions, and no other way. So now,
all access to Core Data is either happening on the main thread, or by
using these code blocks, all of which will wait for their access to
proceed.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
This should fix some potential initialization errors it may have had
before, but this doesn't fix the broken Sound Canvas VA plugin. Roland
says it's supposed to be broken on macOS 12+ and/or Apple silicon
anyway, so I guess there's no dodging that.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
This is needed to re-parent the VolumeSlider window, as there is only a
single VolumeSlider, but two different VolumeButtons and their
respective NSPopover windows. So, always recreate the view on open,
which doesn't appear to have a noticeable impact on performance.
Fixes#331
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
It was referencing the old SpectrumView class, when it should have been
referencing the safe SpectrumViewCG class, which will software render a
single frame of spectrum data when the customizing dialog is opened.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
This was crashing trying to assign a nil CFStringRef from mystery audio
devices to the NSString passed to the enumerate block function, which
was predictably crashing. Ignore such devices instead.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
External artwork already supported the HEIC format, just not the correct
filename extension for the format.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Tag reading can read cue sheets as either a single NSString, or an
NSArray of NSStrings, so handle either case.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Stop visualization processing when the host window is completely
occluded, thus reducing background CPU usage levels significantly
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
This should fix up potential locking issues with maintaining a copy of
the results set while certain other background actions may happen, such
as the player updating play counts while playing.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Updated:
- libFLAC from 1.3.3-235-g772efde6 to 1.4.1
- libvgm from 001ca75 to 0e34925
- libid3tag from 0.16.1 with patch to 0.16.2
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
This magically fixes the stupid header maps that were pulling the system
semaphore.h into Swift projects, when they shouldn't have been doing
that in the first place. This is the same reason that the FLAC library
has its assert.h renamed to FLAC_assert.h.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
And this is the actual meat of getting it to work properly, the changes
the Swift code needed to actually be fully functional.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
These imports needed to be changed so that Swift bridging didn't import
the system's semaphore.h instead of CogAudio's Semaphore.h, which is a
completely different thing.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
There has been an API in GME to detect tracks ending for quite some time
now, and this just adds a little bit to the existing comment, which
previously noted that there was no way to detect if a track had ended,
which may have been true several major versions of GME long past.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
The output has been assigning twice as many samples as it was supposed
to ever since commit 8d851e5bda, which
ended up generating the correct 1024 samples (2048 per GME parameter),
but assigned 2048 to the AudioChunk, which resulted in over-reading the
audio buffer, and thankfully not crashing, but instead causing an awful
sound distortion effect as random memory contents were played as PCM
audio.
Fixes#320
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Allow .mp3 and such to fall back to the FFmpeg container handler, in
case there are chapters in a renamed file.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
The input isn't supposed to close its own sources, as it did not open
them itself, and they should be cleaned up automatically when they are
released to zero reference count.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Let the FFmpeg decoder handle RIFF files, if they happen to be named
.mp3 and not something like .wav.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
This fixes the update URL and parameter handling. Seems there
was an extraneous newline returned by the security command.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>