esp32cam-rtsp icon indicating copy to clipboard operation
esp32cam-rtsp copied to clipboard

Feature request, clock overlay

Open rubin110 opened this issue 3 months ago • 1 comments

It would be great if there was a clock overlay on the video stream, though I'm pretty sure that's impossible due to how limited the platform is. Also I imagine you'll need to include some NTP client to grab the time. Anyhow, figured it couldn't hurt to ask. Thanks!

rubin110 avatar Mar 16 '24 20:03 rubin110

Hi Rubin,

Sure does not hurt to ask!

RTSP has the provision to include a timestamp in the stream. See CStreamer.cpp

    RtpBuf[8] = (m_Timestamp & 0xFF000000) >> 24; // each image gets a timestamp
    RtpBuf[9] = (m_Timestamp & 0x00FF0000) >> 16;
    RtpBuf[10] = (m_Timestamp & 0x0000FF00) >> 8;
    RtpBuf[11] = (m_Timestamp & 0x000000FF);

Not exactly clear how this is used right now. Seems to start at 0 and updated based on the fps.

This could be used to generate some overlay (lateron) but will require a dependency on NTP...

An overlay is really out of scope because the esp32 is already at the max of CPU power for processing and sending images. However, will take a look at the possibility to include a valid/NTP timestamp!

rzeldent avatar Mar 17 '24 10:03 rzeldent