Ejemplo n.º 1
0
        private IList <CameraTheaterMode> GetSupportedTheaterModes()
        {
            List <CameraTheaterMode> theaterModes = new List <CameraTheaterMode>();

            NativeCapabilities.TheaterModeCallback callback = (CameraTheaterMode theaterMode, IntPtr userData) =>
            {
                theaterModes.Add(theaterMode);
                return(true);
            };
            CameraErrorFactory.ThrowIfError(NativeCapabilities.SupportedTheaterModes(_camera.GetHandle(), callback, IntPtr.Zero),
                                            "Failed to get the supported theater modes.");

            return(theaterModes.AsReadOnly());
        }
Ejemplo n.º 2
0
        private IList <CameraTheaterMode> GetSupportedTheaterModes()
        {
            var theaterModes = new List <CameraTheaterMode>();

            NativeCapabilities.TheaterModeCallback callback = (theaterMode, _) =>
            {
                theaterModes.Add(theaterMode);
                return(true);
            };

            NativeCapabilities.SupportedTheaterModes(_camera.GetHandle(), callback).
            ThrowIfFailed("Failed to get the supported theater modes.");

            return(theaterModes.AsReadOnly());
        }