HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
TsLoopParams Class Reference

#include <types.h>

Public Member Functions

TS_API bool operator== (const TsLoopParams &other) const
 
TS_API bool operator!= (const TsLoopParams &other) const
 
TS_API GfInterval GetPrototypeInterval () const
 Returns the prototype region, [protoStart, protoEnd). More...
 
TS_API GfInterval GetLoopedInterval () const
 Returns the union of the prototype region and the echo region(s). More...
 

Public Attributes

TsTime protoStart = 0.0
 
TsTime protoEnd = 0.0
 
int32_t numPreLoops = 0
 
int32_t numPostLoops = 0
 
double valueOffset = 0.0
 

Detailed Description

Inner-loop parameters.

At most one inner-loop region can be specified per spline. Only whole numbers of pre- and post-iterations are supported.

The value offset specifies the difference between the values at the starts of consecutive iterations.

There must always be a knot at the protoStart time; otherwise the loop parameters are invalid and will be ignored.

A copy of the start knot is always made at the end of the prototype region. This is true even if there is no post-looping; it ensures that all iterations (including pre-loops) match the prototype region exactly.

Enabling inner looping will generally change the shape of the prototype interval (and thus all looped copies), because the first knot is echoed as the last. Inner looping does not aim to make copies of an existing shape; it aims to set up for continuity at loop joins.

When inner looping is applied, any knots specified in the pre-looped or post-looped intervals are removed from consideration, though they remain in the spline parameters. A knot exactly at the end of the prototype interval is not part of the prototype; it will be ignored, and overwritten by the start-knot copy.

When protoEnd <= protoStart, inner looping is disabled.

Negative numbers of loops are not meaningful; they are treated the same as zero counts. These quantities are signed only so that accidental underflow does not result in huge loop counts.

Definition at line 162 of file types.h.

Member Function Documentation

TS_API GfInterval TsLoopParams::GetLoopedInterval ( ) const

Returns the union of the prototype region and the echo region(s).

TS_API GfInterval TsLoopParams::GetPrototypeInterval ( ) const

Returns the prototype region, [protoStart, protoEnd).

TS_API bool TsLoopParams::operator!= ( const TsLoopParams other) const
TS_API bool TsLoopParams::operator== ( const TsLoopParams other) const

Member Data Documentation

int32_t TsLoopParams::numPostLoops = 0

Definition at line 168 of file types.h.

int32_t TsLoopParams::numPreLoops = 0

Definition at line 167 of file types.h.

TsTime TsLoopParams::protoEnd = 0.0

Definition at line 166 of file types.h.

TsTime TsLoopParams::protoStart = 0.0

Definition at line 165 of file types.h.

double TsLoopParams::valueOffset = 0.0

Definition at line 169 of file types.h.


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