public static byte[] Compress(byte[] bytData) { MemoryStream ms = new MemoryStream(); Stream s = new DeflaterOutputStream(ms); s.Write(bytData, 0, bytData.Length); s.Close(); return (byte[])ms.ToArray(); }
public ZLib() { zlibstream = new DeflaterOutputStream(memory); }