5#include "flint/math/types.h"
35 void update(
float smoothing = 0.25f);
66 float smoothing = 0.2f);
79 void follow(
float targetX,
float targetY);
81 void updateViewRect();
void setViewSize(Vec2f size)
void setTargetCenter(Vec2f center)
Soft‑lock camera centre on a target (uses current smoothing).
void update(float smoothing=0.25f)
Adjust smoothing factor (lerp) used by future setTargetCenter.
FloatRect getViewRect() const
void setWorldSize(Vec2f size)
void followClamped(const Vec2f &targetPos, const Vec2i &bufferSize, const Vec2i &mapPixelSize, float smoothing=0.2f)
Follow a target but clamp so that the view never leaves map.
Vec2f screenToWorld(const Vec2f &sp, const Vec2i &screen) const
Transform screen‑space point back to world‑space.