Quantum 3 3.0.13

Public Member Functions | List of all members
Quantum.QuantumSnapshotInterpolationTimer.InterpolationBuffer< T > Class Template Reference

Simple ring buffer to store transform data. More...

Public Member Functions

 InterpolationBuffer (int size)
 Create the collection with a given capacity. More...
 
void Add (T t, int tick)
 Add a new item to the collection. More...
 
void Reset ()
 Reset the collection. More...
 
bool TryGet (out T t, int tick)
 Try get a value from the collection for the given frame number. More...
 

Detailed Description

Simple ring buffer to store transform data.

Template Parameters
TType of data to store

Constructor & Destructor Documentation

◆ InterpolationBuffer()

Create the collection with a given capacity.

Parameters
sizeCapacity

Member Function Documentation

◆ Reset()

Reset the collection.

◆ Add()

void Quantum.QuantumSnapshotInterpolationTimer.InterpolationBuffer< T >.Add ( t,
int  tick 
)
inline

Add a new item to the collection.

Parameters
tThe object
tickThe frame number

◆ TryGet()

bool Quantum.QuantumSnapshotInterpolationTimer.InterpolationBuffer< T >.TryGet ( out T  t,
int  tick 
)
inline

Try get a value from the collection for the given frame number.

Parameters
tResulting object
tickRequested frame number
Returns
True if an object with that frame number was found