Hello,
I am new to Cesium and am looking for a solution to creating parallels (lines of latitude), and eventually longitudes as well. I am using polylines to create the latitude lines. Relevant code looks like this:
for (var latLineSecs of newLatArr) {
var latLineId = "latLine_" + latLineSecs
latPositions = getLatitudeLinePositions(secondsToDecimalDegrees(latLineSecs))
latLine = new Cesium.Entity({
name: 'latLine',
id: latLineId,
show: true,
polyline: {
loop: true,
arcType: Cesium.ArcType.None,
width: that.get('width'),
material: that.get('color'),
positions: latPositions,
clampToGround: true,
}
})
When calling this function to create 10 degree increment latitude lines over the whole globe surface (so total of 19 latitude lines circling the globe), it takes upwards of 8 seconds to complete/render (not nice), when using clampToGround.
When setting clampToGround to false, it completes/renders in less than a second (nice).
The reason for attempting to use clampToGround is to avoid the paralax movement of the polylines against the globe surface (as apparently the polylines do have some default height… I assume). i.e. The lines appear to change positions on the globe, when not using clampToGround.
Thanks for any help, thoughts,
Andrew