Cover art scripting variables

Tags: #<Tag:0x00007fe314e8bbe8> #<Tag:0x00007fe314e8b710>

Is there a picard variable for the number of cover art images found for a release? I only see the coverart_maintype, coverart_types and coverart_comment variables in the documentation. I would like to be able to use the number of images in my cover art naming script. Picard shows the number of images found in the right-hand pane when it has identified a release so the information is known but it doesn’t appear to be exposed in a variable that can be used in scripting.

You mean a number like this?
image

I am not a script writer, but I use them. One of the following is supplying that number to me

What you require is Inline Stuff from @jesus2099

http://userscripts-mirror.org/scripts/show/81127

Ahhhh… but have I misread your question? I now realise you mean Picard and not the website… but I’ll still leave this here in case you can crib something useful from it.

Currently not, but this could be added I think. Just to be clear, what exactly is your use case? Do you just want the total number (e.g. 3) or is your goal to actually have a numbering for each file (1-3)?

1 Like

Hi, thanks for the replys

I’m just looking for the total number.

I just recently discovered one could use the scripting language in the “Use the following file name for images” setting and now I’m trying to go back and apply some organization to my album art. My goal is to have the front cover stored with the album tracks with the name folder.jpg and then have a folder named something like “AlbumArt” that contains the available album art that I selected in the Cover Art Archive options (front, back, booklet). If there is only 1 image, I assume that it is the Album cover and then I just want to save it with the tracks as folder.jpg.

I’m using your cover art naming script that I found in this forum with the addition of a folder name.

$if($inmulti(%coverart_types%,booklet),AlbumArt/booklet,$if($eq(%coverart_maintype%,front),folder,AlbumArt/%coverart_maintype%))

It does pretty close to what I want but it doesn’t include the front cover in the AlbumArt folder and creates the AlbumArt folder even if the only image is the album cover.

I was thinking that if the script could tell how many images were available then I could add some logic to get the result I want.