<?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: Manan Verma</title>
    <description>The latest articles on DEV Community by Manan Verma (@darkbytezz).</description>
    <link>https://dev.to/darkbytezz</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.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3816949%2F390080a7-bebb-4965-8c79-6c502fc270f8.jpeg</url>
      <title>DEV Community: Manan Verma</title>
      <link>https://dev.to/darkbytezz</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/darkbytezz"/>
    <language>en</language>
    <item>
      <title>Building a Real-Time Posture Monitoring System in the Browser (MediaPipe + PiP)</title>
      <dc:creator>Manan Verma</dc:creator>
      <pubDate>Tue, 10 Mar 2026 16:00:10 +0000</pubDate>
      <link>https://dev.to/darkbytezz/building-a-real-time-posture-monitoring-system-in-the-browser-mediapipe-pip-3akm</link>
      <guid>https://dev.to/darkbytezz/building-a-real-time-posture-monitoring-system-in-the-browser-mediapipe-pip-3akm</guid>
      <description>&lt;h2&gt;
  
  
  Browsers Kill Background Tabs. Here’s How I Kept My Computer Vision Engine Alive.
&lt;/h2&gt;

&lt;p&gt;Most browser-based computer vision apps quietly die the moment you minimize Chrome.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;I needed mine to keep running.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F69hlm3gqpt25bzlu50at.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F69hlm3gqpt25bzlu50at.png" alt="Posture+ running in Picture-in-Picture while Chrome is minimized"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I’ve been building &lt;strong&gt;Posture+&lt;/strong&gt;, a browser-based posture monitoring system using computer vision.&lt;/p&gt;

&lt;p&gt;The system analyzes pose keypoints from the webcam and computes a &lt;strong&gt;Posture Stability Index (PSI)&lt;/strong&gt; — a metric that tracks posture drift over time.&lt;/p&gt;

&lt;p&gt;The underlying temporal stability framework behind PSI has also been accepted for presentation at &lt;strong&gt;IEEE CSPA 2026&lt;/strong&gt;.&lt;/p&gt;




&lt;p&gt;You can try the live demo here:&lt;/p&gt;

&lt;p&gt;

&lt;/p&gt;
&lt;div class="crayons-card c-embed text-styles text-styles--secondary"&gt;
    &lt;div class="c-embed__content"&gt;
      &lt;div class="c-embed__body flex items-center justify-between"&gt;
        &lt;a href="https://posture-plus.vercel.app/" rel="noopener noreferrer" class="c-link fw-bold flex items-center"&gt;
          &lt;span class="mr-2"&gt;posture-plus.vercel.app&lt;/span&gt;
          

        &lt;/a&gt;
      &lt;/div&gt;
    &lt;/div&gt;
&lt;/div&gt;




&lt;p&gt;The system runs entirely in the browser — no installation required.&lt;/p&gt;

&lt;h2&gt;
  
  
  It even keeps running when Chrome is minimized.
&lt;/h2&gt;

&lt;p&gt;But while building it, I ran into a big problem.&lt;/p&gt;

&lt;p&gt;Modern browsers aggressively suspend background tabs.&lt;/p&gt;

&lt;p&gt;That means the moment the user switches tabs or minimizes Chrome, the entire posture monitoring engine stops.&lt;/p&gt;

&lt;p&gt;Which defeats the purpose of a posture monitoring tool.&lt;/p&gt;

&lt;p&gt;People don’t sit staring at a monitoring tab all day.&lt;/p&gt;




&lt;h2&gt;
  
  
  The Problem
&lt;/h2&gt;

&lt;p&gt;Most browsers throttle background tabs.&lt;/p&gt;

&lt;p&gt;JavaScript execution slows down.&lt;br&gt;&lt;br&gt;
Rendering pauses.&lt;br&gt;&lt;br&gt;
Real-time processing pipelines stall.&lt;/p&gt;
&lt;h2&gt;
  
  
  For applications that rely on continuous camera processing, this becomes a major issue.
&lt;/h2&gt;
&lt;h2&gt;
  
  
  The Workaround
&lt;/h2&gt;

&lt;p&gt;The solution I implemented uses &lt;strong&gt;Picture-in-Picture (PiP)&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Instead of streaming the webcam directly, the system renders posture analysis to a &lt;strong&gt;canvas&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;That canvas is then converted into a video stream using:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="nx"&gt;canvas&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;captureStream&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;This converts the rendered canvas into a real video stream that the browser treats like active media playback.&lt;br&gt;
This stream feeds a hidden video element.&lt;/p&gt;

&lt;p&gt;When the tab becomes hidden or the browser is minimized, the system automatically switches the stream into &lt;strong&gt;PiP mode&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Since PiP video must remain active, the browser keeps the pipeline alive.&lt;/p&gt;

&lt;p&gt;This allows the posture engine to continue running even when the main tab is not visible.&lt;/p&gt;


&lt;h2&gt;
  
  
  Result
&lt;/h2&gt;

&lt;p&gt;Now posture monitoring continues while the user works normally.&lt;/p&gt;

&lt;p&gt;The floating PiP window shows:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;pose keypoints&lt;/li&gt;
&lt;li&gt;posture overlay&lt;/li&gt;
&lt;li&gt;PSI score&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Even if Chrome is minimized, the posture engine keeps running.&lt;br&gt;
The system only stops when the browser itself is closed.&lt;/p&gt;
&lt;h2&gt;
  
  
  Tech Stack
&lt;/h2&gt;

&lt;p&gt;Posture+ is built using:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;React&lt;/li&gt;
&lt;li&gt;TypeScript&lt;/li&gt;
&lt;li&gt;MediaPipe&lt;/li&gt;
&lt;li&gt;Canvas API&lt;/li&gt;
&lt;li&gt;Picture-in-Picture API&lt;/li&gt;
&lt;/ul&gt;


&lt;h2&gt;
  
  
  GitHub
&lt;/h2&gt;

&lt;p&gt;You can explore the project here:&lt;/p&gt;

&lt;p&gt;

&lt;/p&gt;
&lt;div class="ltag-github-readme-tag"&gt;
  &lt;div class="readme-overview"&gt;
    &lt;h2&gt;
      &lt;img src="https://assets.dev.to/assets/github-logo-5a155e1f9a670af7944dd5e12375bc76ed542ea80224905ecaf878b9157cdefc.svg" alt="GitHub logo"&gt;
      &lt;a href="https://github.com/DarkBytezz" rel="noopener noreferrer"&gt;
        DarkBytezz
      &lt;/a&gt; / &lt;a href="https://github.com/DarkBytezz/PosturePlus" rel="noopener noreferrer"&gt;
        PosturePlus
      &lt;/a&gt;
    &lt;/h2&gt;
    &lt;h3&gt;
      First in the market, A full fledged real time temporal posture monitoring system
    &lt;/h3&gt;
  &lt;/div&gt;
  &lt;div class="ltag-github-body"&gt;
    
&lt;div id="readme" class="md"&gt;
&lt;div&gt;
&lt;a rel="noopener noreferrer nofollow" href="https://raw.githubusercontent.com/DarkBytezz/PosturePlus/main/apps/web/public/logo.png"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fraw.githubusercontent.com%2FDarkBytezz%2FPosturePlus%2Fmain%2Fapps%2Fweb%2Fpublic%2Flogo.png" width="100" alt="Posture+ Logo"&gt;&lt;/a&gt;
&lt;div class="markdown-heading"&gt;
&lt;h1 class="heading-element"&gt;Posture+&lt;/h1&gt;
&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Real-Time AI Posture Monitoring — No Wearables Required&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/DarkBytezz/PosturePlus/stargazers" rel="noopener noreferrer"&gt;&lt;img src="https://camo.githubusercontent.com/8e687fbd24a1c43e74ebad749c85a084b31c568f312c7f72489c9621978c9997/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f73746172732f4461726b427974657a7a2f506f7374757265506c75733f7374796c653d736f6369616c" alt="Stars"&gt;&lt;/a&gt;
&lt;a href="https://github.com/DarkBytezz/PosturePlus/forks" rel="noopener noreferrer"&gt;&lt;img src="https://camo.githubusercontent.com/2c23f7628ac18024a7f2e1f7d5d7b97aaec6e293bd0a1b1aa0090eccdc0d6bd8/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f666f726b732f4461726b427974657a7a2f506f7374757265506c75733f7374796c653d736f6369616c" alt="Forks"&gt;&lt;/a&gt;
&lt;a href="https://github.com/DarkBytezz/PosturePlus/issues" rel="noopener noreferrer"&gt;&lt;img src="https://camo.githubusercontent.com/c192b600fced97daebb332dc6c96d596d2d632584a7395658594f69c94e6067b/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6973737565732f4461726b427974657a7a2f506f7374757265506c7573" alt="Issues"&gt;&lt;/a&gt;
&lt;a href="https://github.com/DarkBytezz/PosturePlus/LICENSE" rel="noopener noreferrer"&gt;&lt;img src="https://camo.githubusercontent.com/d125afebd436efd223f4a0dbd29956785874e453708549ec8d89892c2239a842/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f4461726b427974657a7a2f506f7374757265506c7573" alt="License"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a rel="noopener noreferrer nofollow" href="https://camo.githubusercontent.com/b46bfccb78b3b4cd9b05aaf834f04a661af853e66dafff4cb9bfe11d685ee5b8/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f52656163742d31392d626c7565"&gt;&lt;img src="https://camo.githubusercontent.com/b46bfccb78b3b4cd9b05aaf834f04a661af853e66dafff4cb9bfe11d685ee5b8/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f52656163742d31392d626c7565" alt="React"&gt;&lt;/a&gt;
&lt;a rel="noopener noreferrer nofollow" href="https://camo.githubusercontent.com/990af05c083db3b919b708397720f6ce9dddc3cdbef7590ce9376a2a72650017/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f547970655363726970742d5374726963742d626c7565"&gt;&lt;img src="https://camo.githubusercontent.com/990af05c083db3b919b708397720f6ce9dddc3cdbef7590ce9376a2a72650017/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f547970655363726970742d5374726963742d626c7565" alt="TypeScript"&gt;&lt;/a&gt;
&lt;a rel="noopener noreferrer nofollow" href="https://camo.githubusercontent.com/a4cfd1e68c2555eab763d0eed3de24e77afe56c1f0eaad042f3f5738690c31e3/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f566974652d4c696768746e696e675f466173742d707572706c65"&gt;&lt;img src="https://camo.githubusercontent.com/a4cfd1e68c2555eab763d0eed3de24e77afe56c1f0eaad042f3f5738690c31e3/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f566974652d4c696768746e696e675f466173742d707572706c65" alt="Vite"&gt;&lt;/a&gt;
&lt;a rel="noopener noreferrer nofollow" href="https://camo.githubusercontent.com/0d2f639dad449525d100ad98f03ca8f1c9d217ad4dff3b4179e43a81d8b7f17e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4d65646961506970652d506f73652d677265656e"&gt;&lt;img src="https://camo.githubusercontent.com/0d2f639dad449525d100ad98f03ca8f1c9d217ad4dff3b4179e43a81d8b7f17e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4d65646961506970652d506f73652d677265656e" alt="MediaPipe"&gt;&lt;/a&gt;
&lt;a rel="noopener noreferrer nofollow" href="https://camo.githubusercontent.com/2da871de43c6950eebdc520fddc1907571f39df380f63330d9c5dcec0b4d2b2e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f417574682d53757061626173652d334543463845"&gt;&lt;img src="https://camo.githubusercontent.com/2da871de43c6950eebdc520fddc1907571f39df380f63330d9c5dcec0b4d2b2e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f417574682d53757061626173652d334543463845" alt="Supabase"&gt;&lt;/a&gt;
&lt;a rel="noopener noreferrer nofollow" href="https://camo.githubusercontent.com/a7ea63e7f0714e22f0926b65d7efd000d5845ff474c96b031b5ccef942d7cfd6/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4465706c6f792d56657263656c2d626c61636b"&gt;&lt;img src="https://camo.githubusercontent.com/a7ea63e7f0714e22f0926b65d7efd000d5845ff474c96b031b5ccef942d7cfd6/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4465706c6f792d56657263656c2d626c61636b" alt="Vercel"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;🌐 &lt;strong&gt;&lt;a href="https://posture-plus.vercel.app" rel="nofollow noopener noreferrer"&gt;posture-plus.vercel.app&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;/div&gt;

&lt;p&gt;Posture+ is a real-time posture monitoring system that runs entirely in your browser using your webcam. It detects posture instability through &lt;strong&gt;temporal analysis&lt;/strong&gt; — identifying sustained slouch patterns rather than momentary dips.&lt;/p&gt;
&lt;p&gt;No wearables. No sensors. No recordings. Just your laptop camera and five seconds to calibrate.&lt;/p&gt;

&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;Why Posture+&lt;/h2&gt;
&lt;/div&gt;
&lt;p&gt;Most posture tools work like this:&lt;/p&gt;
&lt;div class="highlight highlight-source-python notranslate position-relative overflow-auto js-code-highlight"&gt;
&lt;pre&gt;&lt;span class="pl-k"&gt;if&lt;/span&gt; &lt;span class="pl-s1"&gt;shoulder_angle&lt;/span&gt; &lt;span class="pl-c1"&gt;&amp;gt;&lt;/span&gt; &lt;span class="pl-s1"&gt;threshold&lt;/span&gt;:
    &lt;span class="pl-en"&gt;alert&lt;/span&gt;()&lt;/pre&gt;

&lt;/div&gt;
&lt;p&gt;This misses the point. A single bad frame doesn't mean bad posture. Posture+ instead evaluates &lt;strong&gt;how posture behaves over time&lt;/strong&gt;, detecting:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Sustained forward head posture&lt;/li&gt;
&lt;li&gt;Lateral head tilt&lt;/li&gt;
&lt;li&gt;Shoulder imbalance&lt;/li&gt;
&lt;li&gt;Posture fatigue during long sessions&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Alerts only fire when instability is genuinely sustained — not on random dips.&lt;/p&gt;

&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;Research Context&lt;/h2&gt;

&lt;/div&gt;
&lt;p&gt;Posture+ is built on a research framework developed for real-time posture stability analysis. The work has been &lt;strong&gt;accepted for presentation at IEEE CSPA 2026&lt;/strong&gt;, modeling…&lt;/p&gt;
&lt;/div&gt;
  &lt;/div&gt;
  &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/DarkBytezz/PosturePlus" rel="noopener noreferrer"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
&lt;/div&gt;




&lt;p&gt;If you're building real-time applications in the browser, I'm curious how others deal with background throttling.&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>ai</category>
      <category>javascript</category>
      <category>computervision</category>
    </item>
  </channel>
</rss>
