public interface IPathConverter
| Modifier and Type | Method | Description |
|---|---|---|
long |
calculateDuration(ch.sahits.game.openpatrician.model.ship.INavigableVessel vessel,
ch.sahits.game.openpatrician.clientserverinterface.service.PathInterpolator interpolator,
double fraction) |
Calculate the duration of the travel in milliseconds in real time for the specified fraction of the total distance
|
java.util.Optional<javafx.scene.shape.Path> |
createPath(ch.sahits.game.openpatrician.model.ship.INavigableVessel vessel,
java.util.List<javafx.geometry.Point2D> pointedPath,
double scale) |
Create a path shape out of a list of points.
|
java.util.List<javafx.geometry.Point2D> |
reduceLinePoints(java.util.List<javafx.geometry.Point2D> initialPoints) |
Reduce the number of points that are needed to describe the path.
|
java.util.Optional<javafx.scene.shape.Path> createPath(ch.sahits.game.openpatrician.model.ship.INavigableVessel vessel,
java.util.List<javafx.geometry.Point2D> pointedPath,
double scale)
vessel - vessel that is traveling the path.pointedPath - input points.scale - scaling that is used on the path due to the sacle of the map.java.util.List<javafx.geometry.Point2D> reduceLinePoints(java.util.List<javafx.geometry.Point2D> initialPoints)
initialPoints - list of initial pointslong calculateDuration(ch.sahits.game.openpatrician.model.ship.INavigableVessel vessel,
ch.sahits.game.openpatrician.clientserverinterface.service.PathInterpolator interpolator,
double fraction)
vessel - that is travelinginterpolator - used to hold the path informationfraction - value between [0,1]. 1 means that the whole distance is traveled.Copyright © 2011-2018 Sahits GmbH. All Rights Reserved.