<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: BuildKaro</title>
    <description>The latest articles on DEV Community by BuildKaro (@buildkaro).</description>
    <link>https://dev.to/buildkaro</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4121751%2Fc7e68461-dc74-42b1-b9d1-323bf48933bd.jpg</url>
      <title>DEV Community: BuildKaro</title>
      <link>https://dev.to/buildkaro</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/buildkaro"/>
    <language>en</language>
    <item>
      <title>Building Pune Pulse: a real-time 3D digital twin with an IDM/MOBIL traffic engine</title>
      <dc:creator>BuildKaro</dc:creator>
      <pubDate>Sat, 12 Sep 2026 12:34:54 +0000</pubDate>
      <link>https://dev.to/buildkaro/building-pune-pulse-a-real-time-3d-digital-twin-with-an-idmmobil-traffic-engine-50k2</link>
      <guid>https://dev.to/buildkaro/building-pune-pulse-a-real-time-3d-digital-twin-with-an-idmmobil-traffic-engine-50k2</guid>
      <description>&lt;p&gt;I wanted to see my city — Pune, India — alive in 3D. Not a game with a fictional&lt;br&gt;
map, and not a navigation app tracking where I am. Just the real city, rendered&lt;br&gt;
accurately, with traffic that actually behaves like traffic. So I built it,&lt;br&gt;
solo, and shipped it free on Android as &lt;strong&gt;Pune Pulse&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Here's the architecture, and the parts I think are actually interesting.&lt;/p&gt;

&lt;h3&gt;
  
  
  Engines, not features
&lt;/h3&gt;

&lt;p&gt;The codebase is split into independent modules with typed APIs — lighting,&lt;br&gt;
weather, traffic, analytics, prediction, camera, and streaming are each their&lt;br&gt;
own engine rather than tangled feature code. That separation is what let the&lt;br&gt;
traffic simulation, the day/night cycle, and the what-if scenario tool all&lt;br&gt;
get built and tested independently.&lt;/p&gt;

&lt;h3&gt;
  
  
  The traffic engine: IDM + MOBIL, in a Web Worker
&lt;/h3&gt;

&lt;p&gt;The traffic isn't scripted paths or waypoint-following. Vehicles run on the&lt;br&gt;
&lt;strong&gt;Intelligent Driver Model (IDM)&lt;/strong&gt; for car-following and &lt;strong&gt;MOBIL&lt;/strong&gt; for lane&lt;br&gt;
changes — the same car-following math used in real traffic engineering&lt;br&gt;
research, not something I invented for the demo. It's a pure-TypeScript&lt;br&gt;
engine that runs in a Web Worker, so the simulation step never blocks the&lt;br&gt;
render thread.&lt;/p&gt;

&lt;p&gt;The payoff is the what-if tool: close any road in the city and watch traffic&lt;br&gt;
actually reroute, because the underlying model is a real road graph with real&lt;br&gt;
flow dynamics, not a fixed animation.&lt;/p&gt;

&lt;h3&gt;
  
  
  The city: OpenStreetMap, but only at build time
&lt;/h3&gt;

&lt;p&gt;Pune Pulse renders 95,666 real buildings and the actual road geometry for&lt;br&gt;
Pune, sourced from OpenStreetMap plus elevation data. Critically, OSM is a&lt;br&gt;
&lt;strong&gt;load-time data source only&lt;/strong&gt; — a build-time pipeline (&lt;code&gt;city-pipeline&lt;/code&gt;)&lt;br&gt;
converts OSM + elevation into a chunked, city-agnostic dataset ahead of time.&lt;br&gt;
The running app never talks to OSM; it just renders native three.js meshes&lt;br&gt;
from the pre-built dataset. That keeps it fast and means it works fully&lt;br&gt;
offline once the data is loaded.&lt;/p&gt;

&lt;h3&gt;
  
  
  Rendering: React Three Fiber, shipped to Android via Capacitor
&lt;/h3&gt;

&lt;p&gt;The renderer is React 19 + React Three Fiber on top of three.js, with&lt;br&gt;
postprocessing for the visual layer — the day/night cycle, weather (rain,&lt;br&gt;
haze, dynamic sun), a cinematic drone-style camera, and named real landmarks&lt;br&gt;
(Shaniwar Wada, Dagdusheth Halwai Ganpati, Aga Khan Palace, University&lt;br&gt;
Chowk). Pune Metro runs on its own movement independent of road traffic.&lt;/p&gt;

&lt;p&gt;It's a web app at its core — Capacitor is what wraps it and ships it as a&lt;br&gt;
native Android app, rather than maintaining a separate native codebase.&lt;/p&gt;

&lt;h3&gt;
  
  
  Zero API keys by design
&lt;/h3&gt;

&lt;p&gt;The whole thing is simulation-first: it's fully functional with zero API&lt;br&gt;
keys. Live data providers (TomTom for real traffic, OpenWeather for real&lt;br&gt;
conditions) plug in behind provider interfaces via a thin Express proxy —&lt;br&gt;
but they're optional. Nothing about the core experience depends on a live&lt;br&gt;
key existing.&lt;/p&gt;

&lt;p&gt;It also doesn't use GPS or track your location at all. This is a&lt;br&gt;
visualization/simulation tool, not a navigation app.&lt;/p&gt;

&lt;h3&gt;
  
  
  What's next
&lt;/h3&gt;

&lt;p&gt;I'd love feedback, especially from anyone who's worked on traffic&lt;br&gt;
simulation, OSM-to-3D pipelines, or shipping React Three Fiber apps as&lt;br&gt;
mobile apps via Capacitor. It's free on Google Play:&lt;br&gt;
&lt;a href="https://play.google.com/store/apps/details?id=com.punepulse.app" rel="noopener noreferrer"&gt;https://play.google.com/store/apps/details?id=com.punepulse.app&lt;/a&gt;&lt;/p&gt;

</description>
      <category>dev</category>
      <category>threejs</category>
      <category>webdev</category>
      <category>javascript</category>
    </item>
  </channel>
</rss>
