use of eu.esdihumboldt.util.geometry.interpolation.model.ArcByCenterPoint in project hale by halestudio.
the class ArcGridSegment method getFirstPart.
@Override
public ArcSegment getFirstPart() {
ArcByCenterPoint byCenter = arc.toArcByCenterPoint();
Angle middleAngle = Angle.fromRadians(byCenter.getStartAngle().getRadians() + 0.5 * byCenter.getAngleBetween().getRadians());
Arc part = new ArcByCenterPointImpl(byCenter.getCenterPoint(), byCenter.getRadius(), byCenter.getStartAngle(), middleAngle, byCenter.isClockwise());
// match the parent segment's
return new FixedStartEndGridSegment(part, true, gridSize, getStartPoint(), getMiddlePoint());
}
use of eu.esdihumboldt.util.geometry.interpolation.model.ArcByCenterPoint in project hale by halestudio.
the class ArcGridSegment method getSecondPart.
@Override
public ArcSegment getSecondPart() {
ArcByCenterPoint byCenter = arc.toArcByCenterPoint();
Angle middleAngle = Angle.fromRadians(byCenter.getStartAngle().getRadians() + 0.5 * byCenter.getAngleBetween().getRadians());
Arc part = new ArcByCenterPointImpl(byCenter.getCenterPoint(), byCenter.getRadius(), middleAngle, byCenter.getEndAngle(), byCenter.isClockwise());
// match the parent segment's
return new FixedStartEndGridSegment(part, true, gridSize, getMiddlePoint(), getEndPoint());
}
use of eu.esdihumboldt.util.geometry.interpolation.model.ArcByCenterPoint in project hale by halestudio.
the class ArcSplitSegment method getSecondPart.
@Override
public ArcSegment getSecondPart() {
ArcByCenterPoint byCenter = arc.toArcByCenterPoint();
Angle middleAngle = Angle.fromRadians(byCenter.getStartAngle().getRadians() + 0.5 * byCenter.getAngleBetween().getRadians());
Arc part = new ArcByCenterPointImpl(byCenter.getCenterPoint(), byCenter.getRadius(), middleAngle, byCenter.getEndAngle(), byCenter.isClockwise());
return new FixedStartEndSplitSegment(part, maxPositionalError, getMiddlePoint(), getEndPoint());
}
use of eu.esdihumboldt.util.geometry.interpolation.model.ArcByCenterPoint in project hale by halestudio.
the class ArcSplitSegment method getFirstPart.
@Override
public ArcSegment getFirstPart() {
ArcByCenterPoint byCenter = arc.toArcByCenterPoint();
Angle middleAngle = Angle.fromRadians(byCenter.getStartAngle().getRadians() + 0.5 * byCenter.getAngleBetween().getRadians());
Arc part = new ArcByCenterPointImpl(byCenter.getCenterPoint(), byCenter.getRadius(), byCenter.getStartAngle(), middleAngle, byCenter.isClockwise());
return new FixedStartEndSplitSegment(part, maxPositionalError, getStartPoint(), getMiddlePoint());
}
Aggregations