What I want is: If there are more than one picture for cover art, so there can be for example a picture that has cover-art-type “front” and an other that has cover-art-type “back”. I want to save the pictures as “front.png” and “back.png”. There for I am searching for a variable like %cover-art-type% to put this in the input mask:
Options → Option… → Cover Art → using the following file name for
images: %cover-art-type%
So if the last option “Always use primary type” is un ticked, then what happens to artwork with two types? The infamous ‘cover,booklet’ example for instance?
Not what I was expecting. I thought the tick box applied on a file by file basis… But anyway… If I have a file that has types Front,Booklet. The primary type is Front.
is there any way to have two files created/downloaded. One of type Front and saved as cover.jpg and the other booklet.jpg
is the downloading of cover art handled by a script anywhere? I’d like to do other things like append the comments to the file name.
Not quite sure what you mean by a “file by file basis”. But all it does is that it saves files that are not of type “front” with the filename set to the type. That’s of course per file. Actually you could achieve something similar by setting the following script as the cover art name:
That’s mostly equivalent to using the option. Images of type “front” will be saved as “cover” (or however you name it in the script), everything else will be named by its type, e.g. “booklet” or “medium”.
No, duplicating the downloaded files that way is currently not possible.
You can’t script the download, but you can script the file naming (by using a script in the “use the following filename for images” text field). There is the special %coverart_comment% variable you could use:
Thanks for the information and the link to documentation.
Just to confirm… If there is a single file with the cover in it which is also the first page of the booklet, let’s assume it will have the Primary type of ‘Front’ and a secondary type ‘Booklet’. Other pages of the booklet will be have the type booklet and will download as Booklet(1), Booklet(2) etc…
There’s no way to have two copies downloaded or created on my computer - one called Cover.jpg and the other Booklet.jpg?
The reason why I’d like to do that is so that the file name pattern Booklet* will refer to all of the files with images of the booklet.
The reason for asking about the script is that the other thing I’d like to be able to do is to write metadata into the jpg files - all the usual stuff like album title, artist title and then MB ids. Is there a way to this?
Can this be done in the cover file name mask? What other variables are available? For example Is there anything holding the order/sequence number of the file?
There is currently no built-in way to save the same image twice by type.
The scripting is only generating the filenames for the covers. Picard currently has no tagging support for image files. This would be a valid feature request. But to be honest I doubt anyone would work on this soon. Image metadata is a complete separate beast, and there are more pressing issues for cover art support that need to be tackled. But feel free to open a ticket for it. As an open source project sometimes unexpected contributions tackle some specific issues.
The variables available for the file naming script for cover art are all the normal tags plus the image specific ones documented in the Picard documentation I linked above.
Note that image saving triggers per saved file. So if you use track specific tags in your naming script you would end up with all the images getting saved separately for each track.
Oh, and the image sequence / position numbers might indeed be interesting to have. I could imagine the we have separate %image_number% and %image_type_number% variables available. The first one just is based on the position, the second one is the same but only for the same primary type.
That is something that then could also be used to give unique names to images instead of relying on Picard’s auto numbering on file name conflict.
A very hackish way that could work would be by leveraging different naming scripts based on track number.
Let’s say the scripts checks for track number 1 and only saves images with the main type. But if it is not track 1 and the image types contain “booklet” it saves it with name “booklet”.
Will require that there are always at least 2 files being saved, the one for track 1 and at least one other.
This should save images that contain the type “booklet” always with the name “booklet”. All images that are not of type booklet or all images on track 1 get saved by the second part, which will save images of maintype “front” as “cover” and all other with the name of the main type.
You must disable “Always use the primary image type as the file name for non-front images” for this to work, as otherwise the naming script is not used for non-front images.
No, artwork in general is just another piece of metadata which is applied per file. This e.g. happens if you have embedded artwork in the files (and no loaded data that overwrites it). Picard attempts to avoid separate saving the same file multiple times by checking if it got already written.
But the cover art sources actually all work on a release level.
Really the cover art handling has many things that should be improved.