本文整理了Java中com.vividsolutions.jts.geom.Geometry.createPointFromInternalCoord()
方法的一些代码示例,展示了Geometry.createPointFromInternalCoord()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Geometry.createPointFromInternalCoord()
方法的具体详情如下:
包路径:com.vividsolutions.jts.geom.Geometry
类名称:Geometry
方法名:createPointFromInternalCoord
暂无
代码示例来源:origin: com.vividsolutions/jts
/**
* Computes an interior point of this <code>Geometry</code>.
* An interior point is guaranteed to lie in the interior of the Geometry,
* if it possible to calculate such a point exactly. Otherwise,
* the point may lie on the boundary of the geometry.
* <p>
* The interior point of an empty geometry is <code>POINT EMPTY</code>.
*
* @return a {@link Point} which is in the interior of this Geometry
*/
public Point getInteriorPoint()
{
if (isEmpty())
return factory.createPoint((Coordinate) null);
Coordinate interiorPt = null;
int dim = getDimension();
if (dim == 0) {
InteriorPointPoint intPt = new InteriorPointPoint(this);
interiorPt = intPt.getInteriorPoint();
}
else if (dim == 1) {
InteriorPointLine intPt = new InteriorPointLine(this);
interiorPt = intPt.getInteriorPoint();
}
else {
InteriorPointArea intPt = new InteriorPointArea(this);
interiorPt = intPt.getInteriorPoint();
}
return createPointFromInternalCoord(interiorPt, this);
}
代码示例来源:origin: com.vividsolutions/jts
centPt = cent.getCentroid();
return createPointFromInternalCoord(centPt, this);
代码示例来源:origin: com.vividsolutions/jts-core
/**
* Computes the centroid of this <code>Geometry</code>.
* The centroid
* is equal to the centroid of the set of component Geometries of highest
* dimension (since the lower-dimension geometries contribute zero
* "weight" to the centroid).
* <p>
* The centroid of an empty geometry is <code>POINT EMPTY</code>.
*
* @return a {@link Point} which is the centroid of this Geometry
*/
public Point getCentroid()
{
if (isEmpty())
return factory.createPoint((Coordinate) null);
Coordinate centPt = Centroid.getCentroid(this);
return createPointFromInternalCoord(centPt, this);
}
代码示例来源:origin: com.vividsolutions/jts-core
/**
* Computes an interior point of this <code>Geometry</code>.
* An interior point is guaranteed to lie in the interior of the Geometry,
* if it possible to calculate such a point exactly. Otherwise,
* the point may lie on the boundary of the geometry.
* <p>
* The interior point of an empty geometry is <code>POINT EMPTY</code>.
*
* @return a {@link Point} which is in the interior of this Geometry
*/
public Point getInteriorPoint()
{
if (isEmpty())
return factory.createPoint((Coordinate) null);
Coordinate interiorPt = null;
int dim = getDimension();
if (dim == 0) {
InteriorPointPoint intPt = new InteriorPointPoint(this);
interiorPt = intPt.getInteriorPoint();
}
else if (dim == 1) {
InteriorPointLine intPt = new InteriorPointLine(this);
interiorPt = intPt.getInteriorPoint();
}
else {
InteriorPointArea intPt = new InteriorPointArea(this);
interiorPt = intPt.getInteriorPoint();
}
return createPointFromInternalCoord(interiorPt, this);
}
内容来源于网络,如有侵权,请联系作者删除!