Foray Library
rapid prototyping framework for crossplatform development of vulkan hardware ray tracing applications
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | Public Attributes | Protected Member Functions | List of all members
foray::scene::AnimationSampler Struct Reference

A collection of keyframes. More...

#include <foray_animation.hpp>

Public Member Functions

glm::vec3 SampleVec (float time) const
 Get an interpolated sample.
 
glm::quat SampleQuat (float time) const
 Get an interpolated sample.
 

Static Public Member Functions

static glm::vec4 InterpolateStep (float time, const AnimationKeyframe *lower, const AnimationKeyframe *upper)
 
static glm::vec4 InterpolateLinear (float time, const AnimationKeyframe *lower, const AnimationKeyframe *upper)
 
static glm::quat InterpolateLinearQuat (float time, const AnimationKeyframe *lower, const AnimationKeyframe *upper)
 
static glm::vec4 InterpolateCubicSpline (float time, const AnimationKeyframe *lower, const AnimationKeyframe *upper)
 
static glm::quat ReinterpreteAsQuat (glm::vec4)
 

Public Attributes

EAnimationInterpolation Interpolation = {}
 
std::vector< AnimationKeyframeKeyframes = {}
 

Protected Member Functions

void SelectKeyframe (float time, const AnimationKeyframe *&lower, const AnimationKeyframe *&upper) const
 

Detailed Description

A collection of keyframes.

Member Function Documentation

◆ InterpolateCubicSpline()

static glm::vec4 foray::scene::AnimationSampler::InterpolateCubicSpline ( float  time,
const AnimationKeyframe lower,
const AnimationKeyframe upper 
)
static

◆ InterpolateLinear()

static glm::vec4 foray::scene::AnimationSampler::InterpolateLinear ( float  time,
const AnimationKeyframe lower,
const AnimationKeyframe upper 
)
static

◆ InterpolateLinearQuat()

static glm::quat foray::scene::AnimationSampler::InterpolateLinearQuat ( float  time,
const AnimationKeyframe lower,
const AnimationKeyframe upper 
)
static

◆ InterpolateStep()

static glm::vec4 foray::scene::AnimationSampler::InterpolateStep ( float  time,
const AnimationKeyframe lower,
const AnimationKeyframe upper 
)
static

◆ ReinterpreteAsQuat()

static glm::quat foray::scene::AnimationSampler::ReinterpreteAsQuat ( glm::vec4  )
static

◆ SampleQuat()

glm::quat foray::scene::AnimationSampler::SampleQuat ( float  time) const

Get an interpolated sample.

Parameters
timeTimepoint
Returns
Rotation quaternion

◆ SampleVec()

glm::vec3 foray::scene::AnimationSampler::SampleVec ( float  time) const

Get an interpolated sample.

Parameters
timeTimepoint
Returns
Translation or Scale vector

◆ SelectKeyframe()

void foray::scene::AnimationSampler::SelectKeyframe ( float  time,
const AnimationKeyframe *&  lower,
const AnimationKeyframe *&  upper 
) const
protected

Member Data Documentation

◆ Interpolation

EAnimationInterpolation foray::scene::AnimationSampler::Interpolation = {}

◆ Keyframes

std::vector<AnimationKeyframe> foray::scene::AnimationSampler::Keyframes = {}

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