Skip to main content

Module covers

Module covers 

Source
Expand description

Album covers for the web UI and share pages: embedded art, resized to one of a few sizes, encoded as JPEG, and kept.

Reading embedded art means opening the audio file and parsing its tags, and the art itself is often megabytes; doing that per tile made an albums grid pull tens of megabytes and seconds of server time. Resized covers are kept on disk under the config directory, keyed by the source file’s path, size and mtime so a re-tag is a new key, and the hottest are also held in memory. An album with no art is remembered too, so a grid of them does not reopen every file on every visit.

Structs§

Covers