IPB

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
Euphonos Metadata Importer Test..., OS X Spotlight importer for audio codecs
Dibrom
post Jun 10 2005, 08:39
Post #1


Founder


Group: Admin
Posts: 2958
Joined: 26-August 02
From: Nottingham, UK
Member No.: 1



I've made an initial version of the spotlight importer for my upcoming audio player for OS X, which I mentioned earlier this week here.

Download the importer here.

So far, the importer is setup to recognize files of type:

- FLAC
- APE
- Musepack
- Ogg (as a container)
- OptimFROG
- Speex
- Wavpack

I could easily make it recognize others as well, these were just some I could think of at the moment. It will read id3v1, id3v2, apev2, and vorbis comments, as well as some internal format properties, to extract information about the files and add them to the spotlight metadata database. Note that I have only tested the importer on Ogg Vorbis and MPC files, so I'm not 100% certain the importer will grab the tags from the other file types even though it has the capability to do so.

Right now, I've only made it add metadata for the values that Apple already fills in for mp4 and mp3 files, but in later versions I will make the information set much more complete. The metadata that it currently imports is:

- bitrate
- channel count
- duration in seconds
- media type
- album
- tracknumber
- artist
- genre
- title
- codec type

It would be nice if I could get some people to help test and provide feedback. To use the importer, download the file, extract the importer, and copy it to the ~/Library/Spotlight directory. You may need to make the directory if it doesn't already exist. This will only add support for your current user so if you want it system wide, put it in /Library/Spotlight instead.

After this, to get the metadata to show up, you will need to reimport the files into the spotlight database (all files modified in the future will automatically be imported). To do this, you can either modify the file somehow (touch might do the trick), or you can use mdimport. To reimport a single file, just type "mdimport somefile" at the terminal. You can also have it check the entire file system for reimportation (best if you have tons of files you'd like to do this for) by typing "sudo mdimport /" at the terminal and typing in your password.

You can test to see if the metadata has been imported either by typing "mdls somefilename" at the terminal, or by making some sort of smart folder that filters via one of the metadata properties for audio files.

Although there should be no problems I can see with this importer, use it at your own risk smile.gif I suggest making a backup of files you are testing the import on if you are super paranoid.

Anyway, I will be releasing updates in the near future along with source code. Once this importer is more solid, it will serve as the foundation for Euphonos metadata reading.

Oh, one final thing, it would be nice if someone wanted to make OS X icons for the different file types so that the importer would actually show them up as something other than a blank document in Finder smile.gif
Go to the top of the page
+Quote Post
irchs
post Jun 11 2005, 15:44
Post #2





Group: Members
Posts: 49
Joined: 3-July 03
Member No.: 7543



Hey there, this thing is very nice smile.gif

Here is my debug data for some an Ogg file I tested it on:

CODE
/*THIS IS BEFORE I RAN THE IMPORTER*/

LITTLETOE:~/Desktop jan$ mdls Queens\ Of\ The\ Stone\ Age\ -\ Lullabies\ To\ Paralyze\ -\ 02\ -\ Medication.ogg
Queens Of The Stone Age - Lullabies To Paralyze - 02 - Medication.ogg -------------
kMDItemAttributeChangeDate = 333003-05-12 23:41:03 +0000
kMDItemFSContentChangeDate = 2005-04-02 19:54:52 +0100
kMDItemFSCreationDate      = 2005-04-02 19:54:52 +0100
kMDItemFSCreatorCode       = 0
kMDItemFSFinderFlags       = 0
kMDItemFSInvisible         = 0
kMDItemFSLabel             = 0
kMDItemFSName              = "Queens Of The Stone Age - Lullabies To Paralyze - 02 - Medication.ogg"
kMDItemFSNodeCount         = 0
kMDItemFSOwnerGroupID      = 501
kMDItemFSOwnerUserID       = 501
kMDItemFSSize              = 6887073
kMDItemFSTypeCode          = 0
kMDItemID                  = 1058512
kMDItemLastUsedDate        = 2005-04-02 18:54:52 +0100
kMDItemUsedDates           = (2005-04-02 18:54:52 +0100)

/*RUNNING THE IMPORTER*/

LITTLETOE:~/Desktop jan$ mdimport Queens\ Of\ The\ Stone\ Age\ -\ Lullabies\ To\ Paralyze\ -\ 02\ -\ Medication.ogg

/*CHECKING IT IMPORTED FINE*/

LITTLETOE:~/Desktop jan$ mdls Queens\ Of\ The\ Stone\ Age\ -\ Lullabies\ To\ Paralyze\ -\ 02\ -\ Medication.ogg
Queens Of The Stone Age - Lullabies To Paralyze - 02 - Medication.ogg -------------
kMDItemAlbum                   = "Lullabies To Paralyze"
kMDItemAttributeChangeDate     = 2005-06-11 15:38:56 +0100
kMDItemAudioBitRate            = 500
kMDItemAudioChannelCount       = 2
kMDItemAudioTrackNumber        = 2
kMDItemAuthors                 = ("Queens Of The Stone Age")
kMDItemContentCreationDate     = 1904-01-01 00:00:00 +0000
kMDItemContentModificationDate = 2005-04-02 19:54:52 +0100
kMDItemContentType             = "org.xiph.ogg"
kMDItemContentTypeTree         = (
    "org.xiph.ogg",
    "public.audiovisual-content",
    "public.data",
    "public.item",
    "public.content"
)
kMDItemDisplayName             = "Queens Of The Stone Age - Lullabies To Paralyze - 02 - Medication.ogg"
kMDItemDurationSeconds         = 114
kMDItemFSContentChangeDate     = 2005-04-02 19:54:52 +0100
kMDItemFSCreationDate          = 2005-04-02 19:54:52 +0100
kMDItemFSCreatorCode           = 0
kMDItemFSFinderFlags           = 0
kMDItemFSInvisible             = 0
kMDItemFSLabel                 = 0
kMDItemFSName                  = "Queens Of The Stone Age - Lullabies To Paralyze - 02 - Medication.ogg"
kMDItemFSNodeCount             = 0
kMDItemFSOwnerGroupID          = 501
kMDItemFSOwnerUserID           = 501
kMDItemFSSize                  = 6887073
kMDItemFSTypeCode              = 0
kMDItemID                      = 1058512
kMDItemKind                    = "Ogg Media File"
kMDItemLastUsedDate            = 2005-04-02 19:54:52 +0100
kMDItemMediaTypes              = (Sound)
kMDItemMusicalGenre            = "Rock"
kMDItemTitle                   = "Medication"
kMDItemTotalBitRate            = 500
kMDItemUsedDates               = (2005-04-02 19:54:52 +0100)


Working fine on my other Ogg files too, and the data shows up lovely in Spotlights main interface.

Do you have a website for testing this stuff, cause I would love to help out, maybe even code a little for you. I want to start work on a OggVorbis CoreAudio codec after my exams. This may be of use to your Euphonos Player, and it would be super seksy if it was distributed with your player smile.gif

Thanks

Jan


--------------------
Jan

http://www.eatmacadamia.com/ - http://www.kilvo.com/
Go to the top of the page
+Quote Post
Dibrom
post Jun 12 2005, 01:14
Post #3


Founder


Group: Admin
Posts: 2958
Joined: 26-August 02
From: Nottingham, UK
Member No.: 1



QUOTE (irchs @ Jun 11 2005, 06:44 AM)
Hey there, this thing is very nice smile.gif


Thanks. And I appreciate the feedback smile.gif

QUOTE
Do you have a website for testing this stuff, cause I would love to help out, maybe even code a little for you.  I want to start work on a OggVorbis CoreAudio codec after my exams.  This may be of use to your Euphonos Player, and it would be super seksy if it was distributed with your player smile.gif

Thanks

Jan
*


I don't have a website setup for it yet, but I probably will put something online in a few days. I will be releasing an updated version of this importer later today that is significantly improved. Not only do I add metadata for quite a few of the other apple provided fields now, but I've also added custom fields, and I even have a field setup that holds an array of strings (I'd use a dictionary, but that type isn't supported for the custom metadata schemas unfortunately) containing all xiphcomments or ape tags, so that all the tags are searchable according to their standard name in the spec even if there is no standard spotlight field for them.

Another difference in the new version is that I've added better codec detection for .ogg container files now so that the importer can determine whether the codec is vorbis, flac, speex, theora, or a dozen other formats that people have used.

As for help, that could certainly be useful. I'll see what I can get setup for collaboration here soon. Also, it would be quite nice to have a coreaudio vorbis decoder, and if it worked well, it'd certainly be nice to include something like that in the player bundle smile.gif
Go to the top of the page
+Quote Post
_Prelude_
post Jun 12 2005, 01:42
Post #4





Group: Banned
Posts: 3
Joined: 11-June 05
Member No.: 22646



Hmmmm... very cool idea. A player for Mac like foobar2000..
I don't have a Mac, but my old brother and some friends that use Mac computers for audio would be very interested with this player, and they could recommend it. smile.gif
Go to the top of the page
+Quote Post
Dibrom
post Jun 12 2005, 10:41
Post #5


Founder


Group: Admin
Posts: 2958
Joined: 26-August 02
From: Nottingham, UK
Member No.: 1



I was planning on releasing a revision of this importer earlier tonight, but I think I might hold off for a few days to polish up some of the rough edges and improve handling of other formats I haven't tested as much with yet.

Anyway, here's a preview of what the latest version is looking like with MPC:

CODE
07-Open Car.mpc -------------
com_euphonos_apeTags                = (
   "ALBUM=Deadwing",
   "ARTIST=Porcupine Tree",
   "TITLE=Open Car",
   "TRACK=7",
   "YEAR=2005"
)
kMDItemAlbum                        = "Deadwing"
kMDItemAttributeChangeDate          = 2005-06-12 02:31:52 -0700
kMDItemAudioBitRate                 = 239
kMDItemAudioChannelCount            = 2
kMDItemAudioSampleRate              = 44100
kMDItemAudioTrackNumber             = 7
kMDItemAuthors                      = ("Porcupine Tree")
kMDItemCodecs                       = (Musepack)
kMDItemContentCreationDate          = 2005-06-09 00:00:59 -0700
kMDItemContentModificationDate      = 2005-06-09 00:06:31 -0700
kMDItemContentType                  = "net.musepack.musepack"
kMDItemContentTypeTree              = (
   "net.musepack.musepack",
   "public.audio",
   "public.audiovisual-content",
   "public.data",
   "public.item",
   "public.content"
)
kMDItemDisplayName                  = "07-Open Car.mpc"
kMDItemDurationSeconds              = 227
kMDItemFSContentChangeDate          = 2005-06-09 00:06:31 -0700
kMDItemFSCreationDate               = 2005-06-09 00:00:59 -0700
kMDItemFSCreatorCode                = 0
kMDItemFSFinderFlags                = 0
kMDItemFSInvisible                  = 0
kMDItemFSLabel                      = 0
kMDItemFSName                       = "07-Open Car.mpc"
kMDItemFSNodeCount                  = 0
kMDItemFSOwnerGroupID               = 501
kMDItemFSOwnerUserID                = 501
kMDItemFSSize                       = 6790049
kMDItemFSTypeCode                   = 0
kMDItemID                           = 985676
kMDItemKind                         = "Musepack Audio File"
kMDItemLastUsedDate                 = 2005-06-09 00:06:31 -0700
kMDItemMediaTypes                   = (Sound)
kMDItemMusicalGenre                 = ""
kMDItemProfileName                  = "Insane"
kMDItemRecordingYear                = 2005
kMDItemTitle                        = "Open Car"
kMDItemTotalBitRate                 = 239
kMDItemUsedDates                    = (2005-06-09 00:06:31 -0700)
net_musepack_musepack_streamVersion = 7


This post has been edited by Dibrom: Jun 12 2005, 10:53
Go to the top of the page
+Quote Post
irchs
post Jun 12 2005, 16:00
Post #6





Group: Members
Posts: 49
Joined: 3-July 03
Member No.: 7543



Groovy beans, btw, if you need a good mirror, I will be glad to give you some webspace with unlimited bandwidth smile.gif I own monkeydev.org too if you need a website biggrin.gif It is located in the US, San Francisco smile.gif My MSN is chs@phucknut.net.

I shall check this thread periodically to give your importer some testing. Also, any chance of some source code?! smile.gif

Thanks

Jan

This post has been edited by irchs: Jun 12 2005, 16:06


--------------------
Jan

http://www.eatmacadamia.com/ - http://www.kilvo.com/
Go to the top of the page
+Quote Post
lh_sabre
post Jun 12 2005, 16:51
Post #7





Group: Members
Posts: 85
Joined: 4-March 03
Member No.: 5321



I say take your time with this plug-in--it'll be far more useful for most of us when we have a good player that can actually support all these great codecs wink.gif.
Go to the top of the page
+Quote Post
gordo
post Jul 8 2005, 20:41
Post #8





Group: Members
Posts: 19
Joined: 9-July 04
Member No.: 15221



Works with flac:

Soundtrack/Ry Cooder/Paris, Texas/01 - Ry Cooder , Paris, Texas.flac -------------
kMDItemAlbum = "Paris, Texas"
kMDItemAttributeChangeDate = 2005-07-08 15:30:30 -0400
kMDItemAudioBitRate = 671
kMDItemAudioChannelCount = 2
kMDItemAudioTrackNumber = 1
kMDItemAuthors = ("Ry Cooder")
kMDItemCodecs = (FLAC)
kMDItemContentCreationDate = 2004-08-19 07:22:04 -0400
kMDItemContentModificationDate = 2004-08-19 07:22:04 -0400
kMDItemContentType = "org.xiph.flac"
kMDItemContentTypeTree = (
"org.xiph.flac",
"public.audio",
"public.audiovisual-content",
"public.data",
"public.item",
"public.content"
)
kMDItemDisplayName = "01 - Ry Cooder , Paris, Texas.flac"
kMDItemDurationSeconds = 177
kMDItemFSContentChangeDate = 2004-08-19 07:22:04 -0400
kMDItemFSCreationDate = 2004-08-19 07:22:04 -0400
kMDItemFSCreatorCode = 0
kMDItemFSFinderFlags = 0
kMDItemFSInvisible = 0
kMDItemFSLabel = 0
kMDItemFSName = "01 - Ry Cooder , Paris, Texas.flac"
kMDItemFSNodeCount = 0
kMDItemFSOwnerGroupID = 501
kMDItemFSOwnerUserID = 501
kMDItemFSSize = 14852587
kMDItemFSTypeCode = 0
kMDItemID = 1942022
kMDItemKind = "FLAC Audio File"
kMDItemLastUsedDate = 2004-08-19 07:22:04 -0400
kMDItemMediaTypes = (Sound)
kMDItemMusicalGenre = "Soundtrack"
kMDItemTitle = "Ry Cooder / Paris, Texas"
kMDItemTotalBitRate = 671
kMDItemUsedDates = (2004-08-19 07:22:04 -0400)
Go to the top of the page
+Quote Post
raghu_nayak
post Jun 21 2006, 18:30
Post #9





Group: Members
Posts: 14
Joined: 27-February 05
Member No.: 20194



Hi. Can't download...

404 - Not Found sad.gif


--------------------
Go for Ogg

--------------------

It's Fast, Free, Open and has all stuffs that you need.
Go to the top of the page
+Quote Post
jarsonic
post Jun 21 2006, 20:11
Post #10





Group: Members
Posts: 200
Joined: 30-September 01
From: C-ville, VA
Member No.: 83



QUOTE (raghu_nayak @ Jun 21 2006, 13:30) *
Hi. Can't download...

404 - Not Found sad.gif


See here; seems the Euphonos project is on hold for now.

http://www.hydrogenaudio.org/forums/index....ndpost&p=393530

This post has been edited by jarsonic: Jun 21 2006, 20:11
Go to the top of the page
+Quote Post
shanecavanaugh
post Jun 22 2006, 06:53
Post #11





Group: Members
Posts: 6
Joined: 14-September 05
Member No.: 24481



QUOTE (raghu_nayak @ Jun 21 2006, 13:30) *
Hi. Can't download...

404 - Not Found :(

Mirror
Go to the top of the page
+Quote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



RSS Lo-Fi Version Time is now: 20th September 2014 - 06:05