Show HN: Follow London Trains in 3D
66 points - last Saturday at 4:11 PM
deck.gl based visualiser of the TFL Api + National Rails to be able to track (with minimal drift) a train along the way in London and to the nearest airports. If you pick one from any platform in https://nexttrain.london basically you can share your train journey along the rails. Build to test Cloudflare workers and their infra along with deck.gl performance that is incredible in my opinion.
Sourceadecoster
today at 5:24 PM
A bit buggy in term of tiles jonctions
TheOtherHobbes
today at 3:38 PM
Interesting but quite buggy. Example: mouse dragging seems trapped in a fairly small area.
mgranados
today at 4:18 PM
Ah yeah i tried anchoring to the train with a threshold for panning around i'll try smoothing it. thanks for trying it!
ampdepolymerase
today at 5:35 PM
Can you add support for touch?
I'd love to see a view with all/many trains. In London I was constantly wondering what the criss-cross of underground lines looked like.
mgranados
today at 4:23 PM
I saw a project like that here in hn recently for all uk trains even. it'd be pretty cool to extend this to support that, busy stations might be visually confusing, thanks for suggestions
There seems to be some parallax issues between your trip layer and your 3D Tiles layer, but nice usage of deck.gl.
taylorius
today at 4:39 PM
Is it not that certain train lines are somewhat deep underground? The Piccadilly line swims with respect to the ground in the centre of town, when it is below ground. Further out where lines are at the surface the routes stick to the ground correctly.
mgranados
today at 4:21 PM
thank you! i'll have a look
It would appear you are missing the High Barnet branch of the Northern line.
And the Reading branch of the Elizabeth line
mgranados
today at 4:23 PM
thanks for feedback i'll have a look!
Very nice, but the map seems to be in the wrong position vs. the trains/3d elements.
Having just taken the Elisabeth Line to LHR T5 and sitting here, this was fun. Thanks.
Edit: Is there a Repo to look at and learn from this?
mgranados
today at 4:27 PM
<3 thanks!! i'll clean it and share here sometime soon
kentonv
last Sunday at 3:07 PM
This is really cool!
Quick suggestion: When not tracking a train, the mouse wheel should zoom into / out from where the cursor is pointing, rather than the center of the window.
mgranados
today at 4:30 PM
thanks! that's a great suggestion will implement
This is incredibly cool. I had it open on my desktop for most of the day.
Falimonda
today at 3:28 PM
How do I drive the train? Arrow keys not working :(
mgranados
today at 4:29 PM
It's just following api data for now. That'd be a real cool feature for backlog!
model rough but amazing. i cant do this
The planes were a surprise
mgranados
today at 4:29 PM
hehe thanks!
philipwhiuk
today at 2:33 PM
I'm curious what the 3D model source is - the Gherkin is kinda weird.
The train paths are drawn on a 2D layer above the buildings, not at z-index that matches the proper 3-D position. So the paths appear to weave around and over the tops of buildings.
mgranados
today at 4:34 PM
I meant to make it feel like the tube ones felt "underground" by some metres i'll have a look thanks