getmusicbee.com

General => MusicBee Wishlist => Topic started by: illmatic on March 27, 2012, 08:08:43 PM

Title: Change song file format but keep playcount and rating
Post by: illmatic on March 27, 2012, 08:08:43 PM
Been advised to post this in the Wishlist in the hope it could be made possible in the future.

Basically I would like to be able to replace the song file with one of a different format - e.g. mp3 with m4a but maintain the playcount and rating of the original song.

I can do the first bit - replace the song file and relocate the file within MB, but once located the rating and playcount are reset.

I don't know how difficult this is to implement or whether it is even possible, but thought I would ask!

Many Thanks.
Title: Re: Change song file format but keep playcount and rating
Post by: greenday1987 on March 28, 2012, 06:29:11 PM
I'll +1 this incase I ever upgrade to FLAC
Title: Re: Change song file format but keep playcount and rating
Post by: Wolo on March 28, 2012, 06:34:52 PM
I'd be interested in this as well, +1
Title: Re: Change song file format but keep playcount and rating
Post by: beeing good on March 29, 2012, 06:11:50 AM
This could be very handy.
Title: Re: Change song file format but keep playcount and rating
Post by: Najica on March 31, 2012, 10:10:20 PM
I too sometimes change format and it'd be nice to retain the play count and rating  :)
+1
Title: Re: Change song file format but keep playcount and rating
Post by: paq on April 01, 2012, 03:48:21 AM
A tip for how it could be implemented, from an users perspective:
* Select the song you wish to change the source for and choose Tag Editor > Properties.
* Now at the bottom you have Location. You can now either
a) Edit the location, like replace .mp3 with .flac if the new file is in the same folder or change the location completely.
OR
b) If you click the button in the location field you would get a "Save as"-dialogue instead of the "Chose folder" as it is now. If you would then select an already existing file then that would be the new source, otherwise you would copy/move the file (whichever it does now).

Right now when you want to save it tells you that the file already exists but this could be changed into a pop-up warning: "Do you want to change the location to this already existing file? Tags/metadata will replace current tags in the new file and the old file will be unlinked from your library. OK / Cancel"

One downside with this though is that you can't do it as a batch process. Another idea that could solve this would be if you could select multiple tracks, Edit > Copy tags and then paste onto multiple tracks. This would also include some of the data under properties as play/skipped count. This would of course only work if you would copy from the same number of tracks that you would paste onto, and the copy/paste would go sequentially.
Title: Re: Change song file format but keep playcount and rating
Post by: illmatic on April 01, 2012, 08:43:43 PM
paq, that sounds pretty much exactly what I'd like to do - particularly like the idea of doing it as a batch process for a full album. Would save a lot of time!
Good to see there's a bit of support for this suggestion, hopefully Steven can take a look at it sometime.
Title: Re: Change song file format but keep playcount and rating
Post by: Aleks.TS on June 24, 2012, 01:45:43 PM
+1
Title: Re: Change song file format but keep playcount and rating
Post by: Steven on June 24, 2012, 02:41:56 PM
this seems a fairly popular request and something i had in the back of my mind as well
i will do this, but am thinking just adding another option on the file converter dialog
ie.
select file/ Send To/ Format Converter
Title: Re: Change song file format but keep playcount and rating
Post by: paq on June 24, 2012, 11:04:41 PM
this seems a fairly popular request and something i had in the back of my mind as well
i will do this, but am thinking just adding another option on the file converter dialog
ie.
select file/ Send To/ Format Converter

I am not sure I follow you, could you please elaborate? Will this option let you replace existing files with new ones in a different format while retaining tags, rating and play/skipped count?
Title: Re: Change song file format but keep playcount and rating
Post by: Steven on June 25, 2012, 06:13:21 AM
yes it already has that functionality
Title: Re: Change song file format but keep playcount and rating
Post by: Steven on June 27, 2012, 09:56:07 PM
i've added playcount preservation as an option to the file converter, and also in the tag editor if you rename the file extension it uses the highest quality converter settings to re-encode the file.
However, its not so great in that it locks up the GUI while the conversion is done. I have said at some point i will make tag editing save in the background but at the moment its not something i am prepared to take on.

http://musicbee.niblseed.com/V2/MusicBee_Exe_Patched.zip
Title: Re: Change song file format but keep playcount and rating
Post by: greenday1987 on June 28, 2012, 01:47:35 PM
That doesn't cover replacing the files with files from another source though unless I am mistaken. ie download an album in MP3 then later buy the CD and and rip my own FLAC. I can't delete the MP3 rip from my 'pc and library' and rescan finding the fresh FLAC rip in it's place and have the playcounts etc etc transferred from the MP3 to the FLAC version. The above posted tweak could be handy though :)
Title: Re: Change song file format but keep playcount and rating
Post by: Steven on June 28, 2012, 07:05:05 PM
That doesn't cover replacing the files with files from another source though unless I am mistaken. ie download an album in MP3 then later buy the CD and and rip my own FLAC. I can't delete the MP3 rip from my 'pc and library' and rescan finding the fresh FLAC rip in it's place and have the playcounts etc etc transferred from the MP3 to the FLAC version. The above posted tweak could be handy though :)
would Edit/Copy Tags (Ctrl-C)
then paste on the flac file not do what you want for this scenario?

edit:
that wouldnt copy ratings, or playcount so what i will do is create a hot-key command to copy all those values
Title: Re: Change song file format but keep playcount and rating
Post by: greenday1987 on June 30, 2012, 01:06:10 PM
Thanks Steven for all your efforts. That's an excellent idea
Title: Re: Change song file format but keep playcount and rating
Post by: paq on July 09, 2012, 01:54:29 AM
edit:
that wouldnt copy ratings, or playcount so what i will do is create a hot-key command to copy all those values

This has been implemented in version 2.0.4572, which is nice and I thank you for that! :)

I wish though to also have it in the Edit menu to make it more visible and accessible. Also, it would minimize the risk of someone asking for this feature again, because they didn't look through the hotkeys. While the first option already is called "Copy Tags", this could be called "Copy Tags, Counts and Ratings" and be just beneath it.
Title: Re: Change song file format but keep playcount and rating
Post by: illmatic on July 09, 2012, 10:53:24 PM
Thank you Steven for looking at my request and implementing a solution, if only all developers could be so responsive!

Just so I understand correctly: to replace an mp3 with FLAC, for example (i.e. not using the file converter), I would add the FLAC files to the library, then use the hot key to copy the tags including playcount etc. from each mp3 file and paste onto the corresponding FLAC. Then once finished for all the tracks, delete the mp3 files.

Sounds straightforward enough, obviously I'll try it out once I get chance.

Thanks again.  8)
Title: Re: Change song file format but keep playcount and rating
Post by: paq on July 10, 2012, 12:22:29 AM
Just so I understand correctly: to replace an mp3 with FLAC, for example (i.e. not using the file converter), I would add the FLAC files to the library, then use the hot key to copy the tags including playcount etc. from each mp3 file and paste onto the corresponding FLAC. Then once finished for all the tracks, delete the mp3 files.

Yes, but you can in fact copy tags from several files, and then paste onto the same number of files, at once which is great! So you don't need to copy'n'paste for each track on an album.

However keep in mind that when you delete your mp3-files, any references to them in your playlists will also get lost. I guess if you want to keep your playlists intact you'll have to use the file converter when replacing the files.
Title: Re: Change song file format but keep playcount and rating
Post by: illmatic on July 11, 2012, 11:16:01 PM
This works really nicely, just what I wanted to do. I especially like the way you can paste onto several tracks at once, makes it much quicker. Thanks again.

paq - I understand what you mean about the playlists, but I don't think you can use file converter when going from lossy files to lossless (unless I'm missing something - it has been known...).
Title: Re: Change song file format but keep playcount and rating
Post by: paq on July 12, 2012, 01:16:45 AM
paq - I understand what you mean about the playlists, but I don't think you can use file converter when going from lossy files to lossless (unless I'm missing something - it has been known...).

In the File Converter dialog there is an option called "when the output file already exists, skip conversion and synchronize tag values only". I haven't tried it myself but I guess it will replace your lossy files with your lossless files if you set up the File Converter so that the resulting files would end up exactly where your lossless files already are.
Title: Re: Change song file format but keep playcount and rating
Post by: wombleywoo on February 12, 2023, 01:17:45 PM
If anyone is interested, I have created a crowdfunding campaign to pay a developer to make a plugin which automates this process!

https://gofund.me/38c41b2e