DXGK_VIDPN_INTERFACE::pfnAcquireSourceModeSet routine

The pfnAcquireSourceModeSet function returns a handle to a particular source mode set object that is contained by a specified VidPN object.

Syntax


DXGKDDI_VIDPN_ACQUIRESOURCEMODESET pfnAcquireSourceModeSet;

NTSTATUS APIENTRY pfnAcquireSourceModeSet(
  _In_   const D3DKMDT_HVIDPN hVidPn,
  _In_   const D3DDDI_VIDEO_PRESENT_SOURCE_ID VidPnSourceId,
  _Out_  D3DKMDT_HVIDPNSOURCEMODESET *phVidPnSourceModeSet,
  _Out_  const DXGK_VIDPNSOURCEMODESET_INTERFACE **ppVidPnSourceModeSetInterface
)
{ ... }

Parameters

hVidPn [in]

[in] A handle to a VidPN object. The VidPN manager previously provided this handle to the display miniport driver by calling DxgkDdiEnumVidPnCofuncModality, DxgkDdiIsSupportedVidPn, or DxgkDdiRecommendFunctionalVidPn.

VidPnSourceId [in]

[in] An integer that identifies one of the video present sources associated with the VidPN object.

phVidPnSourceModeSet [out]

[out] A pointer to a variable that receives a handle to the requested source mode set object.

ppVidPnSourceModeSetInterface [out]

[out] A pointer to a variable that receives a pointer to a DXGK_VIDPNSOURCEMODESET_INTERFACE structure. The structure contains pointers to functions that the display miniport driver can call to inspect and alter the source mode set object.

Return value

The pfnAcquireSourceModeSet function returns one of the following values:

Return codeDescription
STATUS_SUCCESS

The function succeeded.

STATUS_GRAPHICS_INVALID_VIDPN

The handle supplied in hVidPn was invalid.

STATUS_GRAPHICS_INVALID_VIDEO_PRESENT_SOURCE

The identifier supplied in VidPnSourceId was invalid.

 

Remarks

VidPN source identifiers are assigned by the operating system. DxgkDdiStartDevice, implemented by the display miniport driver, returns the number N of video present sources supported by the display adapter. Then the operating system assigns identifiers 0, 1, 2, ... N - 1.

When you have finished using the source mode set object handle, you must release the handle by calling pfnReleaseSourceModeSet. Source mode set objects are reference counted, so if you acquire a handle several times, you must release it that same number of times.

The lifetime of the DXGK_VIDPNSOURCEMODESET_INTERFACE structure returned in ppVidPnSourceModeSetInterface is owned by the operating system. Using this ownership scheme, the operating system can switch to newer implementations at run time without breaking clients of the interface.

The D3DDDI_VIDEO_PRESENT_SOURCE_ID data type is defined in D3dukmdt.h.

The D3DKMDT_HVIDPN and D3DKMDT_HVIDPNSOURCEMODESET data types are defined in D3dkmdt.h.

Requirements

Version

Available in Windows Vista and later versions of the Windows operating systems.

Header

D3dkmddi.h (include D3dkmddi.h)

IRQL

PASSIVE_LEVEL

See also

VidPN Source Mode Set Interface
pfnReleaseTargetModeSet
pfnCreateNewSourceModeSet
pfnAssignTargetModeSet

 

 

Send comments about this topic to Microsoft

Show:
© 2014 Microsoft