⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 vmr9.idl

📁 vc6.0完整版
💻 IDL
📖 第 1 页 / 共 3 页
字号:
//=====================================================================

typedef enum {
    MixerPref9_NoDecimation             = 0x00000001, // No decimation - full size
    MixerPref9_DecimateOutput           = 0x00000002, // decimate output by 2 in x & y
    MixerPref9_DecimationReserved       = 0x0000000C, // bits reserved for future use.
    MixerPref9_DecimateMask             = 0x0000000F,

    MixerPref9_BiLinearFiltering        = 0x00000010, // use bi-linear filtering
    MixerPref9_PointFiltering           = 0x00000020, // use point filtering
    MixerPref9_AnisotropicFiltering     = 0x00000040, //
    MixerPref9_PyramidalQuadFiltering   = 0x00000080, // 4-sample tent
    MixerPref9_GaussianQuadFiltering    = 0x00000100, // 4-sample gaussian
    MixerPref9_FilteringReserved        = 0x00000E00, // bits reserved for future use.
    MixerPref9_FilteringMask            = 0x00000FF0, // OR of all above flags

    MixerPref9_RenderTargetRGB          = 0x00001000,
    MixerPref9_RenderTargetReserved     = 0x000FE000, // bits reserved for future use.
    MixerPref9_RenderTargetMask         = 0x000FF000, // OR of all above flags
} VMR9MixerPrefs;


//
//  Normalized relative rectangle
//  Coordinate ranges: x=[0...1) y=[0...1)
//  Where the output window goes from 0,0 (closed inclusive lower bound)
//  to 1,1 (open exclusive upper bound)
//
typedef struct _VMR9NormalizedRect
{
    float left;
    float top;
    float right;
    float bottom;
} VMR9NormalizedRect;



typedef enum {
    ProcAmpControl9_Brightness            = 0x00000001,
    ProcAmpControl9_Contrast              = 0x00000002,
    ProcAmpControl9_Hue                   = 0x00000004,
    ProcAmpControl9_Saturation            = 0x00000008,
    ProcAmpControl9_Mask                  = 0x0000000F
} VMR9ProcAmpControlFlags;

typedef struct _VMR9ProcAmpControl
{
    DWORD       dwSize;
    DWORD       dwFlags;
    float       Brightness;
    float       Contrast;
    float       Hue;
    float       Saturation;
} VMR9ProcAmpControl;

typedef struct _VMR9ProcAmpControlRange
{
    DWORD                       dwSize;
    VMR9ProcAmpControlFlags     dwProperty; // see VMR9ProcAmpControlFlags above
    float                       MinValue;
    float                       MaxValue;
    float                       DefaultValue;
    float                       StepSize;
} VMR9ProcAmpControlRange;


[
    local,
    object,
    local,
    uuid(1a777eaa-47c8-4930-b2c9-8fee1c1b0f3b),
    helpstring("IVMRMixerControl9 Interface"),
    pointer_default(unique)
]
interface IVMRMixerControl9 : IUnknown
{
    HRESULT SetAlpha(
        [in] DWORD dwStreamID,
        [in] float Alpha // Source alpha premultication factor (global alpha for source)
        );

    HRESULT GetAlpha(
        [in] DWORD dwStreamID,
        [out] float* pAlpha
        );

    HRESULT SetZOrder(
        [in] DWORD dwStreamID,
        [in] DWORD dwZ
        );

    HRESULT GetZOrder(
        [in] DWORD dwStreamID,
        [out] DWORD* pZ
        );

    HRESULT SetOutputRect(
        [in] DWORD dwStreamID,
        [in] const VMR9NormalizedRect *pRect
        );

    HRESULT GetOutputRect(
        [in] DWORD dwStreamID,
        [out] VMR9NormalizedRect *pRect
        );

    HRESULT SetBackgroundClr(
        [in] COLORREF ClrBkg
        );

    HRESULT GetBackgroundClr(
        [in] COLORREF* lpClrBkg
        );

    HRESULT SetMixingPrefs(
        [in] DWORD dwMixerPrefs  // a combination of VMRMixingPrefFlags
        );

    HRESULT GetMixingPrefs(
        [out] DWORD* pdwMixerPrefs
        );

    HRESULT SetProcAmpControl(
        [in] DWORD dwStreamID,
        [in] VMR9ProcAmpControl* lpClrControl
        );

    HRESULT GetProcAmpControl(
        [in] DWORD dwStreamID,
        [in, out] VMR9ProcAmpControl* lpClrControl
        );

    HRESULT GetProcAmpControlRange(
        [in] DWORD dwStreamID,
        [in, out] VMR9ProcAmpControlRange* lpClrControl
        );
};


//=====================================================================
//
// IVMRMixerBitmap9
//
//=====================================================================

typedef struct _VMR9AlphaBitmap
{
    DWORD               dwFlags;        // flags word
    HDC                 hdc;            // DC for the bitmap to copy
    IDirect3DSurface9*  pDDS;           // D3D surface to copy
    RECT                rSrc;           // rectangle to copy from the DC/DDS
    VMR9NormalizedRect  rDest;          // output rectangle in composition space
    FLOAT               fAlpha;         // opacity of the bitmap
    COLORREF            clrSrcKey;      // src color key
    DWORD               dwFilterMode;   // See "SetMixerPrefs"
} VMR9AlphaBitmap;


typedef enum {

    // Disable the alpha bitmap for now
    VMR9AlphaBitmap_Disable                     = 0x00000001,

    // Take the bitmap from the HDC rather than the DirectDraw surface
    VMR9AlphaBitmap_hDC                         = 0x00000002,

    // Take the entire DDraw surface - rSrc is ignored
    VMR9AlphaBitmap_EntireDDS                   = 0x00000004,

    // Indicates that the clrTrans value is valid and should be
    // used when blending
    VMR9AlphaBitmap_SrcColorKey                 = 0x00000008,

    // Indicates that the rSrc rectangle is valid and specifies a
    // sub-rectangle of the of original app image to be blended.
    // Use of this parameter enables "Image Strips"
    VMR9AlphaBitmap_SrcRect                     = 0x00000010,

    // Indicates that dwFilterMode parameter is valid and should be
    // used to overide the default filtering method used by the VMR.
    // MixerPref_PointFiltering is particulaly useful for images that
    // contain text and do not need to be stretch prior to blending with
    // the video content.
    VMR9AlphaBitmap_FilterMode                  = 0x00000020
} VMR9AlphaBitmapFlags;

[
    object,
    local,
    uuid(ced175e5-1935-4820-81bd-ff6ad00c9108),
    helpstring("IVMRMixerBitmap Interface"),
    pointer_default(unique)
]
interface IVMRMixerBitmap9 : IUnknown
{
    // Set bitmap, location to blend it, and blending value
    HRESULT SetAlphaBitmap(
        [in] const VMR9AlphaBitmap* pBmpParms
        );

    // Change bitmap location, size and blending value,
    // graph must be running for change to take effect.
    HRESULT UpdateAlphaBitmapParameters(
        [in] const VMR9AlphaBitmap* pBmpParms
        );

    // Get bitmap, location to blend it, and blending value
    HRESULT GetAlphaBitmapParameters(
        [out] VMR9AlphaBitmap* pBmpParms
        );
};



//=====================================================================
//
// IVMRSurface9
//
//=====================================================================
[
    local,
    object,
    local,
    uuid(dfc581a1-6e1f-4c3a-8d0a-5e9792ea2afc),
    helpstring("IVMRSurface Interface"),
    pointer_default(unique)
]
interface IVMRSurface9 : IUnknown
{
    HRESULT IsSurfaceLocked();

    HRESULT LockSurface(
        [out] BYTE** lpSurface
        );

    HRESULT UnlockSurface();

    HRESULT GetSurface(
        [out] IDirect3DSurface9** lplpSurface
        );
};



//=====================================================================
//
// IID_IVMRImagePresenterConfig9 - this interface allows applications
// to configure the default Microsoft provided allocator-presenter
// inorder to simplify the implementation of their own
// allocator-presenter plug-in.
//
//=====================================================================
typedef enum {
    RenderPrefs9_DoNotRenderBorder           = 0x00000001, // app paints color keys
    RenderPrefs9_Mask                        = 0x00000001, // OR of all above flags
} VMR9RenderPrefs;
[
    local,
    object,
    local,
    uuid(45c15cab-6e22-420a-8043-ae1f0ac02c7d),
    helpstring("IVMRImagePresenterConfig9 Interface"),
    pointer_default(unique)
]

interface IVMRImagePresenterConfig9 : IUnknown
{

    HRESULT SetRenderingPrefs(
        [in] DWORD dwRenderFlags   // see VMRRenderPrefs for valid flags
        );

    HRESULT GetRenderingPrefs(
        [out] DWORD* dwRenderFlags // see VMRRenderPrefs for valid flags
        );

}




//=====================================================================
//
// IVMRVideoStreamControl9
//
//=====================================================================
[
    object,
    local,
    uuid(d0cfe38b-93e7-4772-8957-0400c49a4485),
    helpstring("IVMRMixerStreamConfig Interface"),
    pointer_default(unique)
]
interface IVMRVideoStreamControl9: IUnknown
{

    HRESULT SetStreamActiveState(
            [in] BOOL fActive
            );

    HRESULT GetStreamActiveState(
            [out] BOOL* lpfActive
            );
};


typedef enum {
    VMR9Mode_Windowed                        = 0x00000001,
    VMR9Mode_Windowless                      = 0x00000002,
    VMR9Mode_Renderless                      = 0x00000004,

    // not a valid value to pass to SetRenderMode
    VMR9Mode_Mask                            = 0x00000007, // OR of all above flags
} VMR9Mode;

[
    object,
    local,
    uuid(5a804648-4f66-4867-9c43-4f5c822cf1b8),
    helpstring("IVMRFilterConfig9 Interface"),
    pointer_default(unique)
]
interface IVMRFilterConfig9 : IUnknown
{
    HRESULT SetImageCompositor(
            [in] IVMRImageCompositor9* lpVMRImgCompositor
            );

    HRESULT SetNumberOfStreams(
            [in] DWORD dwMaxStreams
            );

    HRESULT GetNumberOfStreams(
            [out] DWORD* pdwMaxStreams
            );

    HRESULT SetRenderingPrefs(
            [in] DWORD dwRenderFlags  // a combination of VMR9RenderPrefs
            );

    HRESULT GetRenderingPrefs(
            [out] DWORD* pdwRenderFlags
            );

    HRESULT SetRenderingMode(
            [in] DWORD Mode  // a combination of VMRMode
            );

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -