[RFC,1/3] controls: Add FrameWallClock and FrameWallClockRaw controls
diff mbox series

Message ID 20241126121706.4350-2-david.plowman@raspberrypi.com
State New
Headers show
Series
  • Frame wallclock timestamps and metadata
Related show

Commit Message

David Plowman Nov. 26, 2024, 12:17 p.m. UTC
We add FrameWallClockRaw, a direct "raw" measurement of the wall clock
timestamp for the frame, and FrameWallClock, for a smoothed
(de-jittered) version of the same number.

Signed-off-by: David Plowman <david.plowman@raspberrypi.com>
---
 src/libcamera/control_ids_core.yaml | 29 +++++++++++++++++++++++++++++
 1 file changed, 29 insertions(+)

Patch
diff mbox series

diff --git a/src/libcamera/control_ids_core.yaml b/src/libcamera/control_ids_core.yaml
index d34a2d06..7cf0f481 100644
--- a/src/libcamera/control_ids_core.yaml
+++ b/src/libcamera/control_ids_core.yaml
@@ -973,4 +973,33 @@  controls:
       description: |
         Enable or disable the debug metadata.
 
+  - FrameWallClockRaw:
+      type: int64_t
+      description: |
+        The time in microseconds since the system clock's epoch.
+
+        This is a direct measurement of the number of microseconds since the
+        system clock's epoch. Because of the way it is sampled, this value is
+        likely to be subject to significant amounts of system and system
+        load-dependent jitter, typically of many milliseconds in duration.
+
+        For a smoothed version of this timestamp, use the FramwWallClock
+        control.
+
+        \sa FrameWallClock
+
+        The FrameWallClockRaw control can only be returned in metadata.
+
+  - FrameWallClock:
+      type: int64_t
+      description: |
+        The time in microseconds since the system clock's epoch.
+
+        This is a smoothed version of the FrameWallClockRaw timestamp, which
+        should show much reduced amounts of jitter.
+
+        \sa FrameWallClockRaw
+
+        The FrameWallClock control can only be returned in metadata.
+
 ...