private IList <Rotation> GetSupportedStreamRotations() { List <Rotation> streamRotations = new List <Rotation>(); NativeCapabilities.StreamRotationCallback callback = (Rotation streamRotation, IntPtr userData) => { streamRotations.Add(streamRotation); return(true); }; CameraErrorFactory.ThrowIfError(NativeCapabilities.SupportedStreamRotations(_camera.GetHandle(), callback, IntPtr.Zero), "Failed to get the supported camera rotations."); return(streamRotations.AsReadOnly()); }
private IList <Rotation> GetSupportedStreamRotations() { var streamRotations = new List <Rotation>(); NativeCapabilities.StreamRotationCallback callback = (streamRotation, _) => { streamRotations.Add(streamRotation); return(true); }; NativeCapabilities.SupportedStreamRotations(_camera.GetHandle(), callback). ThrowIfFailed("Failed to get the supported camera rotations."); return(streamRotations.AsReadOnly()); }