VideoDeviceController.GetDevicePropertyByExtendedId 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
從擷取設備驅動器取得具有指定標識碼的屬性值,使用具有自定義標頭資訊的擴充標識碼,以及指定儲存結果所需的緩衝區大小上限。 您可以使用這個方法來查詢特定相機特有的屬性。
public:
virtual VideoDeviceControllerGetDevicePropertyResult ^ GetDevicePropertyByExtendedId(Platform::Array <byte> ^ extendedPropertyId, IReference<unsigned int> ^ maxPropertyValueSize) = GetDevicePropertyByExtendedId;
VideoDeviceControllerGetDevicePropertyResult GetDevicePropertyByExtendedId(winrt::array_view <byte> const& extendedPropertyId, IReference<uint32_t> const& maxPropertyValueSize);
public VideoDeviceControllerGetDevicePropertyResult GetDevicePropertyByExtendedId(byte[] extendedPropertyId, System.Nullable<uint> maxPropertyValueSize);
function getDevicePropertyByExtendedId(extendedPropertyId, maxPropertyValueSize)
Public Function GetDevicePropertyByExtendedId (extendedPropertyId As Byte(), maxPropertyValueSize As Nullable(Of UInteger)) As VideoDeviceControllerGetDevicePropertyResult
參數
- extendedPropertyId
-
Byte[]
byte[]
包含擴充標識碼數據的位元組數位。
- maxPropertyValueSize
-
Windows.Foundation.IReference
IReference<uint32_t>
應該配置來儲存作業結果的緩衝區大小。 如果驅動程式不需要為傳回的屬性指定大小,請將此值設定為 null。 如果需要大小,而且您未提供值,則傳回之 VideoDeviceControllerGetDevicePropertyResult 物件的 Status 屬性會是 MaxPropertyValueSizeRequired。 如果所提供的值太小而無法儲存作業的結果,傳回的 Status 物件會是 MaxPropertyValueSizeTooSmall,這表示您可以使用較大的緩衝區大小重試呼叫。
傳回
VideoDeviceControllerGetDevicePropertyResult 物件,其中包含作業的狀態,如果成功,則傳回的屬性值。
Windows 需求
裝置系列 |
Windows 10 Creators Update (已於 10.0.15063.0 引進)
|
API contract |
Windows.Foundation.UniversalApiContract (已於 v4.0 引進)
|
備註
常見的裝置屬性會公開為 VideoDeviceController 類別的屬性。 其他屬性定義於 KSPROPERTYSETID_ExtendedCameraControl 屬性集中。 舊版屬性定義於 PROPSETID_VIDCAP_CAMERACONTROL 屬性集中。 如需依標識符存取相機屬性的範例,請參閱 擴充控件和元數據範例。