5 ms·
Making this little website [1] was so eye opening. It's not just the fact that the 3 libraries that I used were different because they came from 3 different com
by GoToRO 9y ago
Making this little website [1] was so eye opening. It's not just the fact that the 3 libraries that I used were different because they came from 3 different companies. You could actually feel the difference in philosophy while using them.
[1] comparemaps.drona.ro
- mistermann 9y agoVERY COOL! Questions/comments: "Make Firefox get along with Google Maps (check this if you experience lag while dragging Google Map or OSM)" - what does this do? Running this, Google maps seems reasonably comparable to the others, yet when I just load Google maps on its own to look something up, it can easily take 5+ seconds to load.....any idea what might cause this discrepancy? Overlaying a more prominent brand label on each would be an improvement. Well done, I really like it!
- GoToRO 9y agoThis is how Chrome pushes out other browsers: first you make a browser that is fast in some aspect. Then you build an app that takes advantage of that aspect. In this case Chrome can handle a lot of events and Google Maps generate a lot of events. So in Chrome it is smooth. In other browsers (I use Firefox) the browser will choke on events and the map will lag. Maybe is just a matter of compiling Firefox with better defaults (more memory allocated, smaller tick rate for events, I don't know, I'm just making suppositions, I have no clue how a browser works) but it feels slower. To prevent this I throttle the events (checkbox checked): I kill the event if it arrived too fast or the change in mouse position is too small. This will make the map more responsive. Please note that I don't say that Chrome does this intentionally. But it happens. I've put more information here at the time: https://stackoverflow.com/questions/16645766/google-maps-api-v3-no-smooth-dragging/22030838#22030838 https://stackoverflow.com/questions/16645766/google-maps-api...
- GoToRO 9y agoOh, and thanks for the kind words!
- lucideer 9y agoThis is absolutely great, but I have two observations: 1. Google's embedded maps & API are significantly faster than their own maps on https://maps.google.com/ https://maps.google.com/. That particular team seems to have just recently fired or re-assigned every developer with any knowledge or - more likely, interest in - performance 2. I would guess the performance of the openstreetmap.org tileservers are the biggest bottleneck in your example. Their own website says "The tile service comes with no guarantee as to availability or speed", which is why alternative hosts of that dataset are so proliferate. Including a few alternative OSM tile hosts like opencyclemap, Mapbox, Mapzen, &c. could be very interesting.
- mistermann 9y agoAre you saying the maps API (which this demo uses) is fast, but the maps website itself is slow? That 100% matches my experience. But how could that be?
- GoToRO 9y agoThe API maps and google.com/maps are different products. Maybe they reuse some code but they do not have the same features. On google.com/maps if you search for a teritory (like a country) you will get a red border arround that teritory. On API maps developers asked for this feature for years and it is still not available.