Home > DirectShow SDK's > DirectShow filter / SDK registration

DirectShow filter / SDK registration

You can register any filter from SDK using IVFRegister interface. Some filters (RGB2YUV for example) do not require registration.

C++:

// {59E82754-B531-4A8E-A94D-57C75F01DA30}
DEFINE_GUID(IID_IVFRegister,
    0x59E82754, 0xB531, 0x4A8E, 0xA9, 0x4D, 0x57, 0xC7, 0x5F, 0x01, 0xDA, 0x30);


/// <summary>
/// Filter registration interface.
/// </summary>
DECLARE_INTERFACE_(IVFRegister, IUnknown)
{
    /// <summary>
    /// Sets registered.
    /// </summary>
    /// <param name="licenseKey">
    /// License Key.
    /// </param>
    STDMETHOD(SetLicenseKey)
        (THIS_
            WCHAR * licenseKey
            )PURE;
};

C#:   

    /// <summary>
    /// Public filter registration interface.
    /// </summary>
    [ComImport]
    [System.Security.SuppressUnmanagedCodeSecurity]
    [Guid("59E82754-B531-4A8E-A94D-57C75F01DA30")]
    [InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
    public interface IVFRegister
    {
        /// <summary>
        /// Sets registered.
        /// </summary>
        /// <param name="licenseKey">
        /// License Key.
        /// </param>
        [PreserveSig]
        void SetLicenseKey([In, MarshalAs(UnmanagedType.LPWStr)] string licenseKey);
    }

Delphi:

const
  IID_IVFRegister: TGUID = '{59E82754-B531-4A8E-A94D-57C75F01DA30}';

type
  /// <summary>
  /// Public filter registration interface.
  /// </summary>
  IVFRegister = interface(IUnknown)
    /// <summary>
    /// Sets registered.
    /// </summary>
    /// <param name="licenseKey">
    /// License Key.
    /// </param>
    procedure SetLicenseKey(licenseKey: PWideChar); stdcall;
  end;

Also we can provide alternative registration ways, for example using system registry, or using custom build.