Search in sources :

Example 21 with CommandBuilder

use of net.osmand.plus.voice.CommandBuilder in project Osmand by osmandapp.

the class VoiceRouter method announceWaypoint.

public void announceWaypoint(List<LocationPointWrapper> points) {
    CommandBuilder p = getNewCommandPlayerToPlay();
    if (p == null) {
        return;
    }
    notifyOnVoiceMessage();
    makeSound();
    String text = getText(null, points, null);
    p.arrivedAtWayPoint(text).play();
}
Also used : CommandBuilder(net.osmand.plus.voice.CommandBuilder)

Example 22 with CommandBuilder

use of net.osmand.plus.voice.CommandBuilder in project Osmand by osmandapp.

the class VoiceRouter method approachWaypoint.

public void approachWaypoint(Location location, List<LocationPointWrapper> points) {
    CommandBuilder p = getNewCommandPlayerToPlay();
    if (p == null) {
        return;
    }
    notifyOnVoiceMessage();
    double[] dist = new double[1];
    makeSound();
    String text = getText(location, points, dist);
    p.goAhead(dist[0], null).andArriveAtWayPoint(text).play();
}
Also used : CommandBuilder(net.osmand.plus.voice.CommandBuilder)

Aggregations

CommandBuilder (net.osmand.plus.voice.CommandBuilder)22 AlarmInfoType (net.osmand.plus.routing.AlarmInfo.AlarmInfoType)1 TurnType (net.osmand.router.TurnType)1