🎉 Add support for GNOME Shell 47
This commit is contained in:
@@ -45,10 +45,8 @@ export default class Effect {
|
||||
|
||||
// Write all uniform values at the start of each animation.
|
||||
shader.connect('begin-animation', (shader, settings) => {
|
||||
const c = Clutter.Color.from_string(settings.get_string('energize-a-color'))[1];
|
||||
|
||||
// clang-format off
|
||||
shader.set_uniform_float(shader._uColor, 3, [c.red / 255, c.green / 255, c.blue / 255]);
|
||||
shader.set_uniform_float(shader._uColor, 3, utils.parseColor(settings.get_string('energize-a-color')));
|
||||
shader.set_uniform_float(shader._uScale, 1, [settings.get_double('energize-a-scale')]);
|
||||
// clang-format on
|
||||
});
|
||||
|
||||
@@ -45,10 +45,8 @@ export default class Effect {
|
||||
|
||||
// Write all uniform values at the start of each animation.
|
||||
shader.connect('begin-animation', (shader, settings) => {
|
||||
const c = Clutter.Color.from_string(settings.get_string('energize-b-color'))[1];
|
||||
|
||||
// clang-format off
|
||||
shader.set_uniform_float(shader._uColor, 3, [c.red / 255, c.green / 255, c.blue / 255]);
|
||||
shader.set_uniform_float(shader._uColor, 3, utils.parseColor(settings.get_string('energize-b-color')));
|
||||
shader.set_uniform_float(shader._uScale, 1, [settings.get_double('energize-b-scale')]);
|
||||
// clang-format on
|
||||
});
|
||||
|
||||
+1
-2
@@ -61,10 +61,9 @@ export default class Effect {
|
||||
// And update all uniforms at the start of each animation.
|
||||
shader.connect('begin-animation', (shader, settings) => {
|
||||
for (let i = 1; i <= 5; i++) {
|
||||
const c = Clutter.Color.from_string(settings.get_string('fire-color-' + i))[1];
|
||||
shader.set_uniform_float(
|
||||
shader._uGradient[i - 1], 4,
|
||||
[c.red / 255, c.green / 255, c.blue / 255, c.alpha / 255]);
|
||||
utils.parseColor(settings.get_string('fire-color-' + i)));
|
||||
}
|
||||
|
||||
// clang-format off
|
||||
|
||||
@@ -48,11 +48,9 @@ export default class Effect {
|
||||
|
||||
// Write all uniform values at the start of each animation.
|
||||
shader.connect('begin-animation', (shader, settings, forOpening, testMode) => {
|
||||
const c = Clutter.Color.from_string(settings.get_string('glitch-color'))[1];
|
||||
|
||||
// clang-format off
|
||||
shader.set_uniform_float(shader._uSeed, 1, [testMode ? 0 : Math.random()]);
|
||||
shader.set_uniform_float(shader._uColor, 4, [c.red / 255, c.green / 255, c.blue / 255, c.alpha / 255]);
|
||||
shader.set_uniform_float(shader._uColor, 4, utils.parseColor(settings.get_string('glitch-color')));
|
||||
shader.set_uniform_float(shader._uScale, 1, [settings.get_double('glitch-scale')]);
|
||||
shader.set_uniform_float(shader._uStrength, 1, [settings.get_double('glitch-strength')]);
|
||||
shader.set_uniform_float(shader._uSpeed, 1, [settings.get_double('glitch-speed')]);
|
||||
|
||||
@@ -50,20 +50,13 @@ export default class Effect {
|
||||
|
||||
// Write all uniform values at the start of each animation.
|
||||
shader.connect('begin-animation', (shader, settings, forOpening, testMode) => {
|
||||
// Get the two configurable colors. They are directly injected into the shader
|
||||
// code below.
|
||||
const gc =
|
||||
Clutter.Color.from_string(settings.get_string('hexagon-glow-color'))[1];
|
||||
const lc =
|
||||
Clutter.Color.from_string(settings.get_string('hexagon-line-color'))[1];
|
||||
|
||||
// clang-format off
|
||||
shader.set_uniform_float(shader._uAdditiveBlending, 1, [settings.get_boolean('hexagon-additive-blending')]);
|
||||
shader.set_uniform_float(shader._uSeed, 2, [testMode ? 0 : Math.random(), testMode ? 0 : Math.random()]);
|
||||
shader.set_uniform_float(shader._uScale, 1, [settings.get_double('hexagon-scale')]);
|
||||
shader.set_uniform_float(shader._uLineWidth, 1, [settings.get_double('hexagon-line-width')]);
|
||||
shader.set_uniform_float(shader._uGlowColor, 4, [gc.red / 255, gc.green / 255, gc.blue / 255, gc.alpha / 255]);
|
||||
shader.set_uniform_float(shader._uLineColor, 4, [lc.red / 255, lc.green / 255, lc.blue / 255, lc.alpha / 255]);
|
||||
shader.set_uniform_float(shader._uGlowColor, 4, utils.parseColor(settings.get_string('hexagon-glow-color')));
|
||||
shader.set_uniform_float(shader._uLineColor, 4, utils.parseColor(settings.get_string('hexagon-line-color')));
|
||||
// clang-format on
|
||||
});
|
||||
});
|
||||
|
||||
@@ -72,11 +72,9 @@ export default class Effect {
|
||||
shader._startPointerPos = null;
|
||||
}
|
||||
|
||||
const c = Clutter.Color.from_string(settings.get_string('incinerate-color'))[1];
|
||||
|
||||
// clang-format off
|
||||
shader.set_uniform_float(shader._uSeed, 2, seed);
|
||||
shader.set_uniform_float(shader._uColor, 3, [c.red / 255, c.green / 255, c.blue / 255]);
|
||||
shader.set_uniform_float(shader._uColor, 3, utils.parseColor(settings.get_string('incinerate-color')));
|
||||
shader.set_uniform_float(shader._uScale, 1, [settings.get_double('incinerate-scale')]);
|
||||
shader.set_uniform_float(shader._uTurbulence, 1, [settings.get_double('incinerate-turbulence')]);
|
||||
// clang-format on
|
||||
|
||||
@@ -65,13 +65,9 @@ export default class Effect {
|
||||
|
||||
// Write all uniform values at the start of each animation.
|
||||
shader.connect('begin-animation', (shader, settings) => {
|
||||
const c1 =
|
||||
Clutter.Color.from_string(settings.get_string('matrix-trail-color'))[1];
|
||||
const c2 = Clutter.Color.from_string(settings.get_string('matrix-tip-color'))[1];
|
||||
|
||||
// clang-format off
|
||||
shader.set_uniform_float(shader._uTrailColor, 3, [c1.red / 255, c1.green / 255, c1.blue / 255]);
|
||||
shader.set_uniform_float(shader._uTipColor, 3, [c2.red / 255, c2.green / 255, c2.blue / 255]);
|
||||
shader.set_uniform_float(shader._uTrailColor, 3, utils.parseColor(settings.get_string('matrix-trail-color')));
|
||||
shader.set_uniform_float(shader._uTipColor, 3, utils.parseColor(settings.get_string('matrix-tip-color')));
|
||||
shader.set_uniform_float(shader._uLetterSize, 1, [settings.get_int('matrix-scale')]);
|
||||
shader.set_uniform_float(shader._uRandomness, 1, [settings.get_double('matrix-randomness')]);
|
||||
shader.set_uniform_float(shader._uOverShoot, 1, [settings.get_double('matrix-overshoot')]);
|
||||
|
||||
@@ -49,11 +49,9 @@ export default class Effect {
|
||||
|
||||
// Write all uniform values at the start of each animation.
|
||||
shader.connect('begin-animation', (shader, settings, forOpening, testMode) => {
|
||||
const c = Clutter.Color.from_string(settings.get_string('portal-color'))[1];
|
||||
|
||||
// clang-format off
|
||||
shader.set_uniform_float(shader._uSeed, 2, [testMode ? 0 : Math.random(), testMode ? 0 : Math.random()]);
|
||||
shader.set_uniform_float(shader._uColor, 3, [c.red / 255, c.green / 255, c.blue / 255]);
|
||||
shader.set_uniform_float(shader._uColor, 3, utils.parseColor(settings.get_string('portal-color')));
|
||||
shader.set_uniform_float(shader._uDetails, 1, [settings.get_double('portal-details')]);
|
||||
shader.set_uniform_float(shader._uRotationSpeed, 1, [settings.get_double('portal-rotation-speed')]);
|
||||
shader.set_uniform_float(shader._uWhirling, 1, [settings.get_double('portal-whirling')]);
|
||||
|
||||
@@ -63,11 +63,8 @@ export default class Effect {
|
||||
|
||||
// Write all uniform values at the start of each animation.
|
||||
shader.connect('begin-animation', (shader, settings, forOpening, testMode) => {
|
||||
// The dust particles will fade to this color over time.
|
||||
const c = Clutter.Color.from_string(settings.get_string('snap-color'))[1];
|
||||
|
||||
// clang-format off
|
||||
shader.set_uniform_float(shader._uDustColor, 4, [c.red / 255, c.green / 255, c.blue / 255, c.alpha / 255]);
|
||||
shader.set_uniform_float(shader._uDustColor, 4, utils.parseColor(settings.get_string('snap-color')));
|
||||
shader.set_uniform_float(shader._uSeed, 2, [testMode ? 0 : Math.random(), testMode ? 0 : Math.random()]);
|
||||
shader.set_uniform_float(shader._uDustScale, 1, [settings.get_double('snap-scale')]);
|
||||
// clang-format on
|
||||
|
||||
@@ -61,10 +61,8 @@ export default class Effect {
|
||||
|
||||
// Write all uniform values at the start of each animation.
|
||||
shader.connect('begin-animation', (shader, settings, forOpening, testMode) => {
|
||||
const c = Clutter.Color.from_string(settings.get_string('trex-scratch-color'))[1];
|
||||
|
||||
// clang-format off
|
||||
shader.set_uniform_float(shader._uFlashColor, 4, [c.red / 255, c.green / 255, c.blue / 255, c.alpha / 255]);
|
||||
shader.set_uniform_float(shader._uFlashColor, 4, utils.parseColor(settings.get_string('trex-scratch-color')));
|
||||
shader.set_uniform_float(shader._uSeed, 2, [testMode ? 0 : Math.random(), testMode ? 0 : Math.random()]);
|
||||
shader.set_uniform_float(shader._uClawSize, 1, [settings.get_double('trex-scratch-scale')]);
|
||||
shader.set_uniform_float(shader._uNumClaws, 1, [settings.get_int('trex-scratch-count')]);
|
||||
|
||||
@@ -46,9 +46,8 @@ export default class Effect {
|
||||
|
||||
// Write all uniform values at the start of each animation.
|
||||
shader.connect('begin-animation', (shader, settings) => {
|
||||
const c = Clutter.Color.from_string(settings.get_string('tv-effect-color'))[1];
|
||||
shader.set_uniform_float(
|
||||
shader._uColor, 4, [c.red / 255, c.green / 255, c.blue / 255, c.alpha / 255]);
|
||||
shader._uColor, 4, utils.parseColor(settings.get_string('tv-effect-color')));
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
@@ -49,11 +49,9 @@ export default class Effect {
|
||||
|
||||
// Write all uniform values at the start of each animation.
|
||||
shader.connect('begin-animation', (shader, settings, forOpening, testMode) => {
|
||||
const c = Clutter.Color.from_string(settings.get_string('tv-glitch-color'))[1];
|
||||
|
||||
// clang-format off
|
||||
shader.set_uniform_float(shader._uSeed, 1, [testMode ? 0 : Math.random()]);
|
||||
shader.set_uniform_float(shader._uColor, 4, [c.red / 255, c.green / 255, c.blue / 255, c.alpha / 255]);
|
||||
shader.set_uniform_float(shader._uColor, 4, utils.parseColor(settings.get_string('tv-glitch-color')));
|
||||
shader.set_uniform_float(shader._uScale, 1, [settings.get_double('tv-glitch-scale')]);
|
||||
shader.set_uniform_float(shader._uStrength, 1, [settings.get_double('tv-glitch-strength')]);
|
||||
shader.set_uniform_float(shader._uSpeed, 1, [settings.get_double('tv-glitch-speed')]);
|
||||
|
||||
@@ -52,9 +52,8 @@ export default class Effect {
|
||||
// Write all uniform values at the start of each animation.
|
||||
shader.connect('begin-animation', (shader, settings, forOpening, testMode) => {
|
||||
for (let i = 1; i <= 3; i++) {
|
||||
const c = Clutter.Color.from_string(settings.get_string('wisps-color-' + i))[1];
|
||||
shader.set_uniform_float(shader._uColor[i - 1], 3,
|
||||
[c.red / 255, c.green / 255, c.blue / 255]);
|
||||
utils.parseColor(settings.get_string('wisps-color-' + i)));
|
||||
}
|
||||
|
||||
// clang-format off
|
||||
|
||||
Reference in New Issue
Block a user