HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Alembic::AbcCoreAbstract::ALEMBIC_VERSION_NS::TimeSamplingType Class Reference

#include <TimeSamplingType.h>

Public Types

enum  AcyclicFlag { kAcyclic }
 

Public Member Functions

 TimeSamplingType ()
 Uniform default. More...
 
 TimeSamplingType (chrono_t iTimePerCycle)
 
 TimeSamplingType (uint32_t iNumSamplesPerCycle, chrono_t iTimePerCycle)
 
 TimeSamplingType (AcyclicFlag)
 
bool operator== (const TimeSamplingType &iRhs) const
 
bool isUniform () const
 
bool isCyclic () const
 
bool isAcyclic () const
 
uint32_t getNumSamplesPerCycle () const
 
chrono_t getTimePerCycle () const
 

Static Public Member Functions

static uint32_t AcyclicNumSamples ()
 
static chrono_t AcyclicTimePerCycle ()
 

Friends

ALEMBIC_EXPORT friend
std::ostream & 
operator<< (std::ostream &ostr, const TimeSamplingType &tst)
 

Detailed Description

The TimeSamplingType class controls how properties in Alembic relate time values to their sample indices.

The default behavior is where there is a time value associated with sample zero, and a uniform time amount between each subsequent sample. This is called "Uniform" time sampling, and would correspond to sampling every frame at 1/24 per second, or similar.

The second behavior is where there is a period of time over which a fixed number of samples are distributed unevenly - imagine a render scene sampled across a shutter period at shutter-begin-open, shutter-full-open, shutter-begin-close, shutter-full-close. This is (perhaps confusingly) called "Cyclic" time sampling.

The final behavior is where the time samples are totally uneven. We make a restriction that they must be strictly increasing, as the indices are increasing. This is so we can bisection search to find the lower or upper bounds when searching for floor, ceiling, or nearest samples by comparing time. This is called "Acyclic" time sampling.

Definition at line 68 of file TimeSamplingType.h.

Member Enumeration Documentation

ACYCLIC This enum exists solely as a way of distinguishing between the argument-less static time sampling, and the argument-less acyclic time sampling.

Enumerator
kAcyclic 

Definition at line 123 of file TimeSamplingType.h.

Constructor & Destructor Documentation

Alembic::AbcCoreAbstract::ALEMBIC_VERSION_NS::TimeSamplingType::TimeSamplingType ( )
inline

Uniform default.

Definition at line 77 of file TimeSamplingType.h.

Alembic::AbcCoreAbstract::ALEMBIC_VERSION_NS::TimeSamplingType::TimeSamplingType ( chrono_t  iTimePerCycle)
inlineexplicit

UNIFORM ...

Definition at line 83 of file TimeSamplingType.h.

Alembic::AbcCoreAbstract::ALEMBIC_VERSION_NS::TimeSamplingType::TimeSamplingType ( uint32_t  iNumSamplesPerCycle,
chrono_t  iTimePerCycle 
)
inline

CYCLIC ...

Definition at line 95 of file TimeSamplingType.h.

Alembic::AbcCoreAbstract::ALEMBIC_VERSION_NS::TimeSamplingType::TimeSamplingType ( AcyclicFlag  )
inlineexplicit

Definition at line 124 of file TimeSamplingType.h.

Member Function Documentation

static uint32_t Alembic::AbcCoreAbstract::ALEMBIC_VERSION_NS::TimeSamplingType::AcyclicNumSamples ( )
static
static chrono_t Alembic::AbcCoreAbstract::ALEMBIC_VERSION_NS::TimeSamplingType::AcyclicTimePerCycle ( )
static
uint32_t Alembic::AbcCoreAbstract::ALEMBIC_VERSION_NS::TimeSamplingType::getNumSamplesPerCycle ( ) const
inline

Definition at line 148 of file TimeSamplingType.h.

chrono_t Alembic::AbcCoreAbstract::ALEMBIC_VERSION_NS::TimeSamplingType::getTimePerCycle ( ) const
inline

Definition at line 150 of file TimeSamplingType.h.

bool Alembic::AbcCoreAbstract::ALEMBIC_VERSION_NS::TimeSamplingType::isAcyclic ( ) const
inline

Definition at line 145 of file TimeSamplingType.h.

bool Alembic::AbcCoreAbstract::ALEMBIC_VERSION_NS::TimeSamplingType::isCyclic ( ) const
inline

Definition at line 140 of file TimeSamplingType.h.

bool Alembic::AbcCoreAbstract::ALEMBIC_VERSION_NS::TimeSamplingType::isUniform ( ) const
inline

Asks if the sampling is: Uniform (1 sample per cycle) Cyclic (N>1 samples per cycle) Acyclic (INF samples per cycle - acyclic!)

Definition at line 139 of file TimeSamplingType.h.

bool Alembic::AbcCoreAbstract::ALEMBIC_VERSION_NS::TimeSamplingType::operator== ( const TimeSamplingType iRhs) const

Using Default Copy Constructor Using Default Assignment Operator

Friends And Related Function Documentation

ALEMBIC_EXPORT friend std::ostream& operator<< ( std::ostream &  ostr,
const TimeSamplingType tst 
)
friend

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