• Post Reply Bookmark Topic Watch Topic
  • New Topic

reading title/artist info from cd  RSS feed

 
Jim Henessey
Ranch Hand
Posts: 32
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

I'm writing a program for myself to keep track of the cds in my cd collection. In order to avoid the tedious task of having to type in the title/artist info for each track on the cd, I would like to have an interface allowing me to read the info off of the cd in my cd-rom drive.

My question: how do I do this? I've had a rough time searching for this on google - I know the javax.sound library is used for ripping the music off of the cd, but I'm unable to find out how I pull the title/artist info - I have no interest in pulling the songs off of the cd for this app.

If anyone can help me with this, I appreciate it. I searched for threads dealing with this subject in this forum but found none - if I missed it, and this has been previously answered, a link to the previous answer would be more than enough.
 
Ernest Friedman-Hill
author and iconoclast
Sheriff
Posts: 24215
37
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I could be wrong (I have no personal experience here), but my understanding is that the info you want is not on the CD. Because of this, online databases of CD title/artist/track data have been set up; first the no-longer-free CDDB, and now FreeDB. Using such a database, you can compute a sort of checksum for a disk and then look up the information from your software. Check out the FreeDB web site for technical info on using their database.
 
Jim Henessey
Ranch Hand
Posts: 32
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You're completely right - this was a "duh" moment for me. For some reason, I always thought that Gracenote/FreeDB was called in only if the information couldn't be found on the cd itself.

For those who come across this thread for whatever reason, a useful class for determining the discid (necessary for retrieving the information from an on-line database) can be found at:

http://www.lint.com/DiscTracker/src/DiscInfo.java

With the accompanying c library for windows at:

http://www.lint.com/DiscTracker/src/DiscInfo_Windows.c
 
Randy Scovil
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I know it's a longshot but if anyone has info on this topic or the files referenced in the post above (couldn't even find them cached) I'd appreciate a heads-up.

Thanks.
 
Ernest Friedman-Hill
author and iconoclast
Sheriff
Posts: 24215
37
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Randy Scovil:
I know it's a longshot but if anyone has info on this topic or the files referenced in the post above (couldn't even find them cached) I'd appreciate a heads-up.

Thanks.


Hi,

Welcome to JavaRanch!

I just googled "Java FreeDB" and the first hit is a library that does what you need.
 
Randy Scovil
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Either the first link has changed, or I think we're talking about two different things (more likely.)

I sincerely appreciate the effort though and welcome any info on CD reading.
 
Rob Spoor
Sheriff
Posts: 20903
81
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you looked at the post date you would have seen that post was almost 5 years old.

Using Google I found this. It seems to be able to connect to a FreeDB server, and also read CD information (using CDDriveWin / CDDriveLin). It does require a DLL file though, which you can get at http://www.antelmann.com/developer/.

And if that does not work, try this
 
Randy Scovil
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As I suggested, this may be about two different things and I'll take responsibility for that.

I am interested in reading the disc proper, not FreeDB. I could not locate the linked files anywhere and despite the age of the post the best available option was to try the longshot that someone had it offline since this appears to be the only place it is referenced and therefore the best place to ask.

I'll continue my search, and thanks.

 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!