internal async Task InitializeAsync_Impl(ExampleMediaCaptureInitializationSettings ExampleMediaCaptureInitializationSettings = null)
        {
            InitializationSettings = ExampleMediaCaptureInitializationSettings ?? new ExampleMediaCaptureInitializationSettings();

            await SelectExclusiveSourceGroupAsync();

            if (UseFallbackSourceGroup)
            {
                await SelectFallbackSourceGroupAsync();
            }

            await InitializeExclusiveMediaCaptureAsync();

            if (UseFallbackSourceGroup)
            {
                await InitializeFallbackMediaCaptureAsync();
            }

            await SetMediaFormatAsync();

            if (InitializationSettings.FaceDetectionAffinity == ExampleMediaCaptureFaceDetectionAffinity.MediaCapturePreview)
            {
                await EnablePreviewFaceDetectionAsync(InitializationSettings.FaceDetectionMode);
            }

            PopulateProperties();
        }
 public IAsyncAction InitializeAsync(ExampleMediaCaptureInitializationSettings ExampleMediaCaptureInitializationSettings) => InitializeAsync_Impl(ExampleMediaCaptureInitializationSettings).AsAsyncAction();