VideoDeviceController 類別

定義

控制相機上的裝置設定。

public ref class VideoDeviceController sealed
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Standard)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.MTA)]
class VideoDeviceController final
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Standard)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.MTA)]
public sealed class VideoDeviceController
Public NotInheritable Class VideoDeviceController
繼承
Object Platform::Object IInspectable VideoDeviceController
屬性
實作

Windows 需求

裝置系列
Windows 10 (已於 10.0.10240.0 引進)
API contract
Windows.Foundation.UniversalApiContract (已於 v1.0 引進)

備註

若要取得這個物件的實例,請擷取 MediaCapture.VideoDeviceController 屬性。

某些驅動程式可能需要相機裝置預覽處於執行中狀態,才能判斷 VideoDeviceController支援哪些控制項。 如果您在預覽資料流程執行之前檢查 VideoDeviceController 是否支援特定控制項,即使影片裝置支援該控制項,仍可能會將其描述為不受支援。

注意

這個類別不是敏捷式的,這表示您需要考慮其執行緒模型和封送處理行為。 如需詳細資訊,請參閱執行緒和封送處理 (C++/CX) 在多執行緒環境中使用 Windows 執行階段 物件 (.NET)

版本歷程記錄

Windows 版本 SDK 版本 已新增值
1703 15063 GetDevicePropertyByExtendedId
1703 15063 GetDevicePropertyById
1703 15063 識別碼
1703 15063 SetDevicePropertyByExtendedId
1703 15063 SetDevicePropertyById
1803 17134 VideoTemporalDenoisingControl
1903 18362 InfraredTorchControl
2004 19041 PanelBasedOptimizationControl

屬性

AdvancedPhotoControl

取得此視訊裝置的進階相片擷取控制項。

BacklightCompensation

取得 MediaDeviceControl 物件,這個物件可用來取得或設定是否在相機上啟用回光補償。

Brightness

取得 MediaDeviceControl 物件,可用來取得或設定相機上的亮度等級。

CameraOcclusionInfo

取得 CameraOcclusionInfo 物件,可用來取得相機目前的遮蔽狀態,並在遮蔽狀態變更時收到通知。

Contrast

取得 MediaDeviceControl 物件,可用來取得或設定相機上的對比層級。

DesiredOptimization

取得或設定值,指出擷取裝置在影片擷取期間應該用來設定高品質圖片、低延遲或低耗電量的優先順序優化。

DigitalWindowControl

取得 DigitalWindowControl ,可讓應用程式擷取擷取裝置感應器的子系。

Exposure

取得 MediaDeviceControl 物件,可用來取得或設定相機的曝光時間。

ExposureCompensationControl

取得此視訊裝置的曝光補償控制。

ExposureControl

取得此視訊裝置的曝光控制項。

ExposurePriorityVideoControl

取得與VideoDeviceController相關聯的ExposurePriorityVideoControl

FlashControl

取得這個視訊裝置的快閃控制項。

Focus

取得 MediaDeviceControl 物件,可用來取得或設定相機的焦點設定。

FocusControl

取得這個視訊裝置的焦點控制項。

HdrVideoControl

取得與VideoDeviceController相關聯的HdrVideoControl。 這可讓您在支援的裝置上啟用和停用高動態範圍 (HDR) 視訊擷取模式。

Hue

取得 MediaDeviceControl 物件,可用來取得或設定相機的色調設定。

Id

取得包含視訊設備控制器識別碼的字串。

InfraredTorchControl

取得所選視訊裝置的基礎結構手電筒筒控制項。

IsoSpeedControl

取得這個視訊裝置的 ISO 電影速度控制。

LowLagPhoto

取得此視訊裝置的低快門延遲相片控制項。

LowLagPhotoSequence

取得此視訊裝置的低快門延遲相片序列控制項。

OpticalImageStabilizationControl

取得與VideoDeviceController相關聯的OpticalImageStabilizationControl

Pan

取得 MediaDeviceControl 物件,可用來取得或設定相機的移動流覽設定。

PanelBasedOptimizationControl

取得 PanelBasedOptimizationControl ,當支援時,允許應用程式啟用擷取設備磁碟機,根據相機的面板位置優化相機擷取功能。

PhotoConfirmationControl

取得此視訊裝置的相片確認控制項。

PrimaryUse

取得或設定裝置的主要用途。

RegionsOfInterestControl

取得此視訊裝置感興趣的區域。

Roll

取得 MediaDeviceControl 物件,可用來取得或設定相機的滾動設定。

SceneModeControl

取得這個視訊裝置的場景模式控制項。

Tilt

取得 MediaDeviceControl 物件,可用來取得或設定相機的傾斜設定。

TorchControl

取得這個視訊裝置的手電筒筒控制項。

VariablePhotoSequenceController

取得與 VideoDeviceController相關聯的 VariablePhotoSequenceController。

VideoTemporalDenoisingControl

取得與VideoDeviceController相關聯的VideoTemporalDenoisingControl。 這可讓您在支援的裝置上啟用和停用時態取消雜訊,其會使用相鄰畫面的影像資料來減少所擷取視訊中雜訊的外觀。

WhiteBalance

取得 MediaDeviceControl 物件,可用來取得或設定相機上的白色平衡。

WhiteBalanceControl

取得這個視訊裝置的白平衡控制項。

Zoom

取得 MediaDeviceControl 物件,可用來取得或設定相機的縮放設定。

ZoomControl

取得與VideoDeviceController相關聯的ZoomControl

方法

GetAvailableMediaStreamProperties(MediaStreamType)

取得影片裝置支援的編碼屬性清單。

GetDeviceProperty(String)

從擷取設備磁碟機取得具有指定識別碼的屬性值。 您可以使用這個方法來查詢特定相機特有的屬性。

GetDevicePropertyByExtendedId(Byte[], IReference<UInt32>)

從擷取設備磁碟機取得具有指定識別碼的屬性值,使用具有自訂標頭資訊的擴充識別碼,並指定儲存結果所需的緩衝區大小上限。 您可以使用這個方法來查詢特定相機特有的屬性。

GetDevicePropertyById(String, IReference<UInt32>)

使用自訂標頭資訊的識別碼,從擷取設備磁碟機取得 屬性的值。 您可以使用這個方法來查詢特定相機特有的屬性。

GetMediaStreamProperties(MediaStreamType)

取得視訊裝置之指定媒體資料流程類型的編碼屬性。

SetDeviceProperty(String, Object)

在擷取設備磁碟機上設定具有指定識別碼的 屬性值。 您可以使用這個方法來設定特定相機特有的屬性。

SetDevicePropertyByExtendedId(Byte[], Byte[])

使用具有自訂標頭資訊的擴充識別碼,並以位元組陣列的形式提供值,使用擷取設備磁碟機中指定識別碼的屬性值。

SetDevicePropertyById(String, Object)

使用具有自訂標頭資訊的擴充識別碼,並提供值做為物件,使用擷取設備磁碟機中指定識別碼的屬性值。

SetMediaStreamPropertiesAsync(MediaStreamType, IMediaEncodingProperties)

針對視訊裝置的指定媒體資料流程類型,以非同步方式設定編碼屬性。

TryAcquireExclusiveControl(String, MediaCaptureDeviceExclusiveControlReleaseMode)

要求具有指定裝置識別碼的相機獨佔控制。

TryGetPowerlineFrequency(PowerlineFrequency)

取得本機電源線頻率。

TrySetPowerlineFrequency(PowerlineFrequency)

設定本機電源線頻率。

適用於

另請參閱