Support and General Use > Audio Playback, Database and Playlists
SOLVED Grouping Tag
Buzkill:
Im not able to get the grouping tag to work as expected in tagnavi_custom.
Is it actually a usable tag like it says in on the database write up?
--- Code: ---%menu_start "custom" "metal group"
"metal" -> artist ? grouping ~ "metal" -> album -> title = "fmt_title"
--- End code ---
By using this i actually only get Songs Titles that have "Metal" in them
so it seems to be checking the "title" tag and not "grouping"
chris_s:
That's because the title is currently used when the grouping tag is empty, see here for an explanation from the person who originally implemented support for the grouping tag: https://www.rockbox.org/tracker/task/7362
--- Quote ---when building the database and a track doesn’t have a grouping tag, it copies the value from the title tag. This should make browsing through classcical works in the database a bit nicer since you will find all your music, not only titles having the grouping tag explicitely set (similar to the recent albumartist improvement). Y
--- End quote ---
I have to admit, I don't quite understand that reasoning, even in the context of classical works. I had the same experience as you where it seemed like the tag simply didn't "work" correctly in the database when I viewed groupings/works by composer, since the list was polluted by song titles, which is why I personally changed it in code for the version I'm running. It's very easy to do. Just look for the if statements in apps/tagcache.c that use has_grouping as a conditional and only keep the part that would be executed if has_grouping was true,
so from lines 2019 to 2026, only keep line 2021:
https://github.com/Rockbox/rockbox/blob/a8253c57ddec8a1dfb2f77e7be9c451595fb094a/apps/tagcache.c#L2021
and from lines 2048 to 2055 only keep line 2050:
https://github.com/Rockbox/rockbox/blob/a8253c57ddec8a1dfb2f77e7be9c451595fb094a/apps/tagcache.c#L2050
Buzkill:
--- Quote from: chris_s on September 01, 2021, 05:14:37 PM ---
so from lines 2019 to 2026, only keep line 2021:
https://github.com/Rockbox/rockbox/blob/a8253c57ddec8a1dfb2f77e7be9c451595fb094a/apps/tagcache.c#L2021
and from lines 2048 to 2055 only keep line 2050:
https://github.com/Rockbox/rockbox/blob/a8253c57ddec8a1dfb2f77e7be9c451595fb094a/apps/tagcache.c#L2050
--- End quote ---
Thanks for the tip! I'll test it out later today.
Buzkill:
--- Quote ---so from lines 2019 to 2026, only keep line 2021:
https://github.com/Rockbox/rockbox/blob/a8253c57ddec8a1dfb2f77e7be9c451595fb094a/apps/tagcache.c#L2021
and from lines 2048 to 2055 only keep line 2050:
https://github.com/Rockbox/rockbox/blob/a8253c57ddec8a1dfb2f77e7be9c451595fb094a/apps/tagcache.c#L2050
--- End quote ---
So i did this and it *kinda* worked. For my test I removed all grouping tags from all my music on the device, and then proceeded to label a single album with the grouping tag "Metal".
I added:
--- Code: ---"Heavy" -> artist ? grouping = "Metal" -> album -> title = "fmt_title"
--- End code ---
...to my custom nav file, but nothing shows up, Just <All Tracks> and <Random> telling me it found nothing. And so i tried this, with no condition, just to see what would show up...
--- Code: ---"Group Test" -> grouping -> artist -> album -> title = "fmt_title"
--- End code ---
and strangely all the Music WITHOUT grouping tags shows up and the entire album I added the "Metal" tag to show up in <UNTAGGED> perfectly sorted.
so it's as if the database is adding the track title to the grouping tag database if there is no grouping tag and leaving it untagged if there is a grouping tag.
Not sure what i did wrong or missed, or maybe something's changed,but you were saying you have it working so it must be on my end. Any ideas?
Buzkill:
it's as if the code is working like this...
--- Code: --- if (has_grouping)
{
#do nothing
}
else
{
ADD_TAG(entry, tag_grouping, &id3.title);
}
--- End code ---
Navigation
[0] Message Index
[#] Next page
Go to full version