public static void BeginCaptureToXcode() { bool flag = !FrameCapture.IsDestinationSupported(FrameCaptureDestination.DevTools); if (flag) { throw new InvalidOperationException("Frame Capture with DevTools is not supported."); } FrameCapture.BeginCaptureImpl(FrameCaptureDestination.DevTools, null); }
public static void BeginCaptureToFile(string path) { bool flag = !FrameCapture.IsDestinationSupported(FrameCaptureDestination.GPUTraceDocument); if (flag) { throw new InvalidOperationException("Frame Capture to file is not supported."); } bool flag2 = string.IsNullOrEmpty(path); if (flag2) { throw new ArgumentException("path", "Path must be supplied when capture destination is GPUTraceDocument."); } bool flag3 = Path.GetExtension(path) != ".gputrace"; if (flag3) { throw new ArgumentException("path", "Destination file should have .gputrace extension."); } FrameCapture.BeginCaptureImpl(FrameCaptureDestination.GPUTraceDocument, new Uri(path).AbsoluteUri); }