Error in polylineVolume documentation ?

PolylineVolume documentation states: “An array of Cartesain3 positions that define the center of the polyline volume.”

In polylineVolume example I see that an array of Cartesain3 positions define the bottom of the polyline volume.

This behavior can be seen in this slightly changed polylineVolume example:

If I’m right the documentation should be corrected to: An array of Cartesain3 positions that define the bottom****of the polylineVolume.

If not, please show me how set positions to define the center****of the polylineVolume.

As I have czml file containing polylines that defines pipes center, i seems that I must move them in z direction to the bottom vertices of the pipes, before i provide positions array to polyineVertices method ?

Cesium ver. 1.44 - 2018-04-02

Windows 10 Pro 1709

Chrome Version 67.0.3396.99 (Official Build) (64-bit)

Hi Alen,

It is indeed from the bottom, we already have an issue open tracking the bug, #6350. I’ve bumped the issue with this report.

I would suggest not modifying the z value, as that moves the positions in fixed frame rather than towards the center of the earth. I would convert to **Cartographic **positions and adjust the height.

Thanks,

Gabby

To bypass that issue I did the the following:

  • Use a standard XMLHttpRequest to retrieve czml data with Cartographic** (lat, long, height) **positions;

  • Czml should have pipe diameter data for every pipe, may be as json strings in description, like: {Diameter: “100”};

  • Recalculate bottmHeight = height - Diameter

  • For polylineVolume positions do:
    { positions: Cesium.Cartesian3.fromDegreesArrayHeights()…};

    ``

Dana ponedjeljak, 2. srpnja 2018. u 09:43:12 UTC+2, korisnik Alen Kelemen napisao je: