Donner SVG Editor & Engine
SVG-native editor and embeddable SVG2 + CSS3 engine in C++20, with GPU (WebGPU) and compact CPU renderers, built for correctness, security, and performance.
Loading...
Searching...
No Matches
donner::svg::components::ClockValue Class Reference

Represents a SMIL clock value, which can be a concrete time in seconds or indefinite. More...

#include "donner/svg/components/animation/ClockValue.h"

Public Member Functions

constexpr ClockValue ()=default
 Default constructor creates a zero clock value.
constexpr double seconds () const
 Returns the time in seconds. Returns infinity for indefinite.
constexpr bool isIndefinite () const
 Returns true if this clock value is indefinite.
constexpr bool operator== (const ClockValue &) const =default
 Equality comparison.
constexpr auto operator<=> (const ClockValue &) const =default
 Ordering comparison.

Static Public Member Functions

static constexpr ClockValue Seconds (double seconds)
 Create a ClockValue representing a specific time in seconds.
static constexpr ClockValue Indefinite ()
 Create a ClockValue representing indefinite.

Friends

std::ostream & operator<< (std::ostream &os, const ClockValue &cv)
 Stream output for debugging.

Detailed Description

Represents a SMIL clock value, which can be a concrete time in seconds or indefinite.

Clock values are used in SVG animation timing attributes like begin, dur, and end. Supported formats: HH:MM:SS.frac, MM:SS.frac, <number><metric> (h/min/s/ms). Default metric is seconds.


The documentation for this class was generated from the following file: