Effects
Effects apply shader-based visuals to the whole chart over a time range, for looks that are hard or impossible with normal chart events. prpr includes several built-in shaders; you can also write your own (see Custom shaders).
Format
Add an effects array to extra.json. Each element is an Effect:
Effect
{
"start": [0, 0, 1],
"end": [0, 0, 1],
"shader": "shader name",
"global": false,
"vars": {
...
}
}start and end are the effect start and end time in the same format as RPE ([bar, numerator, denominator]).
shader is the shader name (built-in or custom).
global controls whether the effect affects UI (combo, pause button, etc.). Optional, default false.
vars is optional: a map from variable names to animation variables used as shader parameters (uniforms). Example:
{
...,
"vars": {
"power": ...,
"radius": ...
}
}Example
This applies the built-in chromatic shader from [2, 0, 1] to [4, 0, 1], with power animating from 0 to 0.1 and sampleCount fixed at 5:
{
...,
"effects": [
{
"start": [2, 0, 1],
"end": [4, 0, 1],
"shader": "chromatic",
"vars": {
"power": [
{
"startTime": [2, 0, 1],
"endTime": [4, 0, 1],
"easingType": 2,
"start": 0.0,
"end": 0.1
}
],
"sampleCount": 5
}
}
]
}Built-in shaders
See built-in shaders for the list and their parameters.