' ########################################################################################
' Microsoft Windows
' File: evr9.inc
' Copyright (c) 201q 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_evr9_PBI)
#DEFINE PBX_evr9_PBI
%EQUATE `EVR9_INC = 1
'/* header files for imported files */
#INCLUDE ONCE "Legacy/COM/Unknwn.inc"
#INCLUDE ONCE "Legacy/System/mfobjects.inc"
#INCLUDE ONCE "Legacy/System/mftransform.inc"
#INCLUDE ONCE "Legacy/System/evr.inc"
#INCLUDE ONCE "Legacy/Graphics/dxva2api.inc"
' ########################################################################################
' Interface name = IEVRVideoStreamControl
' IID = D0CFE38B-93E7-4772-8957-0400C49A4485
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IEVRVideoStreamControl_INTERFACE_DEFINED)
 %IEVRVideoStreamControl_INTERFACE_DEFINED = 1
$IID_IEVRVideoStreamControl = GUID$("{D0CFE38B-93E7-4772-8957-0400C49A4485}")
INTERFACE IEVRVideoStreamControl $IID_IEVRVideoStreamControl
 INHERIT IUnknown
 ' =====================================================================================
 METHOD SetStreamActiveState ( ' VTable offset = 12
 BYVAL fActive AS LONG
 ) AS LONG
 ' =====================================================================================
 METHOD GetStreamActiveState ( ' VTable offset = 16
 BYREF lpfActive AS LONG
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IEVRVideoStreamControl_INTERFACE_DEFINED__ */
' ########################################################################################
' Interface name = IMFVideoProcessor
' IID = 6AB0000C-FECE-4D1F-A2AC-A9573530656E
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IMFVideoProcessor_INTERFACE_DEFINED)
 %IMFVideoProcessor_INTERFACE_DEFINED = 1
$IID_IMFVideoProcessor = GUID$("{6AB0000C-FECE-4D1F-A2AC-A9573530656E}")
INTERFACE IMFVideoProcessor $IID_IMFVideoProcessor
 INHERIT IUnknown
 ' =====================================================================================
 METHOD GetAvailableVideoProcessorModes ( ' VTable offset = 12
 BYREF lpdwNumProcessingModes AS DWORD
 , BYREF ppVideoProcessingModes AS GUID
 ) AS LONG
 ' =====================================================================================
 METHOD GetVideoProcessorCaps ( ' VTable offset = 16
 BYREF lpVideoProcessorMode AS GUID
 , BYREF lpVideoProcessorCaps AS DXVA2_VideoProcessorCaps
 ) AS LONG
 ' =====================================================================================
 METHOD GetVideoProcessorMode ( ' VTable offset = 20
 BYREF lpMode AS GUID
 ) AS LONG
 ' =====================================================================================
 METHOD SetVideoProcessorMode ( ' VTable offset = 24
 BYREF lpMode AS GUID
 ) AS LONG
 ' =====================================================================================
 METHOD GetProcAmpRange ( ' VTable offset = 28
 BYVAL dwProperty AS DWORD
 , BYREF pPropRange AS DXVA2_ValueRange
 ) AS LONG
 ' =====================================================================================
 METHOD GetProcAmpValues ( ' VTable offset = 32
 BYVAL dwFlags AS DWORD
 , BYREF Values AS DXVA2_ProcAmpValues
 ) AS LONG
 ' =====================================================================================
 METHOD SetProcAmpValues ( ' VTable offset = 36
 BYVAL dwFlags AS DWORD
 , BYREF pValues AS DXVA2_ProcAmpValues
 ) AS LONG
 ' =====================================================================================
 METHOD GetFilteringRange ( ' VTable offset = 40
 BYVAL dwProperty AS DWORD
 , BYREF pPropRange AS DXVA2_ValueRange
 ) AS LONG
 ' =====================================================================================
 METHOD GetFilteringValue ( ' VTable offset = 44
 BYVAL dwProperty AS DWORD
 , BYREF pValue AS DXVA2_Fixed32
 ) AS LONG
 ' =====================================================================================
 METHOD SetFilteringValue ( ' VTable offset = 48
 BYVAL dwProperty AS DWORD
 , BYREF pValue AS DXVA2_Fixed32
 ) AS LONG
 ' =====================================================================================
 METHOD GetBackgroundColor ( ' VTable offset = 52
 BYREF lpClrBkg AS DWORD
 ) AS LONG
 ' =====================================================================================
 METHOD SetBackgroundColor ( ' VTable offset = 56
 BYVAL ClrBkg AS DWORD
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IMFVideoProcessor_INTERFACE_DEFINED__ */
' // Size = 48 bytes
TYPE MFVideoAlphaBitmapParams DWORD
 dwFlags AS DWORD
 clrSrcKey AS DWORD ' COLORREF
 rcSrc AS RECT
 nrcDest AS MFVideoNormalizedRect
 fAlpha AS SINGLE ' FLOAT
 dwFilterMode AS DWORD
END TYPE
' // Size = 4 bytes
UNION MFVideoAlphaBitmap_UNION DWORD
 hdc AS DWORD ' HDC
 pDDS AS DWORD PTR ' IDirect3DSurface9*
END UNION
' // Size = 56 bytes
TYPE MFVideoAlphaBitmap DWORD
 GetBitmapFromDC AS LONG
 bitmap AS MFVideoAlphaBitmap_UNION
 params AS MFVideoAlphaBitmapParams
END TYPE
' enum MFVideoAlphaBitmapFlags
%EQUATE `MFVideoAlphaBitmap_EntireDDS = &H1
%EQUATE `MFVideoAlphaBitmap_SrcColorKey = &H2
%EQUATE `MFVideoAlphaBitmap_SrcRect = &H4
%EQUATE `MFVideoAlphaBitmap_DestRect = &H8
%EQUATE `MFVideoAlphaBitmap_FilterMode = &H10
%EQUATE `MFVideoAlphaBitmap_Alpha = &H20
%EQUATE `MFVideoAlphaBitmap_BitMask = &H3f
' ########################################################################################
' Interface name = IMFVideoMixerBitmap
' IID = 814C7B20-0FDB-4EEC-AF8F-F957C8F69EDC
' Inherited interface = IUnknown
' ########################################################################################
#IF NOT %DEF(%IMFVideoMixerBitmap_INTERFACE_DEFINED)
 %IMFVideoMixerBitmap_INTERFACE_DEFINED = 1
$IID_IMFVideoMixerBitmap = GUID$("{814C7B20-0FDB-4EEC-AF8F-F957C8F69EDC}")
INTERFACE IMFVideoMixerBitmap $IID_IMFVideoMixerBitmap
 INHERIT IUnknown
 ' =====================================================================================
 METHOD SetAlphaBitmap ( ' VTable offset = 12
 BYREF pBmpParms AS MFVideoAlphaBitmap
 ) AS LONG
 ' =====================================================================================
 METHOD ClearAlphaBitmap ( ' VTable offset = 16
 ) AS LONG
 ' =====================================================================================
 METHOD UpdateAlphaBitmapParameters ( ' VTable offset = 20
 BYREF pBmpParms AS MFVideoAlphaBitmapParams
 ) AS LONG
 ' =====================================================================================
 METHOD GetAlphaBitmapParameters ( ' VTable offset = 24
 BYREF pBmpParms AS MFVideoAlphaBitmapParams
 ) AS LONG
 ' =====================================================================================
END INTERFACE
#ENDIF ' /* __IMFVideoMixerBitmap_INTERFACE_DEFINED__ */
#ENDIF
