Metadata Provider Overview

The metadata provider library, libmd, extracts metadata from media files on attached devices to provide client applications with up-to-date information on the media content available for browsing or playback.

Metadata is information that describes media files. This information can include details such as the artist name, album title, or year of creation (for a track), as well as playback details such as track runtime or picture dimensions. Clients use metadata to:

Clients make requests of libmd to extract specific sets of metadata fields from individual media files. With this design, clients can retrieve the exact metadata they need at precise times so they can optimize performance and the user experience. For example, suppose the user selects a track in their media browser. The application that provides media information to the browser can extract the track's creation information fields (which are small and fast to retrieve) but not its embedded artwork images (which can be large and slow to process). This strategy increases the browser's responsiveness.

Consider a cover flow application that allows users to visually browse their song collection and begin playback by selecting an album image. The application can extract the cover art when generating the flow of albums and then extract the artist name, year of release, and other album information when the user selects an album image. This "load-on-demand" philosophy supports a good user experience by ensuring the exact information—whether images or text—becomes available as soon as the user needs it.

Note: The multimedia synchronizer service, mm-sync, uses libmd to extract media metadata so it can upload that metadata to QDB databases. But updating databases requires indexing most or all files on a mediastore, so you might not want to rely on mm-sync for obtaining metadata and instead use libmd. Retrieving metadata through libmd lets you prioritize metadata extraction by reading metadata from one file or a select group of files.