首页
诗词
字典
板报
句子
名言
友答
励志
学校
网站地图
图形图像
Photoshop
CorelDRAW
IIIustrator
InDesign
图形图像
Freehand
当前位置:
首页
>
教程频道
>
平面设计
>
图形图像
>
Silverlight 指路蜂二维图形库示例:路径
2012-06-24
Silverlight 引路蜂二维图形库示例:路径引路蜂二维图形库也提供了对一般路径的支持,可以同过线段,二次曲线
Silverlight 引路蜂二维图形库示例:路径
引路蜂二维图形库也提供了对一般路径的支持,可以同过线段,二次曲线,三次曲线组成路径,也可以根据SVG指令来定义路径。
private void Paths() { AffineTransform mat1; /* The path. */ Path path; /** Colors */ Color redColor = new Color(0x96ff0000, true); Color greenColor = new Color(0xff00ff00, false); Color blueColor = new Color(0x750000ff, true); string pathdata = "M 60 20 Q -40 70 60 120 Q 160 70 60 20 z"; mat1 = new AffineTransform(); mat1.Translate(30, 40); mat1.Rotate(-30 * Math.PI / 180.0); path = Path.FromString(pathdata); //Clear the canvas with white color. graphics2D.Reset(); graphics2D.Clear(Color.White); graphics2D.AffineTransform = new AffineTransform(); SolidBrush brush = new SolidBrush(greenColor); graphics2D.Fill(brush, path); graphics2D.AffineTransform = mat1; brush = new SolidBrush(blueColor); Pen pen = new Pen(redColor, 5); graphics2D.SetPenAndBrush(pen, brush); graphics2D.Draw(null, path); graphics2D.Fill(null, path); }
查看更多
下一篇
本文网址:
https://www.reader8.net/jiaocheng/20120624/2087637.html
读书人精选
热点排行
响应考灯箱插件image lightbox
《Java 二 图形设计卷Ⅱ- SWING》第12章
UIImage种及UIButton类02
网站挂黑链竟然将inc.asp放在images文件
javascript适用图像加载器
ubuntu 12.04 装配和配置mysql的图形工具
matlab 图像色彩的显示
《Java 二 图形设计卷Ⅱ- SWING》第8章
[OpenCV]实验1.1:图像加载、展示
施用(ImageMagick+tesseract-ocr)实现