Bagikan melalui


VideoDeviceController.GetDevicePropertyById Metode

Definisi

Mendapatkan nilai properti dari driver perangkat tangkap dengan ID dengan informasi header kustom. Anda dapat menggunakan metode ini untuk mengkueri properti yang khusus untuk kamera tertentu.

public:
 virtual VideoDeviceControllerGetDevicePropertyResult ^ GetDevicePropertyById(Platform::String ^ propertyId, IReference<unsigned int> ^ maxPropertyValueSize) = GetDevicePropertyById;
VideoDeviceControllerGetDevicePropertyResult GetDevicePropertyById(winrt::hstring const& propertyId, IReference<uint32_t> const& maxPropertyValueSize);
public VideoDeviceControllerGetDevicePropertyResult GetDevicePropertyById(string propertyId, System.Nullable<uint> maxPropertyValueSize);
function getDevicePropertyById(propertyId, maxPropertyValueSize)
Public Function GetDevicePropertyById (propertyId As String, maxPropertyValueSize As Nullable(Of UInteger)) As VideoDeviceControllerGetDevicePropertyResult

Parameter

propertyId
String

Platform::String

winrt::hstring

Pengidentifikasi properti tempat nilai diambil.

maxPropertyValueSize

IReference<UInt32>

Nullable<UInt32>

Windows.Foundation.IReference

IReference<uint32_t>

Ukuran buffer yang harus dialokasikan untuk menyimpan hasil operasi. Jika driver tidak mengharuskan ukuran ditentukan untuk properti yang dikembalikan, atur nilai ini ke null. Jika ukuran diperlukan, dan Anda tidak memberikan nilai, properti Status dari objek VideoDeviceControllerGetDevicePropertyResult yang dikembalikan akan menjadi MaxPropertyValueSizeRequired. Jika nilai yang disediakan terlalu kecil untuk menyimpan hasil operasi, objek Status yang dikembalikan akan menjadi MaxPropertyValueSizeTooSmall, yang berarti Anda dapat mencoba kembali panggilan dengan ukuran buffer yang lebih besar.

Mengembalikan

Objek VideoDeviceControllerGetDevicePropertyResult yang berisi status operasi dan, jika berhasil, nilai properti yang dikembalikan.

Persyaratan Windows

Rangkaian perangkat
Windows 10 Creators Update (diperkenalkan dalam 10.0.15063.0)
API contract
Windows.Foundation.UniversalApiContract (diperkenalkan dalam v4.0)

Keterangan

Properti perangkat umum diekspos sebagai properti kelas VideoDeviceController . Properti tambahan ditentukan dalam kumpulan properti KSPROPERTYSETID_ExtendedCameraControl . Properti warisan didefinisikan dalam kumpulan properti PROPSETID_VIDCAP_CAMERACONTROL . Untuk contoh mengakses properti kamera menurut ID, lihat sampel Extended Control dan Metadata.

Berlaku untuk