0
AdvancedPhotoCaptureを使用してSoftwareBitmapを取得しようとしましたが、結果として得られるCapturedPhoto.Frame.SoftwareBitmapがnullです。 SoftwareBitmapをスクリーンに表示するには、どうすれば入手できますか?CapturedPhoto.Frame.SoftwareBitmap is null
//create mediacapture
mediaCapture = new MediaCapture();
await mediaCapture.InitializeAsync();
// check if supported
var settings = new AdvancedPhotoCaptureSettings
{
Mode = AdvancedPhotoMode.Standard
};
//configure capture
if (!mediaCapture.VideoDeviceController.AdvancedPhotoControl.SupportedModes.Contains(settings.Mode))
{
Debug.WriteLine("Mode not supported");
return;
}
mediaCapture.VideoDeviceController.AdvancedPhotoControl.Configure(settings);
var adv = await mediaCapture.PrepareAdvancedPhotoCaptureAsync(ImageEncodingProperties.CreateJpeg());
// take photo
var capturedPhoto = await adv.CaptureAsync();
Debug.WriteLine(capturedPhoto.Frame.SoftwareBitmap == null);