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

findBuildingAtLatLng is not finding any building #54

Open
kegi opened this issue Feb 6, 2019 · 0 comments
Open

findBuildingAtLatLng is not finding any building #54

kegi opened this issue Feb 6, 2019 · 0 comments

Comments

@kegi
Copy link

kegi commented Feb 6, 2019

Description

The method "map.buildings.findBuildingAtLatLng" is not finding any building.

Steps to Reproduce

  1. Initialize map
  2. listen to "initialstreamingcomplete"
  3. call "findBuildingAtLatLng" with same coord as the example

Expected behavior:

This method should retrive a building juste like the version used in the example.

Actual behavior:

Buildings are never found, no matter the provided coordinates.

Code

const map = Leaflet.Wrld.map(
    $('[data-component="map"]')[0],
    'API_KEY',
);

map.on('initialstreamingcomplete', () => {

    let intersection = map.buildings.findBuildingAtLatLng([
        37.795159, -122.404336
    ]);

    console.log(intersection);
    // {found: 0, point: {lat: 0, lng: 0, alt: 0}}
});
@kegi kegi changed the title findBuildingAtLatLng is not finding building anymore findBuildingAtLatLng is not finding any building Feb 6, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant