The member that I set myself to indicate deletion has one capital letter
to differentiate it from the built-in "delete" property of managed
objects, which doesn't do what I want, so I had to dodge it with that
capitalization thing.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Use a custom script found on Stack Overflow, with some minor changes for
a little more sanity, such as using find -print0 / xargs -0 to support
paths with spaces in them.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Header include paths are named after the framework, which is all lower-
case, not uppercase like the source folder is named. The header include
paths inside the project are lowercase as well, so this fits.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Change most, if not all, possible import paths to use the full header
directory paths instead of relative or "assume include paths" settings.
This should fix building with the CI.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
These header files were imported from the wrong path. I really have no
idea why Xcode didn't catch these already with my build tree.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
It was a fun ride, but I think I want to try something different. Users,
please be sure not to have DNS blocking for Crashlytics if you want me
to have any useful bug reporting info if it crashes on you, or otherwise
blows up. Otherwise, I don't get any useful data to help me fix crashes.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Fix the default volume scale reading for newly added tracks, as this
value should be 1 for any files which do not have tags. Also add an
override to the tag applying function, to reset the default on tag
re-read operations.
Please reload the tags or re-add your files to fix them playing
silently.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Add a compatibility getter/setter for URL, which was renamed to url, due
to Core Storage having a requirement of all attributes starting with a
lower case letter.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Fixed the implementation to work correctly with the new Core Data
storage system. Tracks will be garbage collected later.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
The PlaylistEntry class needs a compatibility wrapper for the Unsigned
member, as it is assigned by all of the inputs. Case sensitivity and all
that is. And unfortunately, Core Data requires all model members to
start with a lower case letter.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
The copy action now includes formatted text of the selected entries when
copying, in addition to the supported file and URL types.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Completely rewrite the playlist storage once again, this time with a
much faster Core Data implementation. It still uses a little magic for
Album Artwork consolidation, but string consolidation doesn't seem to be
needed to reduce the disk storage size. Works much faster than my silly
implementation, too.
Old implementations are still kept for backwards compatibility with
existing playlists.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Synchronize audio setup and audio stopping on the object's own pointer,
to hopefully prevent race conditions with out of sync calls to the stop
function from both the main and the audio thread.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
The changes include no longer leaving the workgroup for seeking or for
converter format changes, and also still leaving the workgroup on thread
termination if there was an error with intervals starting or finishing.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Prevent an unhandled exception when a notification is sent on a track
which has been deleted from the playlist.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Jobs are meant to be serialized, so prevent multiple jobs from queueing
simultaneously, as they are not designed to interact with each other.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Long actions, such as file opening, playlist loading, metadata loading
and refreshing, etc, are now handled through NSProgress. Additionally,
a new status bar change displays the progress of the task instead of
the total duration of the playlist. Finally, app quit is blocked by a
running task, and if the app is quit while a task is running, it will
be delayed until the task completes, at which time the app will
terminate cleanly.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Prevent a race condition with deleting playlist entries while their
metadata is still being loaded by the player.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Guard Open in Finder against being called on a playlist with no
selection, which may happen if the action is triggered on an empty
playlist, which would cause an array out of bounds access error.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Guard the playlist entry retrieval function against being called on an
empty playlist, because an empty playlist would result in a division by
zero error to occur here.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
If there is somehow a legacy XML playlist, and there is no queue entry
in the plist, then it should not throw an exception from trying to add
a nil object to the return dictionary.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
An impulse cache reduces any glitching from format channel count changes
to near insignificant levels, resulting in a more pleasant experience
when there are different mixed formats playing, or even a file which
changes format mid-playback.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Ensure that dynamic info updates, even on static files, only update the
exact track they apply to, by atomically assigning the userInfo property
before opening the decoder, so that callbacks to the player indicate the
correct track and don't assume it's the one that's currently visibly
playing. Fixes start of track metadata notifications from overwriting
the previously playing track.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Only do a rough estimation on files without Xing or LAME or iTunes
headers. This is much faster, even if less accurate, and may include
the footer tag if present.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Every schema upgrade process should fall through to the next highest
version number, so they should all run, if the user has somehow upgraded
their database from such an old version.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
The inputs now have their own metadata function, so it should merge in
the track tags from the Cuesheet, and not just forward it to the
decoder.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Bugsnag framework was possibly missing from the config files, so
it's been added properly on older Xcode.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
This should prevent a crash if the input is recycled for another file,
which would cause the output buffer to be freed, but the output size to
contain a count on first call to readAudio, which would cause a memory
access crash.
Possibly fixes#269
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Various warnings related to uninitialized variables, or setting values
to variables that would not be used later or would be overwritten by per
loop initializers.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
If one condition returned memory successfully, but the other did not, it
would result in the cleanup code accessing an uninitialized pointer and
iterating over it, crashing.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Surprised I didn't catch this sooner. This could have resulted in a
division by zero error if either sample rate somehow was zero.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
The two toolbars seem to require unique identifiers for each of their
items, even when they're separate toolbars in separate windows.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Now read all metadata and signal it, and also support pre-buffering
a small block of sample frames if there is embedded artwork, since the
embedded artwork must be handled by the sample decode function.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
Add support for plain "genre" tag, in addition to the previously
supported "icy-genre" field for streams, this one is for static files.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>
DFT should use aligned memory blocks for best results. Also allocate one
extra sample for DFT output, just in case DFT zop is as bad as zrop.
Signed-off-by: Christopher Snowhill <kode54@gmail.com>