-
Notifications
You must be signed in to change notification settings - Fork 166
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement AUDIO header #951
Implement AUDIO header #951
Conversation
for format < 1.1.0 only MP3 is written for format in range [1.1.0, 2.0.0) AUDIO and MP3 is written for format >= 2.0.0 only AUDIO is written
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done a quick initial pass. Is this the only change in 1.1.0 or is there more? The last thing I want to do is half-support something now that people are actually putting effort into standardizing it. Because people will hack around it and/or report bugs because we're only implementing it partially (and then comes the hotfix but it misses some edge case and now we're stuck with n+1 things for the next 20 years)
Not sure if I'll get to really dig into the spec until the weekend, hence this quick review.
EDIT: personally I'm not really against partial support, especially if it's an added tag like this, but if it also for example demands that #START
and #END
use sane values, then this is not getting in in its current state. It's a bit of a chicken-egg problem, especially with bigger spec changes it'll be good to split them up across multiple PR's, but ideally it's still all in a single release. Like I said, I need to actually research the spec soon.
There are more changes for 1.1.0 (see #921): IMO support for format 1.1.0 can be classified in distinct sub-features which can be implemented independently:
|
I only checked The english and german languages. Most other languages simply use the values from the english localisation.
I just changed I also changed the English and German localization to use Audio instead of MP3. |
re: #951 (comment) Yeah independent (or at least multiple) PRs is the way to go for that. But can we release this without all the other things? Personally I'm fine with partial support as long as it doesn't really break the not-yet implemented bits, but I'm not an end user. Also generally agree with your comments on the subfeatures. |
In my opinion yes. As long as we don't say that we fully support 1.1.0 there should be no Issues. For songs with Format < 1.1.0 nothing changes. For songs with Format >= 1.1.0 the AUDIO and MP3 tag should (hopefully) both be valid audio files (usually the same file). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code looks good. Verified that existing songs still work. Did not actually test the new header, but the code looks good enough. Will merge tomorrow.
Format 1.1.0 introduced the mandatory AUDIO header as a replacement for the MP3 header.
USDX now requires songs with VERSION >= 1.1.0 to include the AUDIO header and reads the audio file from this header.
The MP3 header is ignored for songs with VERSION >= 1.1.0.
When saving songs, the AUDIO and MP3 headers are written depending on the VERSION of the song, as shown in the table below:
Footnotes
VERSION >= 2.0.0 is currently not supported by USDX. This is just future proofing ↩