MediaCapture.CapturePhotoToStorageFileAsync Metode

Definisi

Mengambil foto ke file penyimpanan.

public:
 virtual IAsyncAction ^ CapturePhotoToStorageFileAsync(ImageEncodingProperties ^ type, IStorageFile ^ file) = CapturePhotoToStorageFileAsync;
/// [Windows.Foundation.Metadata.RemoteAsync]
IAsyncAction CapturePhotoToStorageFileAsync(ImageEncodingProperties const& type, IStorageFile const& file);
[Windows.Foundation.Metadata.RemoteAsync]
public IAsyncAction CapturePhotoToStorageFileAsync(ImageEncodingProperties type, IStorageFile file);
function capturePhotoToStorageFileAsync(type, file)
Public Function CapturePhotoToStorageFileAsync (type As ImageEncodingProperties, file As IStorageFile) As IAsyncAction

Parameter

type
ImageEncodingProperties

Properti pengodean untuk gambar output.

file
IStorageFile

File penyimpanan tempat gambar disimpan.

Mengembalikan

Mengembalikan objek IAsyncAction yang digunakan untuk mengontrol operasi asinkron.

Atribut

Persyaratan Windows

Kemampuan aplikasi
backgroundMediaRecording microphone webcam

Keterangan

Untuk panduan cara mengambil foto ke file penyimpanan, lihat Pengambilan foto, video, dan audio Dasar dasar dengan MediaCapture.

Berlaku untuk