This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.
To capture the video (filesize: 19MB), using the free "QuickTime Player" application:
| async Task CompileModelAsync() | |
| { | |
| //Define remote URL | |
| var model_remote_url = ""; | |
| var model_name = "FruitModel"; | |
| var model_file_extension = "mlodel"; | |
| string path = Environment.GetFolderPath(Environment.SpecialFolder.Personal); | |
| string model_path = Path.Combine(path, $"{model_name + model_file_extension}"); |
| public class GzipWebClient : WebClient | |
| { | |
| protected override WebRequest GetWebRequest(Uri address) | |
| { | |
| var request = base.GetWebRequest(address); | |
| if(request is HttpWebRequest) | |
| { | |
| ((HttpWebRequest)request).AutomaticDecompression = DecompressionMethods.Deflate | DecompressionMethods.GZip; | |
| } |
| Logger.Info("Sending analytics request to Segment.io ..", props); | |
| var start = DateTime.Now; | |
| HttpResponseMessage response = null; | |
| try { | |
| //breakpoint hit | |
| response = _client.SendAsync(request).Result; | |
| public class EventArgs<T> : EventArgs | |
| { | |
| public T Data { get; set; } | |
| public EventArgs (T data) | |
| { | |
| Data = data; | |
| } | |
| public static EventArgs<T> From (T data) |
| if (UIDevice.CurrentDevice.CheckSystemVersion (6, 0)) | |
| { | |
| var status = ABAddressBook.GetAuthorizationStatus(); | |
| if (status == ABAuthorizationStatus.Denied || status == ABAuthorizationStatus.Restricted) { | |
| // no address book | |
| } else { | |
| if (this.addressBook == null) | |
| this.addressBook = new ABAddressBook(); | |
| if (status == ABAuthorizationStatus.NotDetermined) { |
| public static ABAddressBook Create (out NSError error) | |
| { | |
| IntPtr intPtr; | |
| IntPtr value = ABAddressBook.ABAddressBookCreateWithOptions (IntPtr.Zero, out intPtr); | |
| ABAddressBook result; | |
| if (value == IntPtr.Zero) | |
| { | |
| error = new NSError (intPtr); | |
| result = null; | |
| } |
| public static ABAddressBook Create (out NSError error) | |
| { | |
| IntPtr intPtr; | |
| IntPtr value = ABAddressBook.ABAddressBookCreateWithOptions (IntPtr.Zero, out intPtr); | |
| ABAddressBook result; | |
| if (value == IntPtr.Zero) | |
| { | |
| error = new NSError (intPtr); | |
| result = null; | |
| } |
| public class MyViewController : UIViewController { | |
| public override void ViewDidLoad () | |
| { | |
| base.ViewDidLoad (); | |
| for (int i = 0; i < Int32.MaxValue; i++) { | |
| DoStuffAsync(); | |
| } | |
| } |
| package main | |
| import ( | |
| "github.com/gorilla/rpc" | |
| "github.com/gorilla/rpc/json" | |
| "net/http" | |
| ) | |
| type HelloArgs struct { | |
| Who string |