TSDuck v3.45-4787
MPEG Transport Stream Toolkit
Loading...
Searching...
No Matches
ts::TimeSourceSuperTraits< T, typename std::enable_if< T==TimeSource::PCR||T==TimeSource::OPCR >::type > Class Template Reference

TimeSourceSuperTraits specialization for PCR and OPCR. More...

#include <tsTS.h>

Static Public Attributes

static constexpr size_t BIT_SIZE = 42
 Size in bits of the time source.
 
static constexpr uint64_t SCALE = TimeSourceSuperTraits<TimeSource::PTS>::SCALE * (TICKS / TimeSourceSuperTraits<TimeSource::PTS>::TICKS)
 Scale factor for the modular time source.
 
static constexpr uint64_t TICKS = 27'000'000
 Clock frequency in Hz for PCR.
 

Detailed Description

template<TimeSource T>
class ts::TimeSourceSuperTraits< T, typename std::enable_if< T==TimeSource::PCR||T==TimeSource::OPCR >::type >

TimeSourceSuperTraits specialization for PCR and OPCR.

There is no BIT_MASK.

Member Data Documentation

◆ BIT_SIZE

template<TimeSource T>
constexpr size_t ts::TimeSourceSuperTraits< T, typename std::enable_if< T==TimeSource::PCR||T==TimeSource::OPCR >::type >::BIT_SIZE = 42
staticconstexpr

Size in bits of the time source.

Warning: A PCR value is not a linear value mod 2^42. It is split into PCR_base and PCR_ext (see ISO 13818-1, 2.4.2.2).

◆ SCALE

template<TimeSource T>
constexpr uint64_t ts::TimeSourceSuperTraits< T, typename std::enable_if< T==TimeSource::PCR||T==TimeSource::OPCR >::type >::SCALE = TimeSourceSuperTraits<TimeSource::PTS>::SCALE * (TICKS / TimeSourceSuperTraits<TimeSource::PTS>::TICKS)
staticconstexpr

Scale factor for the modular time source.

For PCR, this is not a power of 2, it does not wrap up at a number of bits. The PCR_base part is equivalent to a PTS/DTS and wraps up at 2**33. The PCR_ext part is a mod 300 value. Note that, since this not a power of 2, there is no possible PCR_MASK value.


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