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

How to draw a path? (eg navigation directions) #249

Open
elfensky opened this issue Jan 25, 2022 · 1 comment
Open

How to draw a path? (eg navigation directions) #249

elfensky opened this issue Jan 25, 2022 · 1 comment

Comments

@elfensky
Copy link

elfensky commented Jan 25, 2022

Is there a way to draw paths/lines on top of the OSMBuildings map?

I want to use OSMBuildings to display a navigation path. Like this, but with 3D buildings and across a city, not a country like the example.

I got as far as using the pointerdown event to get local coordinates and then unprojecting them to get world coordinates.

I know I can use addOBJ or addMarker to add them to the world coordinates, but I can't figure out any way to draw a path between two points.

I suppose I could make a "dotted" line using markers, but that can't be the right way to go about it, and I'd like a "filled" line I could animate on scroll.

I was initially struggling trying to use threejs to display geojson data, but it's really not performing well so I'd really like to use osmb if possible, your 3D engine is way faster.

@kekscom
Copy link
Member

kekscom commented Jan 28, 2022

Hi, There is no simple solution. Some users are buffering line strings (extend them to faces) and then are creating 3d models. I'd consider having a look into MapLibre as well.

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

2 participants