MediaCaptureRelativePanelWatcher 類別

定義

監視與 DisplayRegion相關聯的面板,讓應用程式在面板的相對位置變更時收到通知。

public ref class MediaCaptureRelativePanelWatcher sealed : IClosable
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 655360)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
class MediaCaptureRelativePanelWatcher final : IClosable
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 655360)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
public sealed class MediaCaptureRelativePanelWatcher : System.IDisposable
Public NotInheritable Class MediaCaptureRelativePanelWatcher
Implements IDisposable
繼承
Object Platform::Object IInspectable MediaCaptureRelativePanelWatcher
屬性
實作

Windows 需求

裝置系列
Windows 10, version 2004 (已於 10.0.19041.0 引進)
API contract
Windows.Foundation.UniversalApiContract (已於 v10.0 引進)

備註

此 API 適用于轉軸裝置上的相機型案例,其顯示區域的相對位置可以在執行時間變更,讓應用程式動態修改其相機擷取行為。

藉由呼叫 MediaCapture.CreateRelativePanelWatcher來取得此類別的實例。

屬性

RelativePanel

取得 MediaCaptureRelativePanelWatcher 監視變更的相對面板。

方法

Close()

關閉相對面板監看員並處置相關聯的資源。

Dispose()

執行與釋放 (Free)、釋放 (Release) 或重設 Unmanaged 資源相關聯之應用程式定義的工作。

Start()

啟動相關聯DisplayRegion之相對面板位置的MediaCaptureRelativePanelWatcher監視。

Stop()

停止相關聯DisplayRegion之相對面板位置的MediaCaptureRelativePanelWatcher監視。

事件

Changed

MediaCaptureRelativePanelWatcher 所監視面板的相對位置變更時引發。

適用於

另請參閱

  • <xref:Windows.Media.Capture.MediaCapture.CreateRelativePanelWatcher(Windows.Media.Capture.StreamingCaptureMode%2cWindows.UI.WindowManagement.DisplayRegion)%0a%5bDisplayRegion%5d(%2fuwp%2fapi%2fwindows.ui.windowmanagement.displayregion)>