jamesmontemagno/MediaPlugin

Camera close app in Android 10 Samsung SM-A105f API 29

Kiparin opened this issue · 4 comments

Bug Information

image

LogDevice.txt

Compressed_20210212_140758.mp4

Version Number of Plugin: 5.0.1
Device Tested On: Samsung SM-A105f
Version of VS: Version 16.8.5
Version of Xamarin: 16.8.000.262

Good afternoon. This mistake happens by accident. There is no pattern.
Could kill the app with 1 photo, maybe a few photos need to be taken.

Hey @Kiparin,
did you found any workarounds?
i have absolutely the same issue.. urrghhs

@PhillipWayne Hallo . We couldn't overcome the problem. As a result, we rewrote everything on Xamarin.forms

@PhillipWayne

         await CrossMedia.Current.Initialize();

            if (!CrossMedia.Current.IsCameraAvailable || !CrossMedia.Current.IsTakePhotoSupported)
            {
                Android.Widget.Toast.MakeText(Application.Context, "Камера недоступна", Android.Widget.ToastLength.Long).Show();
                return null;
            }
            var file = await CrossMedia.Current.TakePhotoAsync(new StoreCameraMediaOptions
            {
                DefaultCamera = CameraDevice.Rear,
                ModalPresentationStyle = MediaPickerModalPresentationStyle.OverFullScreen,
                CompressionQuality = 40,
                SaveToAlbum = true,
                PhotoSize = PhotoSize.Medium,
                Name = name + ".jpg",
                Directory = "StemyAppPhotos"
            }).ConfigureAwait(true);

As I understand it, the library does not fit into the dead clock of the operating system, and it kills the data transfer process. Next, and the application.

We found optimal settings in which the crash of the application decreased, but did not overcome the root of the problem.

Maz47 commented

@PhillipWayne @Kiparin

Do you have any updates? I am having the same problem.