More > JRiver Media Center 23 for Mac
Multiple Disc File Naming Expression
jeffcdo:
--- Quote from: RD James on April 06, 2018, 01:49:42 am ---How's this?
--- Code: ---ListBuild(
1,
/ -/ ,
If(Compare([Total Discs], >, 1), [Disc #], ),
PadNumber([Track #], 2),
[Name],
)
--- End code ---
--- End quote ---
I tried this but it seems to put the slashes and dashes in the wrong place(s). It's the right idea though. For now my solution has been using a separate preset for multi-disc sets.
RD James:
That's strange, there shouldn't be any slashes in the output, they're only escaping the spaces around the dash.
The previous expression just added everything as separate list items, this groups [Disc #] and [Track #] together.
--- Code: ---ListBuild(
1,
/ -/ ,
If(Compare([Total Discs], >, 1), [Disc #]-, )PadNumber([Track #], 2),
[Name],
)
--- End code ---
RoderickGI:
RD, I ran both those expressions in an Expression Column of a View I have for 7 albums which have 2 discs each. In fact, the View shows two copies of each Track, one being the original FLAC rip from the CD, and the other being a conversion to M4A done using MC, for use in a vehicle.
Neither expression gave the wanted result of "[Disc #]-[Track #] - [Name]" for most of the albums. Only the last album and only the FLAC files did. So I had a look at the [Total Discs] tag, which I haven't played around with before, and found only the last album had values in the tag, which explained the expression result. So I checked the [Total Tracks] and found values in it for all FLAC files, but none of the M4A files.
So now I am wondering how and when those tags get populated, since I didn't manually populate them. I always thought they were manually populated, which is why I haven't mucked around with them. Obviously you use them, since you included [Total Discs] in your expression, so do you know when they are populated, or do you manually populate them?
They are the correct fields to use in this sort of expression. If they were auto-populated they would be very useful.
RoderickGI:
I think I answered my own question, after falling down the rabbit hole which results from searching the forum for "Total Discs".
It looks like that values in the [Total Discs] and [Total Tracks] tags have come from YADB when I ripped the CDs, and of course they are not carried over to the converted files.
What a shame they aren't auto-calculated, with the ability to manually override of course. But I guess manually entering them wouldn't be too much work, and would be of value.
RD James:
If I recall correctly, [Total Discs] was added to Media Center 1-2 years ago, so anything imported prior to that will need updating.
I'm not sure whether Media Center's "update library from tags" function will pull that in for existing files - some tag changes require that you remove and re-import an album.
Unfortunately I ran some tests and it only seems to fill this information out if your [Disc #] tag is in the format "2/4" for disc 2 of a 4-disc album for example.
If it's just "2" in a directory with three other discs, Media Center doesn't give you a total.
And if you fill out the [Total Discs] field manually, it does not write any tags to the file at all - even if you use the "write tags to files" feature. It does not use the "2/4" format or store it in a unique tag.
So if you convert the tracks externally from Media Center - or perhaps even using Media Center - that information will be lost.
That said - and it's partially due to Media Center's prior lack of [Total Discs] support whatsoever until recently - I have largely switched to using Media Center's "fill track numbers from list order" tool on multi-disc albums.
In my library at least, I see very little reason for the concept of "discs" to actually exist any more. I don't clear out the [Disc #] tag, but rather than naming files: "1-14", "1-15", "2-01", "2-02" I have tracks: "14", "15", "16", "17" etc.
What I do rather than clearing out the original information is have the "fill track number from list order" use the [Episode] tag. I then use expressions which rename files or sort by [Episode] rather than [Track #] if it is not empty.
I also do this in reverse for TV shows. Rather than "[Season]-[Episode] - [Name]" I use [Track #] as a prefix which is a continually incrementing number rather than starting over again for each season.
As a bonus, this works better for shows which have a movie or two in-between seasons.
For example: Battlestar Galactica (2003) essentially has:[*]Miniseries - 2 episodes
[*]Season 1 - 13 episodes
[*]Season 2 - 20 episodes
[*]Season 3 - 20 episodes
[*]Movie / Special 1
[*]Season 4 - 20 episodes
[*]Movie / Special 2[/list]
That's a nightmare to try and tag and sort correctly in a single list view. You have to trick it by using intentionally wrong [Season] and [Episode] tags, which I don't like.
What I do is keep the correct information in the [Season] and [Episode] tags for file naming, but use [Track #] as a prefix, which makes managing file sorting or playback order far easier.
That way I don't have to call the Miniseries "Season 0" or the specials "Episode 21".
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version