Alembic: Alembic::AbcCoreAbstract::ALEMBIC_VERSION_NS::TimeSamplingType Class Reference

Alembic 1.8.11

Loading...
Searching...
No Matches
Alembic::AbcCoreAbstract::ALEMBIC_VERSION_NS::TimeSamplingType Class Reference

`#include <TimeSamplingType.h>`

## Public Types
enum | AcyclicFlag { kAcyclic }

## Public Member Functions
| TimeSamplingType ()
| Uniform default.
| 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)
| Prints out relevant information about the TimeSamplingType instance.

## 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.

## Member Enumeration Documentation

## ◆ AcyclicFlag

enum Alembic::AbcCoreAbstract::ALEMBIC_VERSION_NS::TimeSamplingType::AcyclicFlag

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

## Constructor & Destructor Documentation

## ◆ TimeSamplingType() [1/2]

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

UNIFORM ...

## ◆ TimeSamplingType() [2/2]

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

CYCLIC ...

## Member Function Documentation

## ◆ isUniform()

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!)

## ◆ operator==()

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

Using Default Copy Constructor Using Default Assignment Operator

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

- AbcCoreAbstract/TimeSamplingType.h
- AbcCoreAbstract/TimeSamplingType.cpp