INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: INITIALKEY tag in FLAC, MP3 and m4a  (Read 6013 times)

DrKNo

  • World Citizen
  • ***
  • Posts: 201
INITIALKEY tag in FLAC, MP3 and m4a
« on: October 05, 2015, 07:48:19 am »

I recently started using FLAC for DJ purposes, since lossless formats actually start to become supported by the big DJ Software firms like serato now. I use JRiver for all my library managing, especially for the DJ stuff. And I noticed one thing: There does not seem to be a native support for the INITIALKEY tag, and it's causing problems for me. Initialkey is widely used in the DJ world, and more or less standardized at this point.

- in MP3 ID3, it's TKEY ("Initial Key") and I can access it with a user defined field set to that field
- in FLAC, it's INITIALKEY, again I can access that using a separate custom field
- in m4a, it's initialkey, again, a separate custom field is necessary (apparently, in m4a the field is not standardized, but used as a standard by all the DJ Software I know of)

This is problematic for me: I'd rather like a single field for the initialkey instead of three separate ones that I need to manage independently. How is that managed with the standard fields? Also, seeing that in FLAC and m4a the difference is only in upper- vs lowercase, I cannot seem to define both fields at once, because the new field defaults to "initialkey (1)"

Is there any way to solve this manually, or maybe a chance to support it natively in jriver?

By the way: At this point, you might as well market MC as "the" library management product for a DJ. By using custom fields, views, and file name management MC saves me at least a full day of work every month, paying 30 or so dollars a year for a master license is easily worth that. Keep on building a great product.
Logged

ferday

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 1732
Re: INITIALKEY tag in FLAC, MP3 and m4a
« Reply #1 on: October 05, 2015, 09:11:07 am »

What kind of value do you need in there? Where do the values come from, are they already filled out when you get the tracks?

What do you mean when you have to manage them?  Like how do you use them in your work?

Sorry not a DJ but there may be ways
 Edit: I read about the tag a bit and I see why you use it, not sure how you get it though (does it come that way)

When doing playback do you only need the value, and the name of the tag doesn't matter?
Logged

DrKNo

  • World Citizen
  • ***
  • Posts: 201
Re: INITIALKEY tag in FLAC, MP3 and m4a
« Reply #2 on: October 05, 2015, 10:43:55 am »

Quote
What kind of value do you need in there? Where do the values come from, are they already filled out when you get the tracks?

Strings, generally speaking. Depending on your notation it could be Camelot (e.g. A1, B5, A12 or mixtures like A5/A7) or a traditional Notation (Dm, F# etc.). The values sometimes come with the file (Beatport does that for example), are analyzed with special software (e.g. MixedInKey) or worked out manually with a Keyboard/Piano/whatever. All services I know of use the tags as I specified above (not too sure about mp4, but have not yet seen the contrary).

Quote
What do you mean when you have to manage them?  Like how do you use them in your work?

During sets, I look at the keys to see if two tracks will match tonally - that's just plain musical theory.  Before the sets I sometimes group tracks with similar keys when trying to build a mixtape, or  I use a keyboard to find the right key and correct it if I think I know better than MixedInKey =)

Quote
When doing playback do you only need the value, and the name of the tag doesn't matter?
Well, no, the name (I assume the field that is written to in the tag) matters: DJ software is not flexible and that regard - Serato and Traktor will only read the fields I specified above. If another field is used, the tracks will not be available in the DJ software, which would largely defeat the cause.

What I'm getting at: Standard fields like name, Track number, Artist etc. are handled in a unified manner over all filetypes. I wonder if that would be possible for Initialkey, too?

Logged

ferday

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 1732
Re: INITIALKEY tag in FLAC, MP3 and m4a
« Reply #3 on: October 05, 2015, 10:58:33 am »

well, it maybe could

for example, if Traktor / Serato uses a field specifically called INITIALKEY, you can make that field populate from TKEY or initialkey

it depends how it's handling it now though...do these programs read ANY of the KEY files (TKEY, INITIALKEY, whatever) from MC?

in MC, did you make 3 custom fields (INITIALKEY, TKEY, initialkey?)

for example, if traktor reads INITIALKEY, but your mp3's have TKEY filled, you can put in the INITIALKEY field =TKEY and it will autopopulate, this can be automated

there are probably ways to make all of them do at least semi-automation, but i'd need to know your workflow (you get a file from beatport, fix the tagging, import into MC...which fields auto populate from beatport?  when you make your own TKEY if it's blank or wrong, where do you put that info?  which tags does tracktor actually read from MC, does it read a custom field if you name it INITIALKEY?)  when you get an mp4, you say it has initialkey (no caps) does MC read this tag at all (i.e. does it automap it to INITIALKEY?)

so either you have to give me a bunch of info, or we hope that a fellow DJ comes along to help :)

Logged

ferday

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 1732
Re: INITIALKEY tag in FLAC, MP3 and m4a
« Reply #4 on: October 05, 2015, 11:10:32 am »

maybe that was confusing

do ANY of your custom tags in MC auto-populate from the track, if the info was already there from beatport or mixedinkey etc. (initialkey, tkey)
are ANY of these tags when populated readable from Traktor/Serato (do they recognize your custom INITIALKEY field?)
Logged

DrKNo

  • World Citizen
  • ***
  • Posts: 201
Re: INITIALKEY tag in FLAC, MP3 and m4a
« Reply #5 on: October 05, 2015, 03:48:38 pm »

Thank you very much for taking the time for this, I appreciate it  :)

  • MC does not natively support any of these Fields, apparently. I need to custom-add each.
  • After creation, each field works correctly, but only for it's respective file type.
  • I cannot add all three at the same time, because of the INITIALKEY/initialkey problem (This actually prevents a scripting solution. Personally, I wouldn't mind using FLAC only, I'm thinking about the larger Userbase)
  • Key information is not shared between fields (obviously, MC cannot assume identity).
  • DJ-Software (Serato, Traktor, MixedInKey) uses the three different fields depending on filetype as outlined above, not a single field, meaning I have to write the correct field to the correct filetype. It only reads and writes to the fields that are appropriate to the file type.

You could probably build a workaround for this, but it would be complex: The correct value will stand in one of the fields depending on filetype (Mp3: TKEY, FLAC: INITIALKEY, mp4: initialkey). What would work I guess is would be to define a custom Master field: "Key Master", then fill that from any non-blank standard field, mirror the master back to all three, and write all three to file. That's why I was basically was asking the devs to include it as a mapping like it has been done for other standard fields: Track, Name, Artist etc... Or maybe give us a tool to create tag mappings on our on? Or maybe there's a way to script that more elegantly, that I am just not aware of.

my workflow, if it is helpful:

1) Get new File, have it pre-tagged or tag with external software: Tag is written to appropriate field outside MC
2) Import File to MC: Have all keys inside a single field inside MC, independent of filetype
3) If changes are made to that field,  write change to correct field into file
4) If changes are made outside MC, Update initialkey correctly like any other field

Having either one between 3/4 would be sufficient for me personally.
Logged

ferday

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 1732
Re: INITIALKEY tag in FLAC, MP3 and m4a
« Reply #6 on: October 05, 2015, 05:40:44 pm »

the real killer is the initialkey vs. INITIALKEY, it sounds like you're saying that mp4 will NOT populate INITIALKEY while flac will NOT populate initialkey (if you could even make it...)

if you made a [master key] field, you could make it something like

if(!isempty([INITIALKEY]),[INITIALKEY],[TKEY])

this should make the [master key] into either INITIALKEY or TKEY, depending on which one is populated on import.  if initialkey was simply one letter different we could handle this but i'm lost on what to do there right now...there isn't really a "tag map" that i'm aware of or if that is even possible.  i think this one will have to go to the devs now :)
Logged

Hendrik

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 10943
Re: INITIALKEY tag in FLAC, MP3 and m4a
« Reply #7 on: October 05, 2015, 05:51:33 pm »

Not sure about adding a default field. What does that field even do? On the other hand, if its deemed useful, no harm in adding it.

One thing I could do, I can probably make our tagging code unify these 3 fields all into INITIALKEY, so that if you specify a Custom field like that, it would read/write the 3 different fields for ID3, FLAC and M4A.
It's a good first step, I think. Maybe I should name it something more user friendly though, maybe "Initial Key"?

Do you maybe have a reference for the field definition in FLAC, and maybe something that mentions the tag for m4a, or a sample file with it set, just to be sure I read/write the right thing? I found it for MP3/ID3.
Really super would be a sample in each of the formats you would like it to be read out of. :)
Logged
~ nevcairiel
~ Author of LAV Filters

DrKNo

  • World Citizen
  • ***
  • Posts: 201
Re: INITIALKEY tag in FLAC, MP3 and m4a
« Reply #8 on: October 06, 2015, 01:10:13 am »

That's swell, Hendrick, thank you!

Quote
What does that field even do?

Initial keys stores the musical key the song is in (e.g. F minor, D major) in String form. You will come across the Camelot notation (http://www.mixedinkey.com/HowTo) or standard keys in sharp- or flat notation. Sometimes users store combinations of keys (A7/A9), if the song changes key in the middle, although that might be considered non-standard. Initialkey is expected to hold the first key, hence the name. The field is used mainly in the DJ- and to a lesser extend the production scene to see what songs will match tonally during transition/mashups.

Quote
Do you maybe have a reference for the field definition in FLAC, and maybe something that mentions the tag for m4a, or a sample file with it set, just to be sure I read/write the right thing? I found it for MP3/ID3.

MP3-Tag Mapping Vorbis to mp3 and wma: http://help.mp3tag.de/main_tags.html
Post from HydrogenAudio: http://www.hydrogenaud.io/forums/index.php?showtopic=105431

I will upload a set of files tonight when I'm back from work for you, might be 10-12 hours though. If you let me know of additional file types you will want to add while you are at it, write me. I'll tag and upload them too. wma will probably make sense, I guess? Any other requests?

Logged

Hendrik

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 10943
Re: INITIALKEY tag in FLAC, MP3 and m4a
« Reply #9 on: October 06, 2015, 06:32:19 am »

WMA should be fine, the tags are strictly specified by Microsoft and I found the constant they use for Initial Key, so don't really need that.
MP3 (or something else with ID3), FLAC and m4a would be great.
Logged
~ nevcairiel
~ Author of LAV Filters

DrKNo

  • World Citizen
  • ***
  • Posts: 201
Re: INITIALKEY tag in FLAC, MP3 and m4a
« Reply #10 on: October 06, 2015, 03:19:21 pm »

I sent you the test files via PM =)
Logged

Hendrik

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 10943
Re: INITIALKEY tag in FLAC, MP3 and m4a
« Reply #11 on: October 06, 2015, 03:30:43 pm »

I got them. And in the next build:
NEW: Added 'Initial Key' field and support for the appropriate tags in MP3/ID3, FLAC, M4A and WMA.
Logged
~ nevcairiel
~ Author of LAV Filters

DrKNo

  • World Citizen
  • ***
  • Posts: 201
Re: INITIALKEY tag in FLAC, MP3 and m4a
« Reply #12 on: October 07, 2015, 01:53:29 am »

Brilliant! Thank you both very much for your help!
Logged
Pages: [1]   Go Up