SVG路径字符串格式

命令名称参数
M 移动到(moveTo) (x y)+
Z 闭合路径(closepath) (none)
L 直线(lineTo) (x y)+
H 水平直线 x+
V 垂直直线 y+
C 曲线(curveto) (x1 y1 x2 y2 x y)+
S 平滑曲线 (x2 y2 x y)+
Q 二次贝赛尔曲线 (x1 y1 x y)+
T 平滑二次贝塞尔曲线 (x y)+
A 椭圆弧 (rx ry x-axis-rotation large-arc-flag sweep-flag x y)+
R Catmull-Rom 曲线* x1 y1 (x y)+

* “Catmull-Rom 曲线”不是标准SVG命令,在2.0版时被加入。 注:有种特殊情况,路径只包含三个命令:“M10,10R…z”。在这种情况下,路径将平滑连接到它的起点。

更多:http://www.w3.org/TR/SVG/paths.html#PathData

posted on 2013-08-03 20:28  李超@hicc  阅读(1946)  评论(0编辑  收藏  举报

导航