Configuring Metadata Providers

You can configure metadata providers (MDPs) in two ways: in the configuration file to define initial settings and through the libmd API to define settings for individual metadata extraction sessions.

During startup, libmd reads its configuration file and loads each listed MDP. After an MDP loads successfully, libmd initializes the MDP with any settings assigned to it in the configuration file. These settings apply to the MDP throughout the client application's lifetime.

When libmd has finished setting up, your client can create metadata extraction sessions and assign parameters to those sessions to influence how MDPs extract metadata in any metadata retrieval operations associated with that session.

To assign parameters to sessions, the client must call mmmd_session_params_set() while providing the session handle and the list of parameters, represented as a dictionary of key-value pairs. Parameters defined in this manner apply only to the session referred to by the API call.

Note: The MDP settings recognized by libmd when parsing the configuration file differ from those you can assign to a metadata extraction session through the API. See the default configuration file for the supported configuration file settings.