private bool Start(FileStream os) { if (os == null) return false; bool ok = true; _closeStream = false; _fs = os; try { WriteString("GIF89a"); // header } catch (IOException) { ok = false; } return _started = ok; }
public static void OutputGIF(Bitmap f, String fn) { GifEncoder gif = new GifEncoder(); gif.SetQuality(4); gif.Start(fn); gif.AddFrame(f); gif.Finish(); }