How to get the apple loops metadata?

Programming applications for making music on Linux.

Moderators: MattKingUSA, khz

Post Reply
oldcastle
Established Member
Posts: 57
Joined: Tue May 04, 2021 11:28 am
Has thanked: 4 times
Been thanked: 31 times

How to get the apple loops metadata?

Post by oldcastle »

Hi guys,

I hope this is the right place to ask this question. I need some help in figuring out a way to put the apple loops metadata (tempo and key) in the filename. Here's the thing.
Screenshot 2021-06-23 at 16.17.16.png
Screenshot 2021-06-23 at 16.17.16.png (19.66 KiB) Viewed 9620 times
I want to use apple loops in another DAW, but I want also to know their tempo and key. So, what I'm planning to do is a) convert the .caf to .wav and b) write the tempo and key in the filename. I need help on the second part. Anyway, idea how I can have access to that info? Or any workaround?

Thank you.
User avatar
marbangens
Established Member
Posts: 56
Joined: Fri Nov 16, 2018 8:39 pm
Been thanked: 6 times

Re: How to get the apple loops metadata?

Post by marbangens »

If I understand you correctly you want help how to extract "Information Entry Keys" from caf and put in the filename of a wav file?
I have never used appleloops at all..
The information is in the caf file almost at the end of this doc
Information Entry Keys

Apple reserves keys that are all lowercase. Application-defined keys should contain at least one uppercase character. Each key can be used only once. You can specify multiple values for a single key by separating the values with commas. The following are the standard keys for the Information chunk:

tempo

The base tempo of the audio data in beats per minute.
key signature

The key signature for the audio in the file. In the mValue field, the note is capitalized with values from A to G. Lowercase m indicates a minor key. Lowercase b indicates a flat key. The # symbol indicates a sharp key.

Examples: ‘C’, ‘Cm’, ‘C#’, ‘Cb’.
time signature

The time signature for the audio in the file.

Examples: ‘4/4’, ‘6/8’.
artist

The name of the performance artist for the audio in the file.

Example: ‘Able Baker,Charlie Delta’
album
AudioToolbox/CAFFile.h is an apple header
https://github.com/SpheroShakeAway/Sphe ... /CAFFile.h

Hopes it helps a little at least and good luck!

ps: You may have to calculate "beats" I didn't see it in the documentation but I didn't look closely
oldcastle
Established Member
Posts: 57
Joined: Tue May 04, 2021 11:28 am
Has thanked: 4 times
Been thanked: 31 times

Re: How to get the apple loops metadata?

Post by oldcastle »

You got right.

Thanks!
Post Reply