oldcastle Posted June 23, 2021 Share Posted June 23, 2021 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. I want to use some 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 b) write the tempo and key in the filename. I need help on the second part. Any idea how I can extract that info and convert the file with a new filename containing the key and tempo? I'm looking for a way to automate the process. Thank you. Quote Link to comment Share on other sites More sharing options...
des99 Posted June 23, 2021 Share Posted June 23, 2021 So you're asking for programming help to read an Apple loop file? There are docs on the format, pick your programming language of choice, and make a tool to extract the data you want. (Although this is out of the scope of the Logic forum, really.) If you want to do it manually, then you can use Logic or another tool to inspect the Apple loop file, and manually rename the file with the data you need - if you only need to do a few, this will be good enough. Otherwise, you'll want to make a tool to do what you want. I don't know of any batch renaming tools offhand that can read metadata out of audio files, but you might get lucky perhaps if you look around for audio related batch processing tools... Quote Link to comment Share on other sites More sharing options...
David Nahmani Posted June 24, 2021 Share Posted June 24, 2021 If you're a programmer, you may be interested in this script: https://github.com/jhorology/apple-loops-meta-reader You can also type mdls in the Terminal then drag the loop (to paste its path), then press Enter, to lists its metadata (although I don't see any tempo information listed there): Davids-MacBook-Air:~ david$ mdls /Library/Audio/Apple\ Loops/Apple/Jam\ Pack\ Rhythm\ Section/Thrash\ Drumset\ 05.caf _kMDItemOwnerUserID = 0 kMDItemAppleLoopDescriptors = ( Single, Part, Acoustic, Dry, Clean, Grooving ) kMDItemAppleLoopsLoopMode = "Non-Looping" kMDItemAudioBitRate = 287455 kMDItemAudioChannelCount = 2 kMDItemAudioSampleRate = 44100 kMDItemAuthors = ( Apple ) kMDItemContentCreationDate = 2011-07-22 00:27:51 +0000 kMDItemContentCreationDate_Ranking = 2011-07-22 00:00:00 +0000 kMDItemContentModificationDate = 2011-07-22 00:27:51 +0000 kMDItemContentType = "com.apple.coreaudio-format" kMDItemContentTypeTree = ( "com.apple.coreaudio-format", "public.item", "com.apple.coreaudio-format", "public.data", "public.audiovisual-content", "public.audio", "public.content" ) kMDItemDateAdded = 2018-10-27 22:44:23 +0000 kMDItemDateAdded_Ranking = 2018-10-27 00:00:00 +0000 kMDItemDisplayName = "Thrash Drumset 05.caf" kMDItemDurationSeconds = 2 kMDItemFSContentChangeDate = 2011-07-22 00:27:51 +0000 kMDItemFSCreationDate = 2011-07-22 00:27:51 +0000 kMDItemFSCreatorCode = "" kMDItemFSFinderFlags = 0 kMDItemFSHasCustomIcon = (null) kMDItemFSInvisible = 0 kMDItemFSIsExtensionHidden = 0 kMDItemFSIsStationery = (null) kMDItemFSLabel = 0 kMDItemFSName = "Thrash Drumset 05.caf" kMDItemFSNodeCount = (null) kMDItemFSOwnerGroupID = 80 kMDItemFSOwnerUserID = 0 kMDItemFSSize = 78352 kMDItemFSTypeCode = "" kMDItemInterestingDate_Ranking = 2011-07-22 00:00:00 +0000 kMDItemInterestingDate_RankingRepaired = 1 kMDItemKind = "Apple Loop" kMDItemLogicalSize = 78352 kMDItemMediaTypes = ( Sound ) kMDItemMusicalGenre = "Rock/Blues" kMDItemMusicalInstrumentCategory = "Drums" kMDItemMusicalInstrumentName = "Drum Kit" kMDItemPhysicalSize = 81920 kMDItemTimeSignature = "4/4" kMDItemTotalBitRate = 287455 Quote Link to comment Share on other sites More sharing options...
oldcastle Posted June 24, 2021 Author Share Posted June 24, 2021 I found that script, but I'm not a programmer. I was thinking if I can find a utility or something that could print out the header chunk, so I could use regex or any kind of filter to get the tempo and key info and put in the file name. BTW...what is mdls? Quote Link to comment Share on other sites More sharing options...
David Nahmani Posted June 24, 2021 Share Posted June 24, 2021 BTW...what is mdls? A command to list the metadata of a file: https://ss64.com/osx/mdls.html Quote Link to comment Share on other sites More sharing options...
Eon Posted January 10, 2022 Share Posted January 10, 2022 I found that script, but I'm not a programmer. I was thinking if I can find a utility or something that could print out the header chunk, so I could use regex or any kind of filter to get the tempo and key info and put in the file name. BTW...what is mdls? Im not sure if you still around but have you found a way to do this? I need to do the same since i want to use Logic's Apple Loops inside Bitwig Studio, what i want is just to convert whole Apple Loops library from CAF to WAV and add tempo and key information after the filename of each loop. Quote Link to comment Share on other sites More sharing options...
oldcastle Posted January 11, 2022 Author Share Posted January 11, 2022 Hey. No luck. I wanted to do exactly the same thing as you, but I could not find a way. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.