RandomFractals / geo-data-viewer

Geo Data Analytics tool for VSCode IDE with kepler.gl support to generate and view maps πŸ—ΊοΈ without any Python 🐍, IPyWidgets βš™οΈ, pandas 🐼, Jupyter notebooks πŸ“š, or ReactJS βš›οΈ app code.
https://marketplace.visualstudio.com/items?itemName=RandomFractalsInc.geo-data-viewer
Apache License 2.0
404 stars 43 forks source link

Line from KML disappearing after zoom #116

Closed tyanderson91 closed 3 years ago

tyanderson91 commented 3 years ago

I have a kml with some lines/curves that span the whole globe, including crossing the international date line and the prime meridian. These show up when zoomed all the way out. However, when zooming in even just a little bit, they disappear and don't come back until I zoom back out. I should be able to view portions of a line from .kml when zooming in.

RandomFractals commented 3 years ago

@tyanderson91 could you share some screen shots and kml data file for your issues? Thanks!

tyanderson91 commented 3 years ago

Can't attach a file but here is an example:

<?xml version="1.0" encoding="UTF-8"?>
<kml>
    <Document id="19">
        <Style id="22">
            <LineStyle id="23">
                <color>ff0000ff</color>
                <colorMode>normal</colorMode>
                <width>2</width>
            </LineStyle>
        </Style>
        <Placemark id="25">
            <name>Some Line</name>
            <styleUrl>#23</styleUrl>
            <LineString id="24">
                <coordinates>280,20,0 250,0,0 220,-20,0 150,-35,0 100,-50,0 100,-65,0 70,-80,0 50,-70,0 30,-45,0 15,-5,0 5,20,0</coordinates>
                <altitudeMode>clampToGround</altitudeMode>
            </LineString>
        </Placemark>
    </Document>
</kml>

It looks like the problem only occurs when trying to zoom in/pan to North America through the middle of the Pacific Ocean; Australia through Africa work fine. Maybe it's related to the longitude values being on a 0 to 360 scale instead of -180 to 180?

RandomFractals commented 3 years ago

@tyanderson91 not sure. might be a keplergl issue. I suggest you post it there with sample data and screenshot or recording of the path clipping issue you are experiencing.

RandomFractals commented 3 years ago

@tyanderson91 hey, I tried kml lines. Zoom seems to work with that kml file. see #67

image