Esempio n. 1
0
        private IList <CameraFps> GetSupportedPreviewFps()
        {
            List <CameraFps> previewFps = new List <CameraFps>();

            NativeCapabilities.FpsCallback callback = (CameraFps fps, IntPtr userData) =>
            {
                previewFps.Add(fps);
                return(true);
            };
            CameraErrorFactory.ThrowIfError(NativeCapabilities.SupportedPreviewFps(_camera.GetHandle(), callback, IntPtr.Zero),
                                            "Failed to get the supported camera fps");

            return(previewFps.AsReadOnly());
        }
Esempio n. 2
0
        private IList <CameraFps> GetSupportedPreviewFps()
        {
            var previewFps = new List <CameraFps>();

            NativeCapabilities.FpsCallback callback = (fps, _) =>
            {
                previewFps.Add(fps);
                return(true);
            };

            NativeCapabilities.SupportedPreviewFps(_camera.GetHandle(), callback).
            ThrowIfFailed("Failed to get the supported camera fps");

            return(previewFps.AsReadOnly());
        }