Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: Playlist view grouping - exclude unnecessary (Read 926 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Playlist view grouping - exclude unnecessary

Recently, I began to save genre fields using Mp3tag with RateYourMusic, but there is a feature - there are songs in one album with different genre tags and they break up in my playlist - as if they are different albums, I hope you understand me. There is no genre in your grouping script. Help set up the string so that, with any differences other than artist - year - album - disknumber - nracknumber - title, it will still be displayed together as a complete album. Here is my old line, maybe there is a lot of garbage in the beginning, but it worked until recently

$puts(va_string,'VA')$if($stricmp($meta(va),'1'),$puts(va,1))$if($stricmp($meta(various),'1'),$puts(va,1))$if($stricmp($meta(various artists),'1'),$puts(va,1))$if($stricmp($meta(album artist),'va'),$puts(va,1))$if($stricmp($meta(album artist),'various'),$puts(va,1))$if($stricmp($meta(album artist),'various artists'),$puts(va,1))$if($stricmp($left(%directoryname%,3),'va-'),$puts(va,1))$if($stricmp($left(%directoryname%,3),'va '),$puts(va,1))$if($stricmp($left(%directoryname%,3),'va_'),$puts(va,1))$if($strstr($lower(%path%),'\va\'),$puts(va,1))$if($strstr($lower(%path%),'\various\'),$puts(va,1))$if($strstr($lower(%path%),'\various artists\'),$puts(va,1))$if($strstr($lower(%path%),'\_va\'),$puts(va,1))$if($strstr($lower(%path%),'\_various\'),$puts(va,1))$if($strstr($lower(%path%),'\_various artists\'),$puts(va,1))$if(%tracknumber%,$if(%album%,$if($stricmp($get(va),1),$get(va_string),$if2($meta(album artist),%artist%))$if('('%catalog%')', '('%catalog%')',)$if(%year%, • %year%)$if(%album%, • %album%),$replace(%path%,%filename_ext%,)),$replace(%path%,%filename_ext%,))$if('('CD%discnumber%')', • '('Disk %discnumber%[ - %discsubtitle%]')',)$if(%genre%, • %genre%,)$if(%style%, • %style%,)$if(%comment%, • %comment%,) • '['$upper($if($stricmp($ext(%path%),cue),Image,$if($stricmp(%__cue_embedded%,yes),Image,Tracks)))']'

It would also be great to pull the duration of the album into this line

Re: Playlist view grouping - exclude unnecessary

Reply #1
$if(%genre%, • %genre%,)$if(%style%, • %style%,)

^ Note this part? It splits them up because you are grouping by genre/style tags, and if each track has different values, it makes a new group. This is how grouping works.

So your options are ...

A) Edit tags - Make the genre/style tags the same for ALL tracks per album.

B) Edit group - Remove the genre/style pattern quoted above from the grouping. (No genre/style in grouping)

C) Edit tags+group - Group only the first genre/style value and make sure they are the same for ALL tracks per album...

Code: [Select]
$if(%genre%, • $meta(genre,0),)$if(%style%, • $meta(style,0),)

^ $meta(genre,0) shows only the first value of the tag. $meta(genre,1) would show the second value (if you add it), and so on... If you edit tags to make sure the first (or/and second) value is the same for ALL tracks per album, then remaining values can still be specific per track, and the grouping still works. ("Best of both worlds")

D) Edit group - Modify the grouping pattern to exclude one or two specific genre/style values...

Code: [Select]
$if(%genre%, • $replace(%genre%,', Pop',),)$if(%style%, • $replace(%style%,', Instrumental',),)

^ $replace(%genre%,', Pop',) - This removes the text string ', Pop' from appearing in the grouping, but only if not the very first value (because the comma before ', Pop'). This would only be useful to remove a few extraneous values from the grouping that you still want to keep tagged (like STYLE=Instrumental). (The $replace could be tweaked to catch the first value too...)

These are the options I got. Not sure there are any more.

Personally, my preferred way of tagging is to keep GENRE the same per album (for use in groupings), and then tag STYLE with different values per track. (But then I only tag a few values manually to help remember tracks, not using some database with hundreds of sub-categories...)


Quote
It would also be great to pull the duration of the album into this line

Only possible on EsPlaylist (DUI/CUI) %es_subgroup_length% - or SimPlaylist (DUI) %length%

(Unless you add a custom tag, would probably need to use SQL for that - too complicated for me)

Re: Playlist view grouping - exclude unnecessary

Reply #2
Thank you for your help, you understand the topic perfectly. I really stepped in - I have a genre in the sorting myself)))

- The question is - how do I leave the genre display from the tags in this line above the album (just for information, I'm used to this) but not sort by genre, leaving only the visual?

shows only the first value of the tag

Do you mean the first genre of lo separator?

I'll figure out how I can apply your best practices, they are interesting.


Re: Playlist view grouping - exclude unnecessary

Reply #3
Another question is off topic, but I didn't want to clog up the forum - the display with commas and semicolons - with equal rules for filling in tags (separated by semicolons) is displayed differently. Couldn't find a pattern, maybe you understand?







Re: Playlist view grouping - exclude unnecessary

Reply #4
@anamorphic I replaced $if(%genre%, • %genre%,) it with $meta(genre) one sorting is happening

Could you tell me in simple words the difference between both $if and $meta and how to leave the information but ignore the sorting

Re: Playlist view grouping - exclude unnecessary

Reply #5
Another question is off topic, but I didn't want to clog up the forum - the display with commas and semicolons - with equal rules for filling in tags (separated by semicolons) is displayed differently.

Probably the genre tag is not split for multi-value correctly - right-click track(s) > Properties > right-click Genre > Split Values... make sure ; (semicolon) is in the box > OK > OK.

@anamorphic I replaced $if(%genre%, • %genre%,) it with $meta(genre) one sorting is happening

I guess you made a typo there (missing zero?) but to recap  ...

%genre% and $meta(genre) are exactly the same. (They display the same)

I said to use $meta(genre,0) - this only displays the first value. Example -

In right-click Properties:
GENRE tag = Value1; Value2; Value3

In layout / playlist:
%genre% = Value1, Value2, Value3

$meta(genre) = Value1, Value2, Value3

$meta(genre,0) = Value 1

$meta(genre,1) = Value 2

$meta(genre,2) = Value 3

(etc)

Quote
Could you tell me in simple words the difference between both $if and $meta and how to leave the information but ignore the sorting

Not possible to "leave the information but ignore the sorting"

$if(%genre%, • %genre%,) = "If genre tag exists, display %genre%, else display nothing". Better to use an $if in case some tracks do not have GENRE tag. Without the $if it would display ? (question mark) when there is no tag.

So to recap, if you make ALL tracks in the album have the same GENRE = Value 1, you can use $if(%genre%, • $meta(genre,0),) for the grouping. Tracks can then have a different Value 2, Value 3 and so on (NOT displayed in grouping - display the complete genre/style tags somewhere else like a playlist column or "now playing" panel - does your layout have a "now playing"?)

It is simply not possible for tracks to have different values and display in the same grouping together. Not possible. Same value = same grouping. Different value = different grouping.

(And if you're not happy doing that, you have option A or B above in my first reply - though I think option D to $replace a value can get too complicated and not worth the effort with hundreds of possible genres. Edit: Just curious why did you want to tag RateYourMusic genres to begin with?)

 

Re: Playlist view grouping - exclude unnecessary

Reply #6
@anamorphic Thank you so much for the voluminous reply. You have dispelled many of my doubts. Regarding the genres of rate your music, for a long time I have been independently determining genres and styles by ear, taking into account the nuances of performance, I came to the conclusion that this site is the most accurate in this regard. I would appreciate it if you could share your views.

My list:

rateyourmusic.com
metal-archives.com
last.fm
en.wikipedia.org
bandcamp.com (*tags)