Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect straight CorridorGeometry #2511

Closed
bagnell opened this issue Feb 24, 2015 · 1 comment · Fixed by #2513
Closed

Incorrect straight CorridorGeometry #2511

bagnell opened this issue Feb 24, 2015 · 1 comment · Fixed by #2513

Comments

@bagnell
Copy link
Contributor

bagnell commented Feb 24, 2015

Copy the below code into Sandcastle. The corridor should be straight along the longitude.

var viewer = new Cesium.Viewer('cesiumContainer', { infoBox : false });
var entities = viewer.entities;

entities.add({
    corridor : {
        positions : Cesium.Cartesian3.fromDegreesArray([
            -67.655, 0.0,
            -67.655, 5.0,
            -67.655, 10.0,
            -67.655, 15.0,
            -67.655, 20.0,
            -67.655, 25.0,
            -67.655, 30.0,
            -67.655, 35.0,
            -67.655, 40.0,
            -67.655, 45.0,
            -67.655, 50.0,
            -67.655, 55.0,
            -67.655, 60.0,
            -67.655, 65.0,
            -67.655, 70.0,
            -67.655, 75.0,
            -67.655, 80.0,
            -67.655, 85.0,
            -67.655, 90.0
        ]),
        width : 400000,
        height : 0,
        outline : true,
        outlineColor : Cesium.Color.WHITE,
        outlineWidth : 4,
        material : Cesium.Color.fromRandom({alpha : 0.7})
    }
});

viewer.zoomTo(viewer.entities);
@WarpDrive
Copy link

This array is straight
-67.655, 0.0,
-67.655, 10.0,
-67.655, 20.0,
This array bends
-67.655, 0.0,
-67.655, 15.0,
-67.655, 20.0,
This array is straight
-67.655, 0.0,
-67.655, 20.0,
-67.655, 40.0,
This array bends
-67.655, 0.0,
-67.655, 30.0,
-67.655, 40.0,
Seems like it wants equidistance, but the original example is. Weird.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants