Share via


ICameraCaptureDeviceNative::SetDevice method for Windows Phone 8

July 21, 2014

Applies to: Windows Phone 8 and Windows Phone Silverlight 8.1 only

Allows the capture device to share a Direct3D device with the hosting app.

VOID SetDevice(
   [in]    ID3D11Device* pDevice,
   [in]    ID3D11DeviceContext* pContext
);

Parameters

  • pDevice [in]
    Type: ID3D11Device*

    A pointer to the Direct3D device.

  • pContext [in]
    Type: ID3D11DeviceContext*

    A pointer to the Direct3D device context.

Return value

This method does not return a value.

Remarks

Important Note:

You must call this method before using the ICameraCaptureDeviceNative::GetPreviewBufferTexture method for Windows Phone 8. The texture passed to the GetPreviewBufferTexture method must belong to the device-context pair that is specified with pDevice and pContext.

To access the IcameraCaptureDeviceNative interface, invoke the IUnknown::QueryInterface method on the instance of the PhotoCaptureDevice class or the AudioVideoCaptureDevice class, using the UUID of ICameraCaptureDeviceNative. This method is not directly available from a managed projection, but you can write your own Windows Runtime object that wraps it.

Requirements

Minimum supported phone

Windows Phone 8

Header

Windows.Phone.Media.Capture.Native.h

Namespace

Windows::Phone::Media::Capture

See Also

Other Resources

Advanced photo capture for Windows Phone 8

Advanced capture properties for Windows Phone 8