' ########################################################################################
' Microsoft Windows
' File: wmcontainer.inc
' Copyright (c) 2011 Jos? Roca
' Portions Copyright (c) Microsoft Corporation.
' All Rights Reserved.
' THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER
' EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF
' MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR PURPOSE.
' ########################################################################################
#IF NOT %DEF(PBX_wmcontainer_PBI)
#DEFINE PBX_wmcontainer_PBI
%EQUATE `WMCONTAINER_INC = 1
'/* header files for imported files */
#INCLUDE ONCE "Legacy/System/mfidl.inc"
' ########################################################################################
' Interface name = IMFASFContentInfo
' IID = B1DCA5CD-D5DA-4451-8E9E-DB5C59914EAD
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IMFASFContentInfo_INTERFACE_DEFINED)
 %IMFASFContentInfo_INTERFACE_DEFINED = 1
$IID_IMFASFContentInfo = GUID$("{B1DCA5CD-D5DA-4451-8E9E-DB5C59914EAD}")
INTERFACE IMFASFContentInfo $IID_IMFASFContentInfo
 INHERIT IUnknown
 ' =====================================================================================
 METHOD GetHeaderSize ( ' VTable offset = 12
 BYVAL pIStartOfContent AS IMFMediaBuffer
 , BYREF cbHeaderSize AS QUAD
 ) AS LONG
 ' =====================================================================================
 METHOD ParseHeader ( ' VTable offset = 16
 BYVAL pIHeaderBuffer AS IMFMediaBuffer
 , BYVAL cbOffsetWithinHeader AS QUAD
 ) AS LONG
 ' =====================================================================================
 METHOD GenerateHeader ( ' VTable offset = 20
 BYREF pIHeader AS IMFMediaBuffer
 , BYREF pcbHeader AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetProfile ( ' VTable offset = 24
 BYREF ppIProfile AS IMFASFProfile
 ) AS LONG
 ' =====================================================================================
 METHOD SetProfile ( ' VTable offset = 28
 BYVAL pIProfile AS IMFASFProfile
 ) AS LONG
 ' =====================================================================================
 METHOD GeneratePresentationDescriptor ( ' VTable offset = 32
 BYREF ppIPresentationDescriptor AS IMFPresentationDescriptor
 ) AS LONG
 ' =====================================================================================
 METHOD GetEncodingConfigurationPropertyStore ( ' VTable offset = 36
 BYVAL wStreamNumber AS WORD
 , BYREF ppIStore AS IPropertyStore
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IMFASFContentInfo_INTERFACE_DEFINED__ */
DECLARE FUNCTION MFCreateASFContentInfo LIB "mf.dll" ALIAS "MFCreateASFContentInfo" ( BYREF ppIContentInfo AS IMFASFContentInfo ) AS LONG
'#define MFASF_MIN_HEADER_BYTES ( sizeof( GUID ) + sizeof( QWORD ) )
%EQUATE `MFASF_MIN_HEADER_BYTES = 24
$MF_PD_ASF_FILEPROPERTIES_FILE_ID = GUID$("{3DE649B4-D76D-4E66-9EC9-78120FB4C7E3}")
$MF_PD_ASF_FILEPROPERTIES_CREATION_TIME = GUID$("{3DE649B6-D76D-4E66-9EC9-78120FB4C7E3}")
$MF_PD_ASF_FILEPROPERTIES_PACKETS = GUID$("{3DE649B7-D76D-4E66-9EC9-78120FB4C7E3}")
$MF_PD_ASF_FILEPROPERTIES_PLAY_DURATION = GUID$("{3DE649B8-D76D-4E66-9EC9-78120FB4C7E3}")
$MF_PD_ASF_FILEPROPERTIES_SEND_DURATION = GUID$("{3DE649B9-D76D-4E66-9EC9-78120FB4C7E3}")
$MF_PD_ASF_FILEPROPERTIES_PREROLL = GUID$("{3DE649BA-D76D-4E66-9EC9-78120FB4C7E3}")
$MF_PD_ASF_FILEPROPERTIES_FLAGS = GUID$("{3DE649BB-D76D-4E66-9EC9-78120FB4C7E3}")
$MF_PD_ASF_FILEPROPERTIES_MIN_PACKET_SIZE = GUID$("{3DE649BC-D76D-4E66-9EC9-78120FB4C7E3}")
$MF_PD_ASF_FILEPROPERTIES_MAX_PACKET_SIZE = GUID$("{3DE649BD-D76D-4E66-9EC9-78120FB4C7E3}")
$MF_PD_ASF_FILEPROPERTIES_MAX_BITRATE = GUID$("{3DE649BE-D76D-4E66-9EC9-78120FB4C7E3}")
$MF_PD_ASF_CONTENTENCRYPTION_TYPE = GUID$("{8520FE3D-277E-46EA-99E4-E30A86DB12BE}")
$MF_PD_ASF_CONTENTENCRYPTION_KEYID = GUID$("{8520FE3E-277E-46EA-99E4-E30A86DB12BE}")
$MF_PD_ASF_CONTENTENCRYPTION_SECRET_DATA = GUID$("{8520FE3F-277E-46EA-99E4-E30A86DB12BE}")
$MF_PD_ASF_CONTENTENCRYPTION_LICENSE_URL = GUID$("{8520FE40-277E-46EA-99E4-E30A86DB12BE}")
$MF_PD_ASF_CONTENTENCRYPTIONEX_ENCRYPTION_DATA = GUID$("{62508BE5-ECDF-4924-A359-72BAB3397B9D}")
$MF_PD_ASF_LANGLIST = GUID$("{F23DE43C-9977-460D-A6EC-32937F160F7D}")
'#if (WINVER >= _WIN32_WINNT_WIN7)
$MF_PD_ASF_LANGLIST_LEGACYORDER = GUID$("{f23de43d-9977-460d-a6ec-32937f160f7d}")
'#endif // (WINVER >= _WIN32_WINNT_WIN7)
$MF_PD_ASF_MARKER = GUID$("{5134330E-83A6-475E-A9D5-4FB875FB2E31}")
$MF_PD_ASF_SCRIPT = GUID$("{E29CD0D7-D602-4923-A7FE-73FD97ECC650}")
$MF_PD_ASF_CODECLIST = GUID$("{E4BB3509-C18D-4DF1-BB99-7A36B3CC4119}")
$MF_PD_ASF_METADATA_IS_VBR = GUID$("{5FC6947A-EF60-445D-B449-442ECC78B4C1}")
$MF_PD_ASF_METADATA_V8_VBRPEAK = GUID$("{5FC6947B-EF60-445D-B449-442ECC78B4C1}")
$MF_PD_ASF_METADATA_V8_BUFFERAVERAGE = GUID$("{5FC6947C-EF60-445D-B449-442ECC78B4C1}")
$MF_PD_ASF_METADATA_LEAKY_BUCKET_PAIRS = GUID$("{5FC6947D-EF60-445D-B449-442ECC78B4C1}")
$MF_PD_ASF_DATA_START_OFFSET = GUID$("{E7D5B3E7-1F29-45D3-8822-3E78FAE272ED}")
$MF_PD_ASF_DATA_LENGTH = GUID$("{E7D5B3E8-1F29-45D3-8822-3E78FAE272ED}")
$MF_SD_ASF_EXTSTRMPROP_LANGUAGE_ID_INDEX = GUID$("{48F8A522-305D-422D-8524-2502DDA33680}")
$MF_SD_ASF_EXTSTRMPROP_AVG_DATA_BITRATE = GUID$("{48F8A523-305D-422D-8524-2502DDA33680}")
$MF_SD_ASF_EXTSTRMPROP_AVG_BUFFERSIZE = GUID$("{48F8A524-305D-422D-8524-2502DDA33680}")
$MF_SD_ASF_EXTSTRMPROP_MAX_DATA_BITRATE = GUID$("{48F8A525-305D-422D-8524-2502DDA33680}")
$MF_SD_ASF_EXTSTRMPROP_MAX_BUFFERSIZE = GUID$("{48F8A526-305D-422D-8524-2502DDA33680}")
$MF_SD_ASF_STREAMBITRATES_BITRATE = GUID$("{A8E182ED-AFC8-43D0-B0D1-F65BAD9DA558}")
$MF_SD_ASF_METADATA_DEVICE_CONFORMANCE_TEMPLATE = GUID$("{245E929D-C44E-4F7E-BB3C-77D4DFD27F8A}")
$MF_PD_ASF_INFO_HAS_AUDIO = GUID$("{80E62295-2296-4A44-B31C-D103C6FED23C}")
$MF_PD_ASF_INFO_HAS_VIDEO = GUID$("{80E62296-2296-4A44-B31C-D103C6FED23C}")
$MF_PD_ASF_INFO_HAS_NON_AUDIO_VIDEO = GUID$("{80E62297-2296-4A44-B31C-D103C6FED23C}")
' ########################################################################################
' Interface name = IMFASFProfile
' IID = D267BF6A-028B-4E0D-903D-43F0EF82D0D4
' Inherited interface = IMFAttributes
' ########################################################################################
#IF NOT %DEF(%IMFASFProfile_INTERFACE_DEFINED)
 %IMFASFProfile_INTERFACE_DEFINED = 1
$IID_IMFASFProfile = GUID$("{D267BF6A-028B-4E0D-903D-43F0EF82D0D4}")
INTERFACE IMFASFProfile $IID_IMFASFProfile
 INHERIT IUnknown
 ' =====================================================================================
 ' IMFAttributes methods
 ' =====================================================================================
 METHOD GetItem ( ' VTable offset = 12
 BYREF guidKey AS GUID
 , BYREF pValue AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD GetItemType ( ' VTable offset = 16
 BYREF guidKey AS GUID
 , BYREF pType AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD CompareItem ( ' VTable offset = 20
 BYREF guidKey AS GUID
 , BYREF Value AS PROPVARIANT
 , BYREF pbResult AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD Compare ( ' VTable offset = 24
 BYVAL pTheirs AS IMFAttributes
 , BYVAL MatchType AS LONG
 , BYREF pbResult AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetUINT32 ( ' VTable offset = 28
 BYREF guidKey AS GUID
 , BYREF punValue AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetUINT64 ( ' VTable offset = 32
 BYREF guidKey AS GUID
 , BYREF punValue AS QUAD
 ) AS LONG
 ' =====================================================================================
 METHOD GetDouble ( ' VTable offset = 36
 BYREF guidKey AS GUID
 , BYREF pfValue AS DOUBLE
 ) AS LONG
 ' =====================================================================================
 METHOD GetGUID ( ' VTable offset = 40
 BYREF guidKey AS GUID
 , BYREF pguidValue AS GUID
 ) AS LONG
 ' =====================================================================================
 METHOD GetStringLength ( ' VTable offset = 44
 BYREF guidKey AS GUID
 , BYREF pcchLength AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetString ( ' VTable offset = 48
 BYREF guidKey AS GUID
 , BYREF pwszValue AS WSTRINGZ
 , BYVAL cchBufSize AS DWORD
 , BYREF pcchLength AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetAllocatedString ( ' VTable offset = 52
 BYREF guidKey AS GUID
 , BYREF ppwszValue AS DWORD
 , BYREF pcchLength AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetBlobSize ( ' VTable offset = 56
 BYREF guidKey AS GUID
 , BYREF pcbBlobSize AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetBlob ( ' VTable offset = 60
 BYREF guidKey AS GUID
 , BYVAL pBuf AS DWORD
 , BYVAL cbBufSize AS DWORD
 , BYREF pcbBlobSize AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetAllocatedBlob ( ' VTable offset = 64
 BYREF guidKey AS GUID
 , BYVAL ppBuf AS DWORD
 , BYREF pcbSize AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetUnknown ( ' VTable offset = 68
 BYREF guidKey AS GUID
 , BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD SetItem ( ' VTable offset = 72
 BYREF guidKey AS GUID
 , BYREF Value AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD DeleteItem ( ' VTable offset = 76
 BYREF guidKey AS GUID
 ) AS LONG
 ' =====================================================================================
 METHOD DeleteAllItems ( ' VTable offset = 80
 ) AS LONG
 ' =====================================================================================
 METHOD SetUINT32 ( ' VTable offset = 84
 BYREF guidKey AS GUID
 , BYVAL unValue AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD SetUINT64 ( ' VTable offset = 88
 BYREF guidKey AS GUID
 , BYVAL unValue AS QUAD
 ) AS LONG
 ' =====================================================================================
 METHOD SetDouble ( ' VTable offset = 92
 BYREF guidKey AS GUID
 , BYVAL fValue AS DOUBLE
 ) AS LONG
 ' =====================================================================================
 METHOD SetGUID ( ' VTable offset = 96
 BYREF guidKey AS GUID
 , BYREF guidValue AS GUID
 ) AS LONG
 ' =====================================================================================
 METHOD SetString ( ' VTable offset = 100
 BYREF guidKey AS GUID
 , BYREF wszValue AS WSTRINGZ
 ) AS LONG
 ' =====================================================================================
 METHOD SetBlob ( ' VTable offset = 104
 BYREF guidKey AS GUID
 , BYVAL pBuf AS DWORD
 , BYVAL cbBufSize AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD SetUnknown ( ' VTable offset = 108
 BYREF guidKey AS GUID
 , BYVAL pUnknown AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD LockStore ( ' VTable offset = 112
 ) AS LONG
 ' =====================================================================================
 METHOD UnlockStore ( ' VTable offset = 116
 ) AS LONG
 ' =====================================================================================
 METHOD GetCount ( ' VTable offset = 120
 BYREF pcItems AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetItemByIndex ( ' VTable offset = 124
 BYVAL unIndex AS DWORD
 , BYREF pguidKey AS GUID
 , BYREF pValue AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD CopyAllItems ( ' VTable offset = 128
 BYVAL pDest AS LONG
 ) AS LONG
 ' =====================================================================================
 ' =====================================================================================
 ' IMFASFProfile methods
 ' =====================================================================================
 METHOD GetStreamCount ( ' VTable offset = 132
 BYREF pcStreams AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetStream ( ' VTable offset = 136
 BYVAL dwStreamIndex AS DWORD
 , BYREF pwStreamNumber AS WORD
 , BYREF ppIStream AS IMFASFStreamConfig
 ) AS LONG
 ' =====================================================================================
 METHOD GetStreamByNumber ( ' VTable offset = 140
 BYVAL wStreamNumber AS WORD
 , BYREF ppIStream AS IMFASFStreamConfig
 ) AS LONG
 ' =====================================================================================
 METHOD SetStream ( ' VTable offset = 144
 BYVAL pIStream AS IMFASFStreamConfig
 ) AS LONG
 ' =====================================================================================
 METHOD RemoveStream ( ' VTable offset = 148
 BYVAL wStreamNumber AS WORD
 ) AS LONG
 ' =====================================================================================
 METHOD CreateStream ( ' VTable offset = 152
 BYVAL pIMediaType AS IMFMediaType
 , BYREF ppIStream AS IMFASFStreamConfig
 ) AS LONG
 ' =====================================================================================
 METHOD GetMutualExclusionCount ( ' VTable offset = 156
 BYREF pcMutexs AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetMutualExclusion ( ' VTable offset = 160
 BYVAL dwMutexIndex AS DWORD
 , BYREF ppIMutex AS IMFASFMutualExclusion
 ) AS LONG
 ' =====================================================================================
 METHOD AddMutualExclusion ( ' VTable offset = 164
 BYVAL pIMutex AS IMFASFMutualExclusion
 ) AS LONG
 ' =====================================================================================
 METHOD RemoveMutualExclusion ( ' VTable offset = 168
 BYVAL dwMutexIndex AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD CreateMutualExclusion ( ' VTable offset = 172
 BYREF ppIMutex AS IMFASFMutualExclusion
 ) AS LONG
 ' =====================================================================================
 METHOD GetStreamPrioritization ( ' VTable offset = 176
 BYREF ppIStreamPrioritization AS IMFASFStreamPrioritization
 ) AS LONG
 ' =====================================================================================
 METHOD AddStreamPrioritization ( ' VTable offset = 180
 BYVAL pIStreamPrioritization AS IMFASFStreamPrioritization
 ) AS LONG
 ' =====================================================================================
 METHOD RemoveStreamPrioritization ( ' VTable offset = 184
 ) AS LONG
 ' =====================================================================================
 METHOD CreateStreamPrioritization ( ' VTable offset = 188
 BYREF ppIStreamPrioritization AS IMFASFStreamPrioritization
 ) AS LONG
 ' =====================================================================================
 METHOD Clone ( ' VTable offset = 192
 BYREF ppIProfile AS IMFASFProfile
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IMFASFProfile_INTERFACE_DEFINED__ */
$MF_ASFPROFILE_MINPACKETSIZE = GUID$("{22587626-47DE-4168-87F5-B5AA9B12A8F0}")
$MF_ASFPROFILE_MAXPACKETSIZE = GUID$("{22587627-47DE-4168-87F5-B5AA9B12A8F0}")
DECLARE FUNCTION MFCreateASFProfile LIB "mf.dll" ALIAS "MFCreateASFProfile" ( BYREF ppIProfile AS IMFASFProfile ) AS LONG
DECLARE FUNCTION MFCreateASFProfileFromPresentationDescriptor LIB "mf.dll" ALIAS "MFCreateASFProfileFromPresentationDescriptor" ( BYVAL pIPD AS IMFPresentationDescriptor
 , BYREF ppIProfile AS IMFASFProfile
 ) AS LONG
DECLARE FUNCTION MFCreatePresentationDescriptorFromASFProfile LIB "mf.dll" ALIAS "MFCreatePresentationDescriptorFromASFProfile" ( BYVAL pIProfile AS IMFASFProfile
 , BYREF ppIPD AS IMFPresentationDescriptor
 ) AS LONG
' ########################################################################################
' Interface name = IMFASFStreamConfig
' IID = 9E8AE8D2-DBBD-4200-9ACA-06E6DF484913
' Inherited interface = IMFAttributes
' ########################################################################################
#IF NOT %DEF(%IMFASFStreamConfig_INTERFACE_DEFINED)
 %IMFASFStreamConfig_INTERFACE_DEFINED = 1
$IID_IMFASFStreamConfig = GUID$("{9E8AE8D2-DBBD-4200-9ACA-06E6DF484913}")
INTERFACE IMFASFStreamConfig $IID_IMFASFStreamConfig
 INHERIT IUnknown
 ' =====================================================================================
 ' IMFAttributes methods
 ' =====================================================================================
 METHOD GetItem ( ' VTable offset = 12
 BYREF guidKey AS GUID
 , BYREF pValue AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD GetItemType ( ' VTable offset = 16
 BYREF guidKey AS GUID
 , BYREF pType AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD CompareItem ( ' VTable offset = 20
 BYREF guidKey AS GUID
 , BYREF Value AS PROPVARIANT
 , BYREF pbResult AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD Compare ( ' VTable offset = 24
 BYVAL pTheirs AS IMFAttributes
 , BYVAL MatchType AS LONG
 , BYREF pbResult AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetUINT32 ( ' VTable offset = 28
 BYREF guidKey AS GUID
 , BYREF punValue AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetUINT64 ( ' VTable offset = 32
 BYREF guidKey AS GUID
 , BYREF punValue AS QUAD
 ) AS LONG
 ' =====================================================================================
 METHOD GetDouble ( ' VTable offset = 36
 BYREF guidKey AS GUID
 , BYREF pfValue AS DOUBLE
 ) AS LONG
 ' =====================================================================================
 METHOD GetGUID ( ' VTable offset = 40
 BYREF guidKey AS GUID
 , BYREF pguidValue AS GUID
 ) AS LONG
 ' =====================================================================================
 METHOD GetStringLength ( ' VTable offset = 44
 BYREF guidKey AS GUID
 , BYREF pcchLength AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetString ( ' VTable offset = 48
 BYREF guidKey AS GUID
 , BYREF pwszValue AS WSTRINGZ
 , BYVAL cchBufSize AS DWORD
 , BYREF pcchLength AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetAllocatedString ( ' VTable offset = 52
 BYREF guidKey AS GUID
 , BYREF ppwszValue AS DWORD
 , BYREF pcchLength AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetBlobSize ( ' VTable offset = 56
 BYREF guidKey AS GUID
 , BYREF pcbBlobSize AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetBlob ( ' VTable offset = 60
 BYREF guidKey AS GUID
 , BYVAL pBuf AS DWORD
 , BYVAL cbBufSize AS DWORD
 , BYREF pcbBlobSize AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetAllocatedBlob ( ' VTable offset = 64
 BYREF guidKey AS GUID
 , BYVAL ppBuf AS DWORD
 , BYREF pcbSize AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetUnknown ( ' VTable offset = 68
 BYREF guidKey AS GUID
 , BYREF riid AS GUID
 , BYREF ppv AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD SetItem ( ' VTable offset = 72
 BYREF guidKey AS GUID
 , BYREF Value AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD DeleteItem ( ' VTable offset = 76
 BYREF guidKey AS GUID
 ) AS LONG
 ' =====================================================================================
 METHOD DeleteAllItems ( ' VTable offset = 80
 ) AS LONG
 ' =====================================================================================
 METHOD SetUINT32 ( ' VTable offset = 84
 BYREF guidKey AS GUID
 , BYVAL unValue AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD SetUINT64 ( ' VTable offset = 88
 BYREF guidKey AS GUID
 , BYVAL unValue AS QUAD
 ) AS LONG
 ' =====================================================================================
 METHOD SetDouble ( ' VTable offset = 92
 BYREF guidKey AS GUID
 , BYVAL fValue AS DOUBLE
 ) AS LONG
 ' =====================================================================================
 METHOD SetGUID ( ' VTable offset = 96
 BYREF guidKey AS GUID
 , BYREF guidValue AS GUID
 ) AS LONG
 ' =====================================================================================
 METHOD SetString ( ' VTable offset = 100
 BYREF guidKey AS GUID
 , BYREF wszValue AS WSTRINGZ
 ) AS LONG
 ' =====================================================================================
 METHOD SetBlob ( ' VTable offset = 104
 BYREF guidKey AS GUID
 , BYVAL pBuf AS DWORD
 , BYVAL cbBufSize AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD SetUnknown ( ' VTable offset = 108
 BYREF guidKey AS GUID
 , BYVAL pUnknown AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD LockStore ( ' VTable offset = 112
 ) AS LONG
 ' =====================================================================================
 METHOD UnlockStore ( ' VTable offset = 116
 ) AS LONG
 ' =====================================================================================
 METHOD GetCount ( ' VTable offset = 120
 BYREF pcItems AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetItemByIndex ( ' VTable offset = 124
 BYVAL unIndex AS DWORD
 , BYREF pguidKey AS GUID
 , BYREF pValue AS PROPVARIANT
 ) AS LONG
 ' =====================================================================================
 METHOD CopyAllItems ( ' VTable offset = 128
 BYVAL pDest AS LONG
 ) AS LONG
 ' =====================================================================================
 ' =====================================================================================
 ' IMFASFStreamConfig methods
 ' =====================================================================================
 METHOD GetStreamType ( ' VTable offset = 132
 BYREF pguidStreamType AS GUID
 ) AS LONG
 ' =====================================================================================
 METHOD GetStreamNumber ( ' VTable offset = 136
 ) AS WORD ' WORD
 ' =====================================================================================
 METHOD SetStreamNumber ( ' VTable offset = 140
 BYVAL wStreamNum AS WORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetMediaType ( ' VTable offset = 144
 BYREF ppIMediaType AS IMFMediaType
 ) AS LONG
 ' =====================================================================================
 METHOD SetMediaType ( ' VTable offset = 148
 BYVAL pIMediaType AS IMFMediaType
 ) AS LONG
 ' =====================================================================================
 METHOD GetPayloadExtensionCount ( ' VTable offset = 152
 BYREF pcPayloadExtensions AS WORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetPayloadExtension ( ' VTable offset = 156
 BYVAL wPayloadExtensionNumber AS WORD
 , BYREF pguidExtensionSystemID AS GUID
 , BYREF pcbExtensionDataSize AS WORD
 , BYVAL pbExtensionSystemInfo AS BYTE PTR
 , BYREF pcbExtensionSystemInfo AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD AddPayloadExtension ( ' VTable offset = 160
 BYREF guidExtensionSystemID AS GUID
 , BYVAL cbExtensionDataSize AS WORD
 , BYVAL pbExtensionSystemInfo AS BYTE PTR
 , BYVAL cbExtensionSystemInfo AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD RemoveAllPayloadExtensions ( ' VTable offset = 164
 ) AS LONG
 ' =====================================================================================
 METHOD Clone ( ' VTable offset = 168
 BYREF ppIStreamConfig AS IMFASFStreamConfig
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IMFASFStreamConfig_INTERFACE_DEFINED__ */
$MF_ASFSTREAMCONFIG_LEAKYBUCKET1 = GUID$("{C69B5901-EA1A-4C9B-B692-E2A0D29A8ADD}")
$MF_ASFSTREAMCONFIG_LEAKYBUCKET2 = GUID$("{C69B5902-EA1A-4C9B-B692-E2A0D29A8ADD}")
$MFASFSampleExtension_SampleDuration = GUID$("{C6BD9450-867F-4907-83A3-C77921B733AD}")
$MFASFSampleExtension_OutputCleanPoint = GUID$("{F72A3C6F-6EB4-4EBC-B192-09AD9759E828}")
$MFASFSampleExtension_SMPTE = GUID$("{399595EC-8667-4E2D-8FDB-98814CE76C1E}")
$MFASFSampleExtension_FileName = GUID$("{E165EC0E-19ED-45D7-B4A7-25CBD1E28E9B}")
$MFASFSampleExtension_ContentType = GUID$("{D590DC20-07BC-436C-9CF7-F3BBFBF1A4DC}")
$MFASFSampleExtension_PixelAspectRatio = GUID$("{1B1EE554-F9EA-4BC8-821A-376B74E4C4B8}")
$MFASFSampleExtension_Encryption_SampleID = GUID$("{6698B84E-0AFA-4330-AEB2-1C0A98D7A44D}")
$MFASFSampleExtension_Encryption_KeyID = GUID$("{76376591-795F-4DA1-86ED-9D46ECA109A9}")
' ########################################################################################
' Interface name = IMFASFMutualExclusion
' IID = 12558291-E399-11D5-BC2A-00B0D0F3F4AB
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IMFASFMutualExclusion_INTERFACE_DEFINED)
 %IMFASFMutualExclusion_INTERFACE_DEFINED = 1
$IID_IMFASFMutualExclusion = GUID$("{12558291-E399-11D5-BC2A-00B0D0F3F4AB}")
INTERFACE IMFASFMutualExclusion $IID_IMFASFMutualExclusion
 INHERIT IUnknown
 ' =====================================================================================
 METHOD GetType ( ' VTable offset = 12
 BYREF pguidType AS GUID
 ) AS LONG
 ' =====================================================================================
 METHOD GetRecordCount ( ' VTable offset = 16
 BYREF pdwRecordCount AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetStreamsForRecord ( ' VTable offset = 20
 BYVAL dwRecordNumber AS DWORD
 , BYREF pwStreamNumArray AS WORD
 , BYREF pcStreams AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD AddStreamForRecord ( ' VTable offset = 24
 BYVAL dwRecordNumber AS DWORD
 , BYVAL wStreamNumber AS WORD
 ) AS LONG
 ' =====================================================================================
 METHOD RemoveStreamFromRecord ( ' VTable offset = 28
 BYVAL dwRecordNumber AS DWORD
 , BYVAL wStreamNumber AS WORD
 ) AS LONG
 ' =====================================================================================
 METHOD RemoveRecord ( ' VTable offset = 32
 BYVAL dwRecordNumber AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD AddRecord ( ' VTable offset = 36
 BYREF pdwRecordNumber AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD Clone ( ' VTable offset = 40
 BYREF ppIMutex AS IMFASFMutualExclusion
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IMFASFMutualExclusion_INTERFACE_DEFINED__ */
$MFASFMutexType_Language = GUID$("{72178C2B-E45B-11D5-BC2A-00B0D0F3F4AB}")
$MFASFMutexType_Bitrate = GUID$("{72178C2C-E45B-11D5-BC2A-00B0D0F3F4AB}")
$MFASFMutexType_Presentation = GUID$("{72178C2D-E45B-11D5-BC2A-00B0D0F3F4AB}")
$MFASFMutexType_Unknown = GUID$("{72178C2E-E45B-11D5-BC2A-00B0D0F3F4AB}")
' ########################################################################################
' Interface name = IMFASFStreamPrioritization
' IID = 699BDC27-BBAF-49FF-8E38-9C39C9B5E088
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IMFASFStreamPrioritization_INTERFACE_DEFINED)
 %IMFASFStreamPrioritization_INTERFACE_DEFINED = 1
$IID_IMFASFStreamPrioritization = GUID$("{699BDC27-BBAF-49FF-8E38-9C39C9B5E088}")
INTERFACE IMFASFStreamPrioritization $IID_IMFASFStreamPrioritization
 INHERIT IUnknown
 ' =====================================================================================
 METHOD GetStreamCount ( ' VTable offset = 12
 BYREF pdwStreamCount AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetStream ( ' VTable offset = 16
 BYVAL dwStreamIndex AS DWORD
 , BYREF pwStreamNumber AS WORD
 , BYREF pwStreamFlags AS WORD
 ) AS LONG
 ' =====================================================================================
 METHOD AddStream ( ' VTable offset = 20
 BYVAL wStreamNumber AS WORD
 , BYVAL wStreamFlags AS WORD
 ) AS LONG
 ' =====================================================================================
 METHOD RemoveStream ( ' VTable offset = 24
 BYVAL dwStreamIndex AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD Clone ( ' VTable offset = 28
 BYREF ppIStreamPrioritization AS IMFASFStreamPrioritization
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IMFASFStreamPrioritization_INTERFACE_DEFINED__ */
' enum MFASF_SPLITTERFLAGS
%EQUATE `MFASF_SPLITTER_REVERSE = &H1
%EQUATE `MFASF_SPLITTER_WMDRM = &H2
' ########################################################################################
' Interface name = IMFASFSplitter
' IID = 12558295-E399-11D5-BC2A-00B0D0F3F4AB
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IMFASFSplitter_INTERFACE_DEFINED)
 %IMFASFSplitter_INTERFACE_DEFINED = 1
$IID_IMFASFSplitter = GUID$("{12558295-E399-11D5-BC2A-00B0D0F3F4AB}")
INTERFACE IMFASFSplitter $IID_IMFASFSplitter
 INHERIT IUnknown
 ' =====================================================================================
 METHOD Initialize ( ' VTable offset = 12
 BYVAL pIContentInfo AS IMFASFContentInfo
 ) AS LONG
 ' =====================================================================================
 METHOD SetFlags ( ' VTable offset = 16
 BYVAL dwFlags AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetFlags ( ' VTable offset = 20
 BYREF pdwFlags AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD SelectStreams ( ' VTable offset = 24
 BYVAL pwStreamNumbers AS WORD
 , BYVAL wNumStreams AS WORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetSelectedStreams ( ' VTable offset = 28
 BYREF pwStreamNumbers AS WORD
 , BYREF pwNumStreams AS WORD
 ) AS LONG
 ' =====================================================================================
 METHOD ParseData ( ' VTable offset = 32
 BYVAL pIBuffer AS IMFMediaBuffer
 , BYVAL cbBufferOffset AS DWORD
 , BYVAL cbLength AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetNextSample ( ' VTable offset = 36
 BYREF pdwStatusFlags AS DWORD
 , BYREF pwStreamNumber AS WORD
 , BYREF ppISample AS IMFSample
 ) AS LONG
 ' =====================================================================================
 METHOD Flush ( ' VTable offset = 40
 ) AS LONG
 ' =====================================================================================
 METHOD GetLastSendTime ( ' VTable offset = 44
 BYREF pdwLastSendTime AS DWORD
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IMFASFSplitter_INTERFACE_DEFINED__ */
' enum ASF_STATUSFLAGS
%EQUATE `ASF_STATUSFLAGS_INCOMPLETE = &H1
%EQUATE `ASF_STATUSFLAGS_NONFATAL_ERROR = &H2
$MFASFSPLITTER_PACKET_BOUNDARY = GUID$("{FE584A05-E8D6-42E3-B176-F1211705FB6F}")
DECLARE FUNCTION MFCreateASFSplitter LIB "mf.dll" ALIAS "MFCreateASFSplitter" ( BYREF ppISplitter AS IMFASFSplitter ) AS LONG
' enum MFASF_MULTIPLEXERFLAGS
%EQUATE `MFASF_MULTIPLEXER_AUTOADJUST_BITRATE = &H1
' // Size = 8 bytes
TYPE ASF_MUX_STATISTICS DWORD
 cFramesWritten AS DWORD
 cFramesDropped AS DWORD
END TYPE
' ########################################################################################
' Interface name = IMFASFMultiplexer
' IID = 57BDD80A-9B38-4838-B737-C58F670D7D4F
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IMFASFMultiplexer_INTERFACE_DEFINED)
 %IMFASFMultiplexer_INTERFACE_DEFINED = 1
$IID_IMFASFMultiplexer = GUID$("{57BDD80A-9B38-4838-B737-C58F670D7D4F}")
INTERFACE IMFASFMultiplexer $IID_IMFASFMultiplexer
 INHERIT IUnknown
 ' =====================================================================================
 METHOD Initialize ( ' VTable offset = 12
 BYVAL pIContentInfo AS IMFASFContentInfo
 ) AS LONG
 ' =====================================================================================
 METHOD SetFlags ( ' VTable offset = 16
 BYVAL dwFlags AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetFlags ( ' VTable offset = 20
 BYREF pdwFlags AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD ProcessSample ( ' VTable offset = 24
 BYVAL wStreamNumber AS WORD
 , BYVAL pISample AS IMFSample
 , BYVAL hnsTimestampAdjust AS QUAD
 ) AS LONG
 ' =====================================================================================
 METHOD GetNextPacket ( ' VTable offset = 28
 BYVAL pdwStatusFlags AS DWORD
 , BYREF ppIPacket AS IMFSample
 ) AS LONG
 ' =====================================================================================
 METHOD Flush ( ' VTable offset = 32
 ) AS LONG
 ' =====================================================================================
 METHOD End ( ' VTable offset = 36
 BYREF pIContentInfo AS IMFASFContentInfo
 ) AS LONG
 ' =====================================================================================
 METHOD GetStatistics ( ' VTable offset = 40
 BYVAL wStreamNumber AS WORD
 , BYREF pMuxStats AS ASF_MUX_STATISTICS
 ) AS LONG
 ' =====================================================================================
 METHOD SetSyncTolerance ( ' VTable offset = 44
 BYVAL msSyncTolerance AS DWORD
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IMFASFMultiplexer_INTERFACE_DEFINED__ */
DECLARE FUNCTION MFCreateASFMultiplexer LIB "mf.dll" ALIAS "MFCreateASFMultiplexer" ( BYREF ppIMultiplexer AS IMFASFMultiplexer ) AS LONG
' enum MFASF_INDEXERFLAGS
%EQUATE `MFASF_INDEXER_WRITE_NEW_INDEX = &H1
%EQUATE `MFASF_INDEXER_READ_FOR_REVERSEPLAYBACK = &H2
%EQUATE `MFASF_INDEXER_WRITE_FOR_LIVEREAD = &H4
' // Size = 20 bytes
TYPE ASF_INDEX_IDENTIFIER DWORD
 guidIndexType AS GUID ' GUID
 wStreamNumber AS WORD ' WORD
END TYPE
' // Size = 92 bytes
TYPE ASF_INDEX_DESCRIPTOR DWORD
 Identifier AS ASF_INDEX_IDENTIFIER ' ASF_INDEX_IDENTIFIER
 cPerEntryBytes AS WORD ' WORD
 szDescription AS WSTRINGZ * 32 ' WCHAR
 dwInterval AS DWORD
END TYPE
' ########################################################################################
' Interface name = IMFASFIndexer
' IID = 53590F48-DC3B-4297-813F-787761AD7B3E
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IMFASFIndexer_INTERFACE_DEFINED)
 %IMFASFIndexer_INTERFACE_DEFINED = 1
$IID_IMFASFIndexer = GUID$("{53590F48-DC3B-4297-813F-787761AD7B3E}")
INTERFACE IMFASFIndexer $IID_IMFASFIndexer
 INHERIT IUnknown
 ' =====================================================================================
 METHOD SetFlags ( ' VTable offset = 12
 BYVAL dwFlags AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetFlags ( ' VTable offset = 16
 BYREF pdwFlags AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD Initialize ( ' VTable offset = 20
 BYVAL pIContentInfo AS IMFASFContentInfo
 ) AS LONG
 ' =====================================================================================
 METHOD GetIndexPosition ( ' VTable offset = 24
 BYVAL pIContentInfo AS IMFASFContentInfo
 , BYREF pcbIndexOffset AS QUAD
 ) AS LONG
 ' =====================================================================================
 METHOD SetIndexByteStreams ( ' VTable offset = 28
 BYVAL ppIByteStreams AS IMFByteStream
 , BYVAL cByteStreams AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetIndexByteStreamCount ( ' VTable offset = 32
 BYREF pcByteStreams AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetIndexStatus ( ' VTable offset = 36
 BYREF pIndexIdentifier AS ASF_INDEX_IDENTIFIER
 , BYREF pfIsIndexed AS LONG
 , BYVAL pbIndexDescriptor AS BYTE PTR
 , BYREF pcbIndexDescriptor AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD SetIndexStatus ( ' VTable offset = 40
 BYVAL pbIndexDescriptor AS BYTE PTR
 , BYVAL cbIndexDescriptor AS DWORD
 , BYVAL fGenerateIndex AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetSeekPositionForValue ( ' VTable offset = 44
 BYREF pvarValue AS PROPVARIANT
 , BYREF pIndexIdentifier AS ASF_INDEX_IDENTIFIER
 , BYREF pcbOffsetWithinData AS QUAD
 , BYREF phnsApproxTime AS QUAD
 , BYREF pdwPayloadNumberOfStreamWithinPacket AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GenerateIndexEntries ( ' VTable offset = 48
 BYVAL pIASFPacketSample AS IMFSample
 ) AS LONG
 ' =====================================================================================
 METHOD CommitIndex ( ' VTable offset = 52
 BYVAL pIContentInfo AS IMFASFContentInfo
 ) AS LONG
 ' =====================================================================================
 METHOD GetIndexWriteSpace ( ' VTable offset = 56
 BYREF pcbIndexWriteSpace AS QUAD
 ) AS LONG
 ' =====================================================================================
 METHOD GetCompletedIndex ( ' VTable offset = 60
 BYVAL pIIndexBuffer AS IMFMediaBuffer
 , BYVAL cbOffsetWithinIndex AS QUAD
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IMFASFIndexer_INTERFACE_DEFINED__ */
'#if (WINVER >= _WIN32_WINNT_WIN7)
$MFASFINDEXER_TYPE_TIMECODE = GUID$("{49815231-6bad-44fd-810a-3f60984ec7fd}")
'#endif // (WINVER >= _WIN32_WINNT_WIN7)
%EQUATE `MFASFINDEXER_PER_ENTRY_BYTES_DYNAMIC = &Hffff
%EQUATE `MFASFINDEXER_NO_FIXED_INTERVAL = &Hffffffff
%EQUATE `MFASFINDEXER_READ_FOR_REVERSEPLAYBACK_OUTOFDATASEGMENT = &Hffffffffffffffff&&
%EQUATE `MFASFINDEXER_APPROX_SEEK_TIME_UNKNOWN = &Hffffffffffffffff&&
DECLARE FUNCTION MFCreateASFIndexer LIB "mf.dll" ALIAS "MFCreateASFIndexer" ( BYREF ppIIndexer AS IMFASFIndexer ) AS LONG
DECLARE FUNCTION MFCreateASFIndexerByteStream LIB "mf.dll" ALIAS "MFCreateASFIndexerByteStream" ( BYVAL pIContentByteStream AS IMFByteStream
 , BYVAL cbIndexStartOffset AS QUAD
 , BYREF pIIndexByteStream AS IMFByteStream
 ) AS LONG
' enum MFASF_STREAMSELECTORFLAGS
%EQUATE `MFASF_STREAMSELECTOR_DISABLE_THINNING = &H1
%EQUATE `MFASF_STREAMSELECTOR_USE_AVERAGE_BITRATE = &H2
' enum ASF_SELECTION_STATUS
%EQUATE `ASF_STATUS_NOTSELECTED = 0
%EQUATE `ASF_STATUS_CLEANPOINTSONLY = 1
%EQUATE `ASF_STATUS_ALLDATAUNITS = 2
' ########################################################################################
' Interface name = IMFASFStreamSelector
' IID = D01BAD4A-4FA0-4A60-9349-C27E62DA9D41
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IMFASFStreamSelector_INTERFACE_DEFINED)
 %IMFASFStreamSelector_INTERFACE_DEFINED = 1
$IID_IMFASFStreamSelector = GUID$("{D01BAD4A-4FA0-4A60-9349-C27E62DA9D41}")
INTERFACE IMFASFStreamSelector $IID_IMFASFStreamSelector
 INHERIT IUnknown
 ' =====================================================================================
 METHOD GetStreamCount ( ' VTable offset = 12
 BYREF pcStreams AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetOutputCount ( ' VTable offset = 16
 BYREF pcOutputs AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetOutputStreamCount ( ' VTable offset = 20
 BYVAL dwOutputNum AS DWORD
 , BYREF pcStreams AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetOutputStreamNumbers ( ' VTable offset = 24
 BYVAL dwOutputNum AS DWORD
 , BYREF rgwStreamNumbers AS WORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetOutputFromStream ( ' VTable offset = 28
 BYVAL wStreamNum AS WORD
 , BYREF pdwOutput AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetOutputOverride ( ' VTable offset = 32
 BYVAL dwOutputNum AS DWORD
 , BYREF pSelection AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD SetOutputOverride ( ' VTable offset = 36
 BYVAL dwOutputNum AS DWORD
 , BYVAL Selection AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetOutputMutexCount ( ' VTable offset = 40
 BYVAL dwOutputNum AS DWORD
 , BYREF pcMutexes AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetOutputMutex ( ' VTable offset = 44
 BYVAL dwOutputNum AS DWORD
 , BYVAL dwMutexNum AS DWORD
 , BYREF ppMutex AS IUnknown
 ) AS LONG
 ' =====================================================================================
 METHOD SetOutputMutexSelection ( ' VTable offset = 48
 BYVAL dwOutputNum AS DWORD
 , BYVAL dwMutexNum AS DWORD
 , BYVAL wSelectedRecord AS WORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetBandwidthStepCount ( ' VTable offset = 52
 BYREF pcStepCount AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD GetBandwidthStep ( ' VTable offset = 56
 BYVAL dwStepNum AS DWORD
 , BYREF pdwBitrate AS DWORD
 , BYREF rgwStreamNumbers AS WORD
 , BYREF rgSelections AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD BitrateToStepNumber ( ' VTable offset = 57
 BYVAL dwBitrate AS DWORD
 , BYREF pdwStepNum AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD SetStreamSelectorFlags ( ' VTable offset = 58
 BYVAL dwStreamSelectorFlags AS DWORD
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IMFASFStreamSelector_INTERFACE_DEFINED__ */
DECLARE FUNCTION MFCreateASFStreamSelector LIB "mf.dll" ALIAS "MFCreateASFStreamSelector" ( BYVAL pIASFProfile AS IMFASFProfile , BYREF ppSelector AS IMFASFStreamSelector ) AS LONG
DECLARE FUNCTION MFCreateASFMediaSink LIB "mf.dll" ALIAS "MFCreateASFMediaSink" ( BYVAL pIByteStream AS IMFByteStream
 , BYREF ppIMediaSink AS IMFMediaSink
 ) AS LONG
DECLARE FUNCTION MFCreateASFMediaSinkActivate LIB "mf.dll" ALIAS "MFCreateASFMediaSinkActivate" ( BYREF pwszFileName AS WSTRINGZ
 , BYVAL pContentInfo AS IMFASFContentInfo
 , BYREF ppIActivate AS IMFActivate
 ) AS LONG
DECLARE FUNCTION MFCreateWMVEncoderActivate LIB "mf.dll" ALIAS "MFCreateWMVEncoderActivate" ( BYVAL pMediaType AS IMFMediaType
 , BYVAL pEncodingConfigurationProperties AS IPropertyStore
 , BYREF ppActivate AS IMFActivate
 ) AS LONG
DECLARE FUNCTION MFCreateASFStreamingMediaSink LIB "mf.dll" ALIAS "MFCreateASFStreamingMediaSink" ( BYVAL pIByteStream AS IMFByteStream
 , BYREF ppIMediaSink AS IMFMediaSink
 ) AS LONG
DECLARE FUNCTION MFCreateASFStreamingMediaSinkActivate LIB "mf.dll" ALIAS "MFCreateASFStreamingMediaSinkActivate" ( BYVAL pByteStreamActivate AS IMFActivate
 , BYVAL pContentInfo AS IMFASFContentInfo
 , BYREF ppIActivate AS IMFActivate
 ) AS LONG
DECLARE FUNCTION MFCreateWMAEncoderActivate LIB "mf.dll" ALIAS "MFCreateWMAEncoderActivate" ( BYVAL pMediaType AS IMFMediaType
 , BYVAL pEncodingConfigurationProperties AS IPropertyStore
 , BYREF ppActivate AS IMFActivate
 ) AS LONG
'EXTERN_C const DECLSPEC_SELECTANY PROPERTYKEY MFPKEY_ASFMEDIASINK_BASE_SENDTIME = { { 0xcddcbc82, 0x3411, 0x4119, 0x91, 0x35, 0x84, 0x23, 0xc4, 0x1b, 0x39, 0x57}, 3 };
'EXTERN_C const DECLSPEC_SELECTANY PROPERTYKEY MFPKEY_ASFMEDIASINK_AUTOADJUST_BITRATE = { { 0xcddcbc82, 0x3411, 0x4119, 0x91, 0x35, 0x84, 0x23, 0xc4, 0x1b, 0x39, 0x57}, 4 };
'EXTERN_C const DECLSPEC_SELECTANY PROPERTYKEY MFPKEY_ASFMEDIASINK_DRMACTION = { { 0xa1db6f6c, 0x1d0a, 0x4cb6, 0x82, 0x54, 0xcb, 0x36, 0xbe, 0xed, 0xbc, 0x48}, 5 };
MACRO MFPKEY_ASFMEDIASINK_BASE_SENDTIME = GUID$("{CDDCBC82-3411-4119-9135-8423C41B3957}") & MKDWD$(3)
MACRO MFPKEY_ASFMEDIASINK_AUTOADJUST_BITRATE = GUID$("{CDDCBC82-3411-4119-9135-8423C41B3957}") & MKDWD$(4)
MACRO MFPKEY_ASFMEDIASINK_DRMACTION = GUID$("{A1DB6F6C-1D0A-4CB6-8254-CB36BEEDBC48}") & MKDWD$(5)
' enum MFSINK_WMDRMACTION
%EQUATE `MFSINK_WMDRMACTION_UNDEFINED = 0
%EQUATE `MFSINK_WMDRMACTION_ENCODE = 1
%EQUATE `MFSINK_WMDRMACTION_TRANSCODE = 2
%EQUATE `MFSINK_WMDRMACTION_TRANSCRYPT = 3
%EQUATE `MFSINK_WMDRMACTION_LAST = 3
'EXTERN_C const DECLSPEC_SELECTANY PROPERTYKEY MFPKEY_ASFSTREAMSINK_CORRECTED_LEAKYBUCKET = { { 0xa2f152fb, 0x8ad9, 0x4a11, 0xb3, 0x45, 0x2c, 0xe2, 0xfa, 0xd8, 0x72, 0x3d}, 1 };
MACRO MFPKEY_ASFSTREAMSINK_CORRECTED_LEAKYBUCKET = GUID$("{A2F152FB-8AD9-4A11-B345-2CE2FAD8723D}") & MKDWD$(1)
'//
'// Define WMContainer constants
'//
%EQUATE `MFASF_MAX_STREAM_NUMBER = 127
%EQUATE `MFASF_INVALID_STREAM_NUMBER = %MFASF_MAX_STREAM_NUMBER + 1
%EQUATE `MFASF_PAYLOADEXTENSION_MAX_SIZE = &Hff
%EQUATE `MFASF_PAYLOADEXTENSION_VARIABLE_SIZE = &Hffff
%EQUATE `MFASF_DEFAULT_BUFFER_WINDOW_MS = 3000
'//
'#if (WINVER >= _WIN32_WINNT_WIN7)
' ########################################################################################
' Interface name = IMFDRMNetHelper
' IID = 3D1FF0EA-679A-4190-8D46-7FA69E8C7E15
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IMFDRMNetHelper_INTERFACE_DEFINED)
 %IMFDRMNetHelper_INTERFACE_DEFINED = 1
$IID_IMFDRMNetHelper = GUID$("{3D1FF0EA-679A-4190-8D46-7FA69E8C7E15}")
INTERFACE IMFDRMNetHelper $IID_IMFDRMNetHelper
 INHERIT IUnknown
 ' =====================================================================================
 METHOD ProcessLicenseRequest ( ' VTable offset = 12
 BYVAL pLicenseRequest AS BYTE PTR ' __ BYTE *pLicenseRequest
 , BYVAL cbLicenseRequest AS DWORD
 , BYREF ppLicenseResponse AS DWORD
 , BYREF pcbLicenseResponse AS DWORD
 , BYREF pbstrKID AS WSTRING
 ) AS LONG
 ' =====================================================================================
 METHOD GetChainedLicenseResponse ( ' VTable offset = 16
 BYREF ppLicenseResponse AS DWORD
 , BYREF pcbLicenseResponse AS DWORD
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IMFDRMNetHelper_INTERFACE_DEFINED__ */
#ENDIF
