Swisstrains v2 kickoff
There are 4 years since I didn’t update www.swisstrains.ch project but nevertheless it was good thing because I used this interval to learn more about SBB railway infrastructure + more understanding of their website(which I am still crawling to get the project data from) but it was also an opportunity to polish my programming skills, to learn new technologies and to master various maps APIs; so now it’s time to move the project to the next level.
The current progress can be seen under hacks section of my website and in the following you can see what changed in this version.
These are from the G+ post that I posted shortly after publishing my hack.
- usage of GMaps JS API v3 + google.maps.geometry.spherical library; before I used v2 + home-made geo helpers
- cleaner, less and highly optimized JS code; if you want to have fun just read the (JS) source code of swisstrains.ch
- carefully reviewed HTTP headers and started to cache and GZIP always when I had the chance
- map interaction improved; there are no more ‘Loading’, ‘Zoom beyond level x forbidden’ annoying dialogs. Maps are also styled now (thanks GMaps v3 !) so the unnecessary elements (like roads) are dimmed.
- straightforward export process of the SBB trains network line; 4 years ago I used several (commercial) GIS tools, today I am using only open source tools
- storing of the railroad network(2000+ polylines and 1800 points=stations) is done using Fusion Tables; before painted them one by one (so 2000 GPolyline objects + 1800+ GMarkers=DIVs)
- ability to plot ALL the running vehicles (which are up to 700, depends on time of day) and visualize them in one map.
- GMaps API v3 is designed for mobile; guess what, this version runs smoothly and loads pretty fast on iPhone, Android. Tablets too !
Depending on my availability (remember I am doing this in my free time), I will try to:
- push this project to you via Github
- review/port other features of the current swisstrains.ch
- update the romanian version http://cfr.webgis.ro
- improve the mobile version, maybe try native
Make sure you watch this space for the next updates !
Also please add your comments about the project, i.e. if you miss any train lines, vehicles or you want to see new features.