ICodecAPI interface

The ICodecAPI interface sets and retrieves settings on an encoder or decoder filter.

Methods

The ICodecAPI interface has these methods.

Method Description
ICodecAPI::GetAllSettings The GetAllSettings method gets the codec's current properties and writes them to a stream.
ICodecAPI::GetDefaultValue The GetDefaultValue method gets the default value of a codec property.
ICodecAPI::GetParameterRange The GetParameterRange method gets the range of values for a codec property.
ICodecAPI::GetParameterValues The GetParameterValues method gets the list of possible values for a codec property.
ICodecAPI::GetValue The GetValue method gets the current value of a codec property.
ICodecAPI::IsModifiable The IsModifiable method queries whether a codec property can be changed, given the codec's current configuration.
ICodecAPI::IsSupported The IsSupported method queries whether a codec supports a given property.
ICodecAPI::RegisterForEvent The RegisterForEvent method registers the application to receive events from the codec.
ICodecAPI::SetAllDefaults The SetAllDefaults method resets all codec properties to their default values.
ICodecAPI::SetAllDefaultsWithNotify The SetAllDefaultsWithNotify method resets all codec properties to their default values, and returns a list of the properties that changed.
ICodecAPI::SetAllSettings The SetAllSettings method reads codec properties from a stream and sets them on the codec.
ICodecAPI::SetAllSettingsWithNotify The SetAllSettingsWithNotify method reads codec properties from a stream, sets them on the codec, and returns a list of the properties that changed.
ICodecAPI::SetValue The SetValue method sets the value of a codec property.
ICodecAPI::SetValueWithNotify The SetValueWithNotify method sets a property on a codec and returns a list of other properties that changed as a result.
ICodecAPI::UnregisterForEvent The UnregisterForEvent method unregisters the application for a specified encoder event.

Remarks

This interface defines a generic mechanism for setting properties on a codec (encoder or decoder). A codec property is a key/value pair, where the key is a GUID and the value is a VARIANT. The interpretation of the VARIANT data depends on the property GUID. For a list of codec property GUIDs, see Codec API Properties.

Codec Profiles

Codecs can optionally store profile and capability information in the system registry. This information enables applications to query the device during device enumeration. Default profiles are stored in the following registry key:
HKEY_LOCAL_MACHINE
   Software
      Classes
         CLSID
            Category
               Profiles
Each profile is a registry key whose default string is a text description of the profile. Each value has a GUID name, followed by a string value containing the numeric GUID value. For example:
C++
  HLKM\Software\Classes\CLSID\<category>\Profiles\DVD
    default "HQ DVD"
    REG_SZ {...} = "0"
    REG_SZ {...} = "1234"
where {...} is a property GUID that the application can map into its user interface. Microsoft is currently considering the definition of a set of standard profiles.

Default codec capabilities are stored under HLKM\Software\Classes\CLSID&lt;category>\Instance&lt;Filter CLSID>\Capabilities. Each value has a GUID name, followed by a string value containing the numeric GUID value. For example:

C++
HLKM\Software\Classes\CLSID\<category>\Instance\<My DVD encoder>\Capabilities
     default "My DVD encoder"
     REG_SZ_MULTI {...}
where {...} is a property GUID that the application can map into its user interface.

Requirements

   
Minimum supported client Windows XP with SP2 [desktop apps | UWP apps]
Minimum supported server Windows Server 2003 R2 [desktop apps | UWP apps]
Target Platform Windows
Header strmif.h (include Dshow.h)

See Also

Decoder Settings for Windows Media Center Edition

Encoder API