6#include <PhosphorPointer/phosphorpointer_export.h>
229 return !(*
this == other);
251 bool isUser =
false);
281 [[nodiscard]]
double resolvedParam(
const QString& paramId,
const QVariantMap& params,
double fallback)
const;
Q_DECLARE_TYPEINFO(PhosphorPointerShaders::PointerShaderEffect::TextureSlot, Q_RELOCATABLE_TYPE)
Definition PointerFrameState.h:16
constexpr double kMaxBufferScale
Definition CustomParamsKey.h:37
constexpr double kMinBufferScale
Lower / upper bounds on a multipass bufferScale (FBO downscale factor).
Definition CustomParamsKey.h:36
QMap< QString, QVariantMap > PackPresets
Pack-declared named parameter presets: preset name → { paramId → value }.
Definition ShaderPresetParse.h:32
Declared parameter.
Definition PointerShaderEffect.h:203
QVariant stepValue
Definition PointerShaderEffect.h:212
QString id
Definition PointerShaderEffect.h:204
QString group
Definition PointerShaderEffect.h:208
QString type
"float", "int", "bool", "color"
Definition PointerShaderEffect.h:206
QString name
Definition PointerShaderEffect.h:205
QString description
Definition PointerShaderEffect.h:207
QVariant maxValue
Definition PointerShaderEffect.h:211
QVariant minValue
Definition PointerShaderEffect.h:210
QVariant defaultValue
Definition PointerShaderEffect.h:209
User texture slot.
Definition PointerShaderEffect.h:219
QString path
Definition PointerShaderEffect.h:220
bool operator!=(const TextureSlot &other) const
Definition PointerShaderEffect.h:227
QString wrap
Definition PointerShaderEffect.h:221
bool operator==(const TextureSlot &other) const
Definition PointerShaderEffect.h:223
Metadata for a single pointer shader effect.
Definition PointerShaderEffect.h:50
bool isUserEffect
Whether this pack was loaded from the user-local directory.
Definition PointerShaderEffect.h:101
QString id
Stable identifier, the registry lookup key.
Definition PointerShaderEffect.h:71
PhosphorShaders::PackPresets presets
Pack-declared named parameter presets: preset name -> { paramId -> value }.
Definition PointerShaderEffect.h:243
double resolvedReach(const QVariantMap ¶ms) const
The pack's reach in logical px for the given friendly parameter map: the reachParam value when declar...
bool isMultipass
Opt-in multipass.
Definition PointerShaderEffect.h:172
static QString layerToken(Layer layer)
The metadata spelling of layer, the inverse of what fromJson parses.
QString reachParam
Optional name of an int/float parameter whose resolved value replaces reach (same idea as the surface...
Definition PointerShaderEffect.h:116
static constexpr double kMaxReach
Definition PointerShaderEffect.h:196
QList< TextureSlot > textures
Definition PointerShaderEffect.h:232
double resolvedTrailWindow(const QVariantMap ¶ms) const
How far back this pack reads the trail, in seconds, for the given friendly parameter map: the trailWi...
Layer layer
Paint layer relative to the cursor. Default Below.
Definition PointerShaderEffect.h:107
bool isValid() const
Definition PointerShaderEffect.h:253
QString author
Author attribution.
Definition PointerShaderEffect.h:80
QString vertexShaderPath
Optional vertex shader path (same resolution rules).
Definition PointerShaderEffect.h:95
double reach
How far, in logical px, from any trail point or press point the pack may paint.
Definition PointerShaderEffect.h:112
bool needsCursor
Bind the cursor sprite as uCursorSprite. Default false.
Definition PointerShaderEffect.h:168
static constexpr double kMinBufferScale
Definition PointerShaderEffect.h:186
QString sourceDir
Resolved absolute directory containing this pack's assets.
Definition PointerShaderEffect.h:98
QString description
One-line description for settings UI.
Definition PointerShaderEffect.h:77
static constexpr double kMinReach
Bounds on resolvedReach, in logical px.
Definition PointerShaderEffect.h:195
QList< ParameterInfo > parameters
Definition PointerShaderEffect.h:214
static PointerShaderEffect fromJson(const QJsonObject &obj, const QString &sourceDir=QString(), bool isUser=false)
Parse a pack's metadata.json root.
Layer
Where the chain paints relative to the cursor.
Definition PointerShaderEffect.h:52
@ Below
The chain paints under KWin's cursor (or the hardware cursor plane) and never touches cursor visibili...
Definition PointerShaderEffect.h:55
double trailWindowSeconds
How far back, in seconds, the pack's stages actually READ the trail.
Definition PointerShaderEffect.h:155
QString fragmentShaderPath
Fragment shader path.
Definition PointerShaderEffect.h:91
QString category
Category for settings-UI grouping ("Trail", "Glow", "Click", ...).
Definition PointerShaderEffect.h:86
QString previewPath
Preview image path (absolute once resolved). Empty when none.
Definition PointerShaderEffect.h:104
bool bufferFeedback
Last frame's buffer is sampleable as iChannel<N>.
Definition PointerShaderEffect.h:180
QString trailWindowParam
Optional name of an int/float parameter whose resolved value replaces trailWindowSeconds,...
Definition PointerShaderEffect.h:165
QString version
Semantic version of this pack.
Definition PointerShaderEffect.h:83
QStringList bufferShaderPaths
Buffer-pass shader paths (max kMaxBufferPasses), resolved like fragmentShaderPath.
Definition PointerShaderEffect.h:176
double bufferScale
Render-target scale relative to the canvas, clamped to [kMinBufferScale, kMaxBufferScale] at parse ti...
Definition PointerShaderEffect.h:184
static constexpr double kMaxBufferScale
Definition PointerShaderEffect.h:187
bool samplesTrail
Whether any of the pack's stages actually reads uPointerTrail.
Definition PointerShaderEffect.h:141
double trailSeconds
How long, in seconds, after the last motion or button event the pack still needs frames.
Definition PointerShaderEffect.h:124
QString name
Human-readable display name.
Definition PointerShaderEffect.h:74