11 2015 档案
gif显示
摘要:public void gifplay(string path,ref Panel panel) { try{ Bitmap animatedGif = new Bitmap(path ); Graphics g = p...
阅读全文
字符画与拼接图片
摘要://字符画// 通过计算rowSize*colSize区域的亮度平均值用一个字符替代 public static String BitmapConvert(Bitmap bitmap, int rowSize, int colSize) { Stri...
阅读全文
计算图片不透明轨迹
摘要:/// Calculate the graphics path that representing the figure in the bitmap /// excluding the transparent color which is the top left pixel. ...
阅读全文
窗体特效
摘要:using System.Runtime.InteropServices; public class Win32 { public const Int32 AW_HOR_POSITIVE = 0x00000001; // 从左到右打开窗口 public const Int32 AW_HOR_NE...
阅读全文
全局钩子
摘要:using System;using System.Collections.Generic;using System.IO;using System.Windows.Forms;using System.Runtime.InteropServices;using System.Reflection;...
阅读全文
获取程序代码块资源消耗
摘要:// 在这里写一些可能消耗内存的代码,例如,如果想了解创建一个GcMultiRow软件需要多少内存可以执行以下代码long start = GC.GetTotalMemory(true);var gcMulitRow1 = new GcMultiRow();GC.Collect();// 确保所有内...
阅读全文
窗体移动
摘要:int x,y; void MainFormMouseDown(object sender, MouseEventArgs e) { if (e.Button == MouseButtons.Left) ...
阅读全文
处理图片透明操作
摘要:// /// 处理图片透明操作 /// /// 原始图片 /// 透明度(0.0---1.0) /// private Image TransparentImage(Image srcImage, float opacity) { float[][] nArray ={...
阅读全文
浙公网安备 33010602011771号