随笔分类 -  Graphics & Imaging

摘要:其实网上有挺多实现鼠标滚轮支持的文章,原理都一样,通过 HtmlPage.Window.AttachEvent("DOMMouseScroll", ...)来对ScrollViewer进行控制,但许多却仅限于对ScrollViewer添加滚轮支持,而对TextBox、ListBox这样的控件 好像挺没辙的。使用Reflector看TextBox和ListBox的实现,发现他们内部都有一个field... 阅读全文

posted @ 2009-02-13 10:54 Adrian H. 阅读(1454) 评论(4) 推荐(0)

摘要:C# code snippet below is an illustration of the Cooky-Turkey algorithm, the performance may suck when processing huge datasets, but you can use arrays of double instead of arrays of complex number structure to reduce the performance impact by object initializations and method invocations(overloaded operators). 阅读全文

posted @ 2007-08-10 15:30 Adrian H. 阅读(3235) 评论(3) 推荐(0)

摘要:Lena(或Lenna) 的图片是在数字图像处理的文献中经常被引用做示例图片, 我对这幅图片的出处也一直很好奇, 今天才在网上发现.. 原来她是某年Playboy杂志里的... 阅读全文

posted @ 2007-08-10 14:57 Adrian H. 阅读(1706) 评论(0) 推荐(0)

摘要:PGM(Portable Gray Map) is an image format which uses 1 or 2 byte to store a grayscale pixel, the format specification is simple and straight forward, detail specification can be seen here So, writing a simple converter from PGM to the most common used BMP format is really an easy job. 阅读全文

posted @ 2007-08-07 13:56 Adrian H. 阅读(3120) 评论(1) 推荐(1)

摘要:GLEE 是 Microsoft Research 的 Lev Nachmanson 开发的一个.NET 图形布局和查看的工具, 遵循了 Sugiyama 方案, 可以生成有层次的的布局, 自然地使用图形表示流程的信息, 如程序流程, 状态机, 类图等等.. 阅读全文

posted @ 2007-06-12 19:50 Adrian H. 阅读(1550) 评论(2) 推荐(0)

摘要:Inspired by http://incubator.quasimondo.com/processing/fastblur.pde , I wrote a piece of CSharp code to implement this efficient "gaussian blur" alogorithm for one of my .Net project. The concept of the "fast" is avoiding floating point calculation and pre-calculating some multiplication operation, storing the results into a large two-dimension array for later blurring operations, so it saves lots of time. 阅读全文

posted @ 2007-03-30 22:17 Adrian H. 阅读(27662) 评论(6) 推荐(0)