Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Write lyrics to id3 tag #23

Open
dmo60 opened this issue Apr 15, 2013 · 10 comments
Open

Write lyrics to id3 tag #23

dmo60 opened this issue Apr 15, 2013 · 10 comments

Comments

@dmo60
Copy link
Owner

dmo60 commented Apr 15, 2013

Add an option to write the lyrics to the lyrics tag of the audio file. Python mutagen can be used for it.

@dmo60
Copy link
Owner Author

dmo60 commented Nov 1, 2013

I tried using mutagen and it was working quite well (you can find it on the experimental branch).

Unfortunatly, Rhythmbox 3 uses Python 3 and mutagen is not available there, so I won't put any more efforts in this. Perhaps I will find another easy way to do it someday.

@Hunsu
Copy link

Hunsu commented Mar 27, 2014

I have found two library that support python 3. https://github.com/LordSputnik/mutagen and https://code.google.com/p/stagger/.

@dmo60
Copy link
Owner Author

dmo60 commented Mar 27, 2014

Cool, the first one looks promising. I might try that. It's not my highest priority at the moment, but I'm definitely planning to implement this someday!

@Hunsu
Copy link

Hunsu commented Mar 27, 2014

I planing to do it too! Have you written some code that could help me as you are saying that you used mutagen before?

@fossfreedom
Copy link

me again - mutagenx works very well - the syntax is identical to python2 mutagen and I would warmly recommend using this. I use this on coverart here - the same code works on both python 2 based RB2.96-2.99 and python3 based RB3

@dmo60
Copy link
Owner Author

dmo60 commented Mar 27, 2014

You can find my attempt using mutagen for python 2 in the experimental branch, mainly here:
https://github.com/dmo60/lLyrics/blob/experimental/lLyrics/Util.py

@Hunsu
Copy link

Hunsu commented Apr 20, 2014

I have implemented this and the changed the search method. The search method as next :

  • Look if there's lyrics in audio tag (only for mp3 and ogg files)
  • if not search for lyrics sources with Google (in future we may search others searcher)
  • We use an xml file that contains lyrics sources to parse lyrics from the source.

The xml file contains the informations :

  • The source name
  • The name of the tag that contains lyrics (eg. div.lyrics)
  • The tag number if there's not a specific tag for lyrics
  • The start string as you used it in your lyrics sources
  • The end string.
    The lLyrics.py code must be changed, I will do it when I have some time. There's a problem the xml file must be in home folder. When I put it in lLyrics folder it doesn't work. I will add others sources later. What about the downloadAllLyrics I implemented? have you take a look at it?

the code is here https://drive.google.com/file/d/0B25ViosYm6ByY3l5VHJnVkdjQ28/edit?usp=sharing

Edit :
I have made many changes to this code. I think I could give the final version next week.

@dmo60
Copy link
Owner Author

dmo60 commented Apr 22, 2014

First, thanks for your work! To be honest, these are some big changes and I currently don't have the time to review them all. I have had a look at your downloadAllLyrics and had some small issues, but I don't remember them in detail.

It would be easier for me to merge your changes, if you could submit a pull request: https://help.github.com/articles/using-pull-requests

I'm looking forward to your final version and I hope I will find some time to test it properly. I will give you feedback as soon as I can.

@Hunsu
Copy link

Hunsu commented Apr 26, 2014

So to make a pull request I must fork you project? I will do it when I have some time. Are you ok with the new search method?

@CreamyCookie
Copy link

That feature would be super amazing! 👍

It would also be nice to show the lyrics that are included in the tags (if the lyrics couldn't be found).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants