我有一个图书馆,利用中点近线,定期收集比照路数(构成许多比方点的复杂路程)。
我可以毫不怀疑地提出这些建议,但我需要为先进的地貌作业提供更多支持: 曲线最接近点,交叉点,数字包含点,更重要的是,path组合:差异、交叉点、排他性、联盟, ......
是否有很好的来源来做到这一点?
增 编
我有一个图书馆,利用中点近线,定期收集比照路数(构成许多比方点的复杂路程)。
我可以毫不怀疑地提出这些建议,但我需要为先进的地貌作业提供更多支持: 曲线最接近点,交叉点,数字包含点,更重要的是,path组合:差异、交叉点、排他性、联盟, ......
是否有很好的来源来做到这一点?
增 编
我不得不在 cur或封闭的道路上实施其中一些行动。 大部分锅炉.到底线和多管。 几个有用的概念:
任意分区的示范守则:
static Point2D.Double[][] splitBezier(Point2D.Double[] p) {
return splitBezier(p, 0.5);
}
static Point2D.Double[][] splitBezier(Point2D.Double[] p, double t) {
Point2D.Double[][] parts = new Point2D.Double[2][4];
Point2D.Double ab = interpolate(t, p[0], p[1]);
Point2D.Double bc = interpolate(t, p[1], p[2]);
Point2D.Double cd = interpolate(t, p[2], p[3]);
Point2D.Double abc = interpolate(t, ab, bc);
Point2D.Double bcd = interpolate(t, bc, cd);
Point2D.Double abcd = interpolate(t, abc, bcd);
parts[0][0] = p[0];
parts[0][1] = ab;
parts[0][2] = abc;
parts[0][3] = abcd;
parts[1][0] = abcd;
parts[1][2] = bcd;
parts[1][2] = cd;
parts[1][3] = p[3];
return parts;
}
static Point2D.Double interpolate(double t, Point2D.Double a, Point2D.Double b) {
return new Point2D.Double((1 - t) * a.getX() + t * b.getX(),
(1 - t) * a.getY() + t * b.getY());
}
一些有用的网站:
I have been given an assignement for a graphics module, one part of which is to calculate the minimum bounding ellipse of a set of arbitrary shapes. The ellipse doesn t have to be axis aligned. This ...
How can we check if a line segment falls partially or fully inside a triangle? Cheers.
I have a point p, and 2 line segments in a 2D plane. Point p is a location of view from where camera is looking towards the line segments. I want to check if line segment 1 is partially or fully ...
I have a set of points and I need to convert the set to (non-overlapping) triangles (or a big polygon if equivalent)... The application: I have a list of locations (latitude,longitude) from a country,...
Just Curious. I m currently foraying into the world of Java coding, and, was wondering weather Geometry can come useful in the kind of programming a Beginner to Intermediate Skill level Java coder has....
I have to write an algorithm in AS3.0 that plots the location of points radially. I d like to input a radius and an angle at which the point should be placed. Obviously I remember from geometry ...
I have a polygon determined by an Array of Points. This polygon is crossing itself making some holes in the polygon itself. My questions is: How can I omit this holes and just get the exterior ...
I am working with complex networks. I want to find group of nodes which forms a cycle of 3 nodes (or triangles) in a given graph. As my graph contains about million edges, using a simple iterative ...