From 42bc0cbf85f53b633db41d8a488158c587a6f46b Mon Sep 17 00:00:00 2001
From: Mistium <92952823+Mistium@users.noreply.github.com>
Date: Mon, 2 Dec 2024 22:39:45 +0000
Subject: [PATCH] Create ImageEffects-min.js
---
cache/ImageEffects-min.js | 1 +
1 file changed, 1 insertion(+)
create mode 100644 cache/ImageEffects-min.js
diff --git a/cache/ImageEffects-min.js b/cache/ImageEffects-min.js
new file mode 100644
index 0000000..7c27a23
--- /dev/null
+++ b/cache/ImageEffects-min.js
@@ -0,0 +1 @@
+!function(t){"use strict";if(!t.extensions.unsandboxed)throw new Error("Image Effects must run unsandboxed");function e(t){return[parseInt(t.slice(1,3),16),parseInt(t.slice(3,5),16),parseInt(t.slice(5,7),16),9===t.length?parseInt(t.slice(7,9),16)/255:255]}t.extensions.register(new class{constructor(){this.cutPos=[0,0],this.scale=[100,100],this.cutoutDirection=90,this.softness=10,this.allShards=[]}getInfo(){return{id:"imgEffectsSP",name:"Image Effects",color1:"#9966FF",color2:"#774DCB",blocks:[{blockType:t.BlockType.LABEL,text:"Effects"},{opcode:"convertHexToRGB",blockType:t.BlockType.REPORTER,text:"convert [HEX] to [CHANNEL]",hideFromPalette:!0,arguments:{HEX:{type:t.ArgumentType.COLOR,defaultValue:"#ff0000"},CHANNEL:{type:t.ArgumentType.STRING,menu:"CHANNELS"}}},{opcode:"applyHueEffect",blockType:t.BlockType.REPORTER,text:"apply hue [COLOR] to URI [SVG]",arguments:{SVG:{type:t.ArgumentType.STRING,defaultValue:"svg/data-uri"},COLOR:{type:t.ArgumentType.COLOR,defaultValue:"#ff0000"}}},"---",{opcode:"deleteColor",blockType:t.BlockType.REPORTER,text:"remove color [COLOR] from [DATA_URI]",arguments:{COLOR:{type:t.ArgumentType.COLOR,defaultValue:"#ff0000"},DATA_URI:{type:t.ArgumentType.STRING,defaultValue:"svg/data-uri"}}},{opcode:"replaceColor",blockType:t.BlockType.REPORTER,text:"replace color [COLOR] with [REPLACE] from [DATA_URI]",arguments:{COLOR:{type:t.ArgumentType.COLOR,defaultValue:"#ff0000"},REPLACE:{type:t.ArgumentType.COLOR,defaultValue:"#00ff00"},DATA_URI:{type:t.ArgumentType.STRING,defaultValue:"svg/data-uri"}}},{opcode:"setSoftness",blockType:t.BlockType.COMMAND,text:"set softness of color detection to [AMT]%",arguments:{AMT:{type:t.ArgumentType.NUMBER,defaultValue:10}}},"---",{opcode:"applyEffect",blockType:t.BlockType.REPORTER,text:"set [EFFECT] effect of URI [SVG] to [PERCENTAGE]%",arguments:{EFFECT:{type:t.ArgumentType.STRING,menu:"EFFECTS"},SVG:{type:t.ArgumentType.STRING,defaultValue:"svg/data-uri"},PERCENTAGE:{type:t.ArgumentType.NUMBER,defaultValue:50}}},{opcode:"applyBulgeEffect",blockType:t.BlockType.REPORTER,text:"set bulge effect of URI [SVG] to [STRENGTH]% at x [CENTER_X] y [CENTER_Y]",arguments:{SVG:{type:t.ArgumentType.STRING,defaultValue:"svg/data-uri"},STRENGTH:{type:t.ArgumentType.NUMBER,defaultValue:50},CENTER_X:{type:t.ArgumentType.NUMBER,defaultValue:0},CENTER_Y:{type:t.ArgumentType.NUMBER,defaultValue:0}}},{opcode:"applyWaveEffect",blockType:t.BlockType.REPORTER,text:"set wave effect of URI [SVG] to amplitude x [AMPX] y [AMPY] and frequency x [FREQX] y [FREQY]",arguments:{SVG:{type:t.ArgumentType.STRING,defaultValue:"svg/data-uri"},AMPX:{type:t.ArgumentType.NUMBER,defaultValue:50},AMPY:{type:t.ArgumentType.NUMBER,defaultValue:50},FREQX:{type:t.ArgumentType.NUMBER,defaultValue:5},FREQY:{type:t.ArgumentType.NUMBER,defaultValue:5}}},{opcode:"applyLineGlitchEffect",blockType:t.BlockType.REPORTER,text:"set line glitch of URI [SVG] to [PERCENTAGE]% on [DIRECT] axis and line width [WIDTH]",arguments:{SVG:{type:t.ArgumentType.STRING,defaultValue:"svg/data-uri"},PERCENTAGE:{type:t.ArgumentType.NUMBER,defaultValue:50},DIRECT:{type:t.ArgumentType.STRING,menu:"POSITIONS"},WIDTH:{type:t.ArgumentType.NUMBER,defaultValue:5}}},{opcode:"applyAbberationEffect",blockType:t.BlockType.REPORTER,text:"set abberation of URI [SVG] to colors [COLOR1] and [COLOR2] at [PERCENTAGE]% on [DIRECT] axis",arguments:{SVG:{type:t.ArgumentType.STRING,defaultValue:"svg/data-uri"},PERCENTAGE:{type:t.ArgumentType.NUMBER,defaultValue:5},COLOR1:{type:t.ArgumentType.COLOR,defaultValue:"#ff0000"},COLOR2:{type:t.ArgumentType.COLOR,defaultValue:"#00f7ff"},DIRECT:{type:t.ArgumentType.STRING,menu:"POSITIONS"}}},"---",{opcode:"removeTransparencyEffect",blockType:t.BlockType.REPORTER,text:"remove pixels from URI [SVG] [REMOVE] [THRESHOLD]% transparency",arguments:{SVG:{type:t.ArgumentType.STRING,defaultValue:"svg/data-uri"},THRESHOLD:{type:t.ArgumentType.NUMBER,defaultValue:50},REMOVE:{type:t.ArgumentType.STRING,menu:"REMOVAL"}}},{opcode:"applyEdgeOutlineEffect",blockType:t.BlockType.REPORTER,text:"add outline to URI [SVG] with thickness [THICKNESS] and color [COLOR] opacity [A]%",arguments:{SVG:{type:t.ArgumentType.STRING,defaultValue:"svg/data-uri"},THICKNESS:{type:t.ArgumentType.NUMBER,defaultValue:1},COLOR:{type:t.ArgumentType.COLOR,defaultValue:"#ff0000"},A:{type:t.ArgumentType.NUMBER,defaultValue:100}}},{blockType:t.BlockType.LABEL,text:"Clipping"},{opcode:"clipImage",blockType:t.BlockType.REPORTER,text:"clip [CUTOUT] from [MAIN]",arguments:{MAIN:{type:t.ArgumentType.STRING,defaultValue:"source-here"},CUTOUT:{type:t.ArgumentType.STRING,defaultValue:"cutout-here"}}},{opcode:"overlayImage",blockType:t.BlockType.REPORTER,text:"clip [CUTOUT] onto [MAIN]",arguments:{MAIN:{type:t.ArgumentType.STRING,defaultValue:"source-here"},CUTOUT:{type:t.ArgumentType.STRING,defaultValue:"cutout-here"}}},"---",{opcode:"setCutout",blockType:t.BlockType.COMMAND,text:"set clipping position to x [X] y [Y]",arguments:{X:{type:t.ArgumentType.NUMBER,defaultValue:0},Y:{type:t.ArgumentType.NUMBER,defaultValue:0}}},{opcode:"changeCutout",blockType:t.BlockType.COMMAND,text:"change clipping position by x [X] y [Y]",arguments:{X:{type:t.ArgumentType.NUMBER,defaultValue:10},Y:{type:t.ArgumentType.NUMBER,defaultValue:0}}},{opcode:"currentCut",blockType:t.BlockType.REPORTER,text:"clipping [POS]",disableMonitor:!0,arguments:{POS:{type:t.ArgumentType.STRING,menu:"POSITIONS"}}},"---",{opcode:"setScale",blockType:t.BlockType.COMMAND,text:"set clipping size to x [SIZE] y [Y]",arguments:{SIZE:{type:t.ArgumentType.NUMBER,defaultValue:100},Y:{type:t.ArgumentType.NUMBER,defaultValue:100}}},{opcode:"changeScale",blockType:t.BlockType.COMMAND,text:"change clipping size by x [SIZE] y [Y]",arguments:{SIZE:{type:t.ArgumentType.NUMBER,defaultValue:10},Y:{type:t.ArgumentType.NUMBER,defaultValue:0}}},{opcode:"currentScale",blockType:t.BlockType.REPORTER,text:"clipping size [POS]",disableMonitor:!0,arguments:{POS:{type:t.ArgumentType.STRING,menu:"POSITIONS"}}},"---",{opcode:"setDirection",blockType:t.BlockType.COMMAND,text:"set clipping direction to [ANGLE]",arguments:{ANGLE:{type:t.ArgumentType.ANGLE,defaultValue:90}}},{opcode:"changeDirection",blockType:t.BlockType.COMMAND,text:"change clipping direction by [ANGLE]",arguments:{ANGLE:{type:t.ArgumentType.ANGLE,defaultValue:15}}},{opcode:"currentDir",blockType:t.BlockType.REPORTER,text:"clipping direction"},"---",{opcode:"crackImage",blockType:t.BlockType.COMMAND,text:"crack [URI] into [SHARDS] shards",arguments:{URI:{type:t.ArgumentType.STRING,defaultValue:"svg/data-uri"},SHARDS:{type:t.ArgumentType.NUMBER,defaultValue:5}}},{opcode:"getShard",blockType:t.BlockType.REPORTER,text:"get shard #[SHARD]",arguments:{SHARD:{type:t.ArgumentType.NUMBER,defaultValue:1}}},{blockType:t.BlockType.LABEL,text:"Pixels"},{opcode:"numPixels",blockType:t.BlockType.REPORTER,text:"number of pixels [TYPE] in [URI]",arguments:{URI:{type:t.ArgumentType.STRING,defaultValue:"svg/data-uri"},TYPE:{type:t.ArgumentType.STRING,menu:"PIXELTYPE"}}},{opcode:"getPixel",blockType:t.BlockType.REPORTER,text:"get hex of pixel #[NUM] in [URI]",arguments:{URI:{type:t.ArgumentType.STRING,defaultValue:"svg/data-uri"},NUM:{type:t.ArgumentType.NUMBER,defaultValue:1}}},{opcode:"setPixel",blockType:t.BlockType.REPORTER,text:"set color of pixel #[NUM] to [COLOR] in [URI]",arguments:{URI:{type:t.ArgumentType.STRING,defaultValue:"svg/data-uri"},NUM:{type:t.ArgumentType.NUMBER,defaultValue:1},COLOR:{type:t.ArgumentType.COLOR,defaultValue:"#ff0000"}}},{opcode:"setPixels",blockType:t.BlockType.REPORTER,text:"set color of pixels from #[NUM] to [NUM2] to [COLOR] in [URI]",arguments:{URI:{type:t.ArgumentType.STRING,defaultValue:"svg/data-uri"},NUM:{type:t.ArgumentType.NUMBER,defaultValue:1},NUM2:{type:t.ArgumentType.NUMBER,defaultValue:10},COLOR:{type:t.ArgumentType.COLOR,defaultValue:"#ff0000"}}},{blockType:t.BlockType.LABEL,text:"Image Conversions"},{opcode:"svgToBitmap",blockType:t.BlockType.REPORTER,text:"convert svg content [SVG] to bitmap with width [WIDTH] height [HEIGHT]",arguments:{SVG:{type:t.ArgumentType.STRING,defaultValue:""},WIDTH:{type:t.ArgumentType.NUMBER,defaultValue:100},HEIGHT:{type:t.ArgumentType.NUMBER,defaultValue:100}}},{opcode:"convertImageToSVG",blockType:t.BlockType.REPORTER,text:"convert bitmap URI [URI] to svg [TYPE]",arguments:{URI:{type:t.ArgumentType.STRING,defaultValue:"svg/data-uri"},TYPE:{type:t.ArgumentType.STRING,menu:"fileType"}}},{opcode:"makeSVGimage",blockType:t.BlockType.REPORTER,text:"make new svg with image URI [URI] to svg [TYPE]",arguments:{URI:{type:t.ArgumentType.STRING,defaultValue:"svg/data-uri"},TYPE:{type:t.ArgumentType.STRING,menu:"fileType"}}},{opcode:"upscaleImage",blockType:t.BlockType.REPORTER,text:"upscale image URI [URI] by [NUM] %",arguments:{URI:{type:t.ArgumentType.STRING,defaultValue:"svg/data-uri"},NUM:{type:t.ArgumentType.NUMBER,defaultValue:5}}},"---",{opcode:"stretchImg",blockType:t.BlockType.REPORTER,text:"stretch URI [URI] to width [W] height [H]",arguments:{URI:{type:t.ArgumentType.STRING,defaultValue:"svg/data-uri"},W:{type:t.ArgumentType.NUMBER,defaultValue:200},H:{type:t.ArgumentType.NUMBER,defaultValue:100}}},"---",{opcode:"audioToImage",blockType:t.BlockType.REPORTER,text:"convert audio URI [AUDIO_URI] to PNG with width [W] height [H]",arguments:{AUDIO_URI:{type:t.ArgumentType.STRING,defaultValue:"audio_uri_here"},W:{type:t.ArgumentType.NUMBER,defaultValue:100},H:{type:t.ArgumentType.NUMBER,defaultValue:100}}},{opcode:"skewSVG",blockType:t.BlockType.REPORTER,text:"skew SVG content [SVG] at x [Y] y [X] as [TYPE]",arguments:{SVG:{type:t.ArgumentType.STRING,defaultValue:"