group2 0.1.0
CSE 125 Group 2
Loading...
Searching...
No Matches
EntityInterpolation.cpp File Reference

Implementation of append + bracket-search sampling for InterpolationBuffer. More...

#include "EntityInterpolation.hpp"
#include "ecs/components/InterpolationBuffer.hpp"
#include <cstddef>
#include <entt/entt.hpp>
#include <glm/common.hpp>
#include <glm/gtc/constants.hpp>
Include dependency graph for EntityInterpolation.cpp:

Namespaces

namespace  entity_interpolation

Functions

void entity_interpolation::appendSample (entt::registry &registry, entt::entity e, Uint64 captureNs, const SampleInputs &inputs)
 Append a snapshot sample at captureNs into the entity's InterpolationBuffer, creating the component on first call.
InterpolatedTransform entity_interpolation::sample (const entt::registry &registry, entt::entity e, Uint64 renderTimeNs, const glm::vec3 &fallbackPos, float fallbackYaw)
 Look up e's interpolated transform at renderTimeNs.

Detailed Description

Implementation of append + bracket-search sampling for InterpolationBuffer.