摘要:
方法一:Rectangle bounds = Screen.GetBounds(Point.Empty); using (Bitmap bitmap = new Bitmap(bounds.Width, bounds.Height)) { using (Graphics g = Graphics.FromImage(bitmap)) { g.CopyFromScreen(Point.Empty, Point.Empty, bounds.Size); ... 阅读全文
摘要:
http://www.cnblogs.com/softidea/p/3265576.html 阅读全文
摘要:
http://www.cnblogs.com/sync/p/3274968.html 阅读全文
摘要:
http://code.google.com/p/protobuf/downloads/list 阅读全文
摘要:
#WinPcap和Libpcap的最强大的特性之一,是拥有过滤数据包的引擎。 它提供了有效的方法去获取网络中的某些数据包,这也是WinPcap捕获机制中的一个组成部分。 用来过滤数据包的函数是# 阅读全文
摘要:
public static unsafe byte[] ConvertTo8Byte(Bitmap img) { byte[] result = new byte[img.Width * img.Height]; int n = 0; BitmapData data = img.LockBits(new Rectangle(0, 0, img.Width, img.Height), ImageLockMode.ReadOnly, ... 阅读全文
摘要:
Bitmap bit = new Bitmap(renderImage.Width, renderImage.Height); using (Graphics g = Graphics.FromImage(bit)) { g.DrawImage(pictureBox1.Image, new Rectangle(0, 0, renderImage.Width, renderImage.Height), new Rectangle(0, 0, renderImage.Width, renderImage.Height), ... 阅读全文
摘要:
/// /// 通过FileStream 来打开文件,这样就可以实现不锁定Image文件,到时可以让多用户同时访问Image文件 /// /// /// public static Bitmap ReadImageFile(string path) { FileStream fs = File.OpenRead(path); //OpenRead int filelength = 0; filelength = (int)... 阅读全文
摘要:
http://tieba.baidu.com/p/1954912175http://down.51cto.com/data/497803win8专业版:NBCCB-JJJDX-PKBKJ-KQX8X-WTV3H 阅读全文
摘要:
static void Serialize(T instance , string fileName){ using(XmlWriter writer = new XmlWriter(filename , Encoding.UTF8)) { XmlSerializer serializer = new XmlSerializer(typeof(T)); serializer.Serialize(writer , instance); }}Serialize(order , "order.xml"); 阅读全文