Phosphor
Qt6 / Wayland library suite for window-management tools
 
Loading...
Searching...
No Matches
Interpolate.h File Reference
#include <PhosphorAnimation/phosphoranimation_export.h>
#include <QColor>
#include <QLineF>
#include <QPointF>
#include <QRectF>
#include <QSizeF>
#include <QTransform>
#include <QtGlobal>
#include <QtMath>
#include <cmath>
#include <concepts>
#include <type_traits>

Go to the source code of this file.

Classes

struct  PhosphorAnimation::Interpolate< qreal >
 
struct  PhosphorAnimation::Interpolate< QPointF >
 
struct  PhosphorAnimation::Interpolate< QSizeF >
 
struct  PhosphorAnimation::Interpolate< QRectF >
 
struct  PhosphorAnimation::detail::OkLab
 
struct  PhosphorAnimation::Interpolate< QColor >
 
struct  PhosphorAnimation::detail::DecomposedTransform
 
struct  PhosphorAnimation::Interpolate< QTransform >
 

Namespaces

namespace  PhosphorAnimation
 
namespace  PhosphorAnimation::detail
 

Concepts

concept  PhosphorAnimation::detail::PositionalGeometric
 Position-carrying T whose damage region is fully determined by endpoints + overshoot.
 
concept  PhosphorAnimation::detail::SizeGeometric
 Size-only T — caller must supply an anchor for damage rect.
 
concept  PhosphorAnimation::detail::ScalarValue
 

Enumerations

enum class  PhosphorAnimation::ColorSpace { PhosphorAnimation::Linear , PhosphorAnimation::OkLab }
 Interpolation space selector for AnimatedValue<QColor, ...>. More...
 

Functions

qreal PhosphorAnimation::detail::srgbToLinear (qreal c)
 
qreal PhosphorAnimation::detail::linearToSrgb (qreal c)
 
QColor PhosphorAnimation::detail::lerpColorLinear (const QColor &from, const QColor &to, qreal t)
 
OkLab PhosphorAnimation::detail::linearToOkLab (qreal r, qreal g, qreal bv)
 
void PhosphorAnimation::detail::okLabToLinear (const OkLab &lab, qreal &r, qreal &g, qreal &bv)
 
QColor PhosphorAnimation::detail::lerpColorOkLab (const QColor &from, const QColor &to, qreal t)
 
qreal PhosphorAnimation::detail::colorDistance (const QColor &from, const QColor &to)
 L2 norm in linear-RGB space — matches the lerp space so velocity rescale uses a consistent metric.
 
DecomposedTransform PhosphorAnimation::detail::decomposeTransform (const QTransform &t)
 QR-style decomposition on the 2x2 linear part under Qt's post-multiply row-vector convention: M = R x K x S.
 
QTransform PhosphorAnimation::detail::recomposeTransform (const DecomposedTransform &d)
 
bool PhosphorAnimation::detail::isPureTranslate (const QTransform &t)
 True if the 2x2 linear part is identity (only translation present).
 
QTransform PhosphorAnimation::detail::lerpTransform (const QTransform &from, const QTransform &to, qreal t)
 

Variables

constexpr qreal PhosphorAnimation::kRectSizeEpsilonPx = 1.0
 Sub-pixel epsilon for rect size-change detection.