Lines connect several locations with each other. You can choose between various styles.
Use EarthInstance.addLine( properties )
var myline = myearth.addLine( {
locations: [
{ lat : 40.5, lng : -1 },
{ lat : 48.8, lng : 8.6 },
],
offsetFlow: 1,
width: 2
} );
[]
You must provide at least to two locations (start and end point).
0.01
Distance to the earth surface.
0
Offset at the end location. When used with offsetEasing: "arc" (default), this property determines the height of the arc.
"arc"
An easing function that describes the offsetFlow from start to end.
#FF0000
false
1
Only available if hairline: false
-1 (same value as width)
Width at the end point.
Only available if hairline: false
1
0.0 - 1.0
Displays only a part of the line. A clip value of 0.5 displays only the first half of the line.
true
0.5
0.5
0.01 - 0.99
0
1
0.0 - 1.0
false (if opacity is not set and dashed: false)
Needs to be true for using opacity and dashed lines.
Example: Transparent Rendering
true
false
Lines set to alwaysBehind: true are rendered behind Markers, Images and other Lines.
Example: alwaysBehind
Reference to the EarthInstance.
Example: Animatable Properties
Stops all animations of this object. To stop a specific animation use AnimationInstance.stop()
Removes the line permanently.