【发布时间】:2018-10-29 13:27:41
【问题描述】:
我有一个应用程序,我需要通过手机摄像头一次拍摄多张图像。用户不想一次又一次地打开相机。
我也尝试过https://github.com/jamesmontemagno/MediaPlugin 插件,但它不支持连续图像捕获。它一次点击一张图片。
有没有办法实现这种行为?
谢谢
【问题讨论】:
标签: c# xamarin xamarin.forms
我有一个应用程序,我需要通过手机摄像头一次拍摄多张图像。用户不想一次又一次地打开相机。
我也尝试过https://github.com/jamesmontemagno/MediaPlugin 插件,但它不支持连续图像捕获。它一次点击一张图片。
有没有办法实现这种行为?
谢谢
【问题讨论】:
标签: c# xamarin xamarin.forms
Can you try this in media plugin
for (int i = 0; i < 3; i++)
{
file = await MediaPicker.TakePhotoAsync(new StoreCameraMediaOptions { SaveToAlbum = true, Name = "", Directory = "" });
if (file != null)
{
//code to save
}
The user can press cancel at anytime to stop taking pictures, and it'll hit the return and stop running the code. But its ran the logic to save the images each time a photo has been taken.
【讨论】: