TouchVG framework
|
求曲线上最近点的函数 更多...
#include <mgnear.h>
静态 Public 成员函数 | |
static float | nearestOnBezier (const Point2d &pt, const Point2d *pts, Point2d &nearpt) |
计算一点到三次贝塞尔曲线段上的最近点 更多... | |
static Box2d | bezierBox1 (const Point2d points[4]) |
计算贝塞尔曲线段的绑定框 更多... | |
static Box2d | bezierBox4 (const Point2d &p1, const Point2d &p2, const Point2d &p3, const Point2d &p4) |
计算贝塞尔曲线段的绑定框 更多... | |
static void | beziersBox (Box2d &box, int count, const Point2d *points, bool closed=false) |
计算贝塞尔曲线的绑定框 更多... | |
static bool | beziersIntersectBox (const Box2d &box, int count, const Point2d *points, bool closed=false) |
判断贝塞尔曲线是否与矩形相交 更多... | |
static void | cubicSplinesBox (Box2d &box, int n, const Point2d *knots, const Vector2d *knotvs, bool closed=false, bool hermite=true) |
计算三次样条曲线的绑定框 更多... | |
static bool | cubicSplinesIntersectBox (const Box2d &box, int n, const Point2d *knots, const Vector2d *knotvs, bool closed=false, bool hermite=true) |
判断三次样条曲线是否与矩形相交 更多... | |
static float | cubicSplinesHit (int n, const Point2d *knots, const Vector2d *knotvs, bool closed, const Point2d &pt, float tol, Point2d &nearpt, int &segment, bool hermite=true) |
计算点到三次样条曲线的最近距离 更多... | |
static float | quadSplinesHit (int n, const Point2d *knots, bool closed, const Point2d &pt, float tol, Point2d &nearpt, int &segment) |
计算点到二次样条曲线的最近距离 更多... | |
static float | linesHit (int n, const Point2d *points, bool closed, const Point2d &pt, float tol, Point2d &nearpt, int &segment, bool *inside=(bool *) 0, int *hitType=(int *) 0, int flags=-1, int ignoreVertex=-1) |
计算点到折线或多边形的最近距离 更多... | |
static float | roundRectHit (const Box2d &rect, float rx, float ry, const Point2d &pt, float tol, Point2d &nearpt, int &segment) |
计算点到圆角矩形的最近距离 更多... | |
static void | getRectHandle (const Box2d &rect, int index, Point2d &pt) |
得到矩形的8个控制手柄坐标 更多... | |
static void | moveRectHandle (Box2d &rect, int index, const Point2d &pt, bool lockCornerScale=true) |
移动矩形的一个控制手柄 更多... | |
求曲线上最近点的函数