melodic-orange-92161
03/02/2026, 8:52 PMtall-airline-16756
03/02/2026, 8:52 PMtall-airline-16756
03/02/2026, 8:53 PMstartedAt, endedAt, createdAt from egress/webhook events) to compute the correct time for each frame or to stamp a single capture time.
• FFmpeg examples can add a static timestamp or a running clock; I can provide exact FFmpeg commands if you want to go this route.
Questions to help me give exact steps
• Do you need a running clock (updated every frame) visible during the whole recording, or just a single timestamp (e.g., recording start time) in a corner?
• Do you prefer the timestamp to be in local time or UTC?
• Are you planning to use LiveKit’s Universal Egress/browser compositor or do you want a post-processing pipeline (FFmpeg)?
• If post-processing, which OS or environment will run the FFmpeg job (Linux, macOS, serverless, etc.)?
If you tell me which option you prefer and answer those questions, I’ll give a step-by-step example (including a sample HTML overlay for the compositor or an FFmpeg command to burn timestamps into the video).
Sources: Backup Egress Recordings | Universal Egress | Universal Egressmelodic-orange-92161
03/02/2026, 8:54 PMtall-airline-16756
03/02/2026, 8:54 PMclock_overlay.html.
<!doctype html>
<html>
<head>
<meta charset="utf-8" />
<style>
html,body { margin:0; padding:0; width:100%; height:100%; background:transparent; overflow:hidden; }
#clock {
position: absolute;
right: 16px;
bottom: 16px;
padding: 6px 10px;
background: rgba(0,0,0,0.5);
color: #fff;
font-family: Arial, sans-serif;
font-size: 18px;
border-radius: 6px;
backdrop-filter: blur(2px);
}
</style>
</head>
<body>
<div id="clock">—</div>
<script>
function pad(n){ return n < 10 ? '0'+n : n; }
function updateClock(){
const d = new Date();
// Example format: 2026-03-02 14:05:07
const ts = d.getFullYear() + '-' + pad(d.getMonth()+1) + '-' + pad(d.getDate())
+ ' ' + pad(d.getHours()) + ':' + pad(d.getMinutes()) + ':' + pad(d.getSeconds());
document.getElementById('clock').textContent = ts;
}
updateClock();
setInterval(updateClock, 1000);
</script>
</body>
</html>
Notes about the page
• Background is transparent so the compositor can overlay it on top of the video.
• You can adjust font, size, position, color, and opacity.
• If you want local timezone, the page uses the compositor environment’s timezone (usually UTC on server environments) — you can convert or format time as needed in JavaScript.
How to use this with the browser compositor
1. Host the HTML page where the compositor can load it (static file server or embed it in the compositor instance).
2. Configure your egress compositor to include this page as an overlay layer. The compositor should render the meeting/video plus this page on top.
3. When you start egress, the compositor will record the combined output with the running clock baked in.
Alternative: pass timestamps from the server
• If you prefer the server to drive the clock (e.g., to ensure a specific timezone or sync with startedAt), the compositor page can accept query params or a small JSON payload from your egress job and render based on that. Example: load clock_overlay.html?tz=America/Los_Angeles and use Intl APIs to render in that timezone.
Post-processing fallback
• If you cannot use a compositor, you can achieve a running clock with FFmpeg post-processing, but that adds complexity for perfectly syncing a running clock with the original frames. The compositor approach is simpler and ensures the timestamp matches the recorded frames.
Questions to make this exact for you
• Are you using LiveKit’s Universal Egress/browser compositor or another egress workflow? (If unclear, tell me how you currently start egress.)
• Do you want timezone conversion (local vs UTC) or any specific timestamp format?
• Where would you host the overlay page (public URL, packaged with the compositor, or served from your app)?
• Do you want the clock visible for the entire recording or only during certain segments?
If you confirm those details, I’ll provide:
• A ready-to-use overlay page that uses a specific timezone or format you want.
• Example compositor layout configuration (placement and sizing).
• If needed, an FFmpeg fallback command for post-processing.
Would you like the overlay formatted for a particular timezone or style (e.g., larger, different corner, 12-hour clock with AM/PM)?