added fxJPGHexGlitch

This commit is contained in:
2022-07-30 13:37:13 +02:00
parent 6a99b0b8e0
commit 9e0764e282
3 changed files with 3 additions and 3 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 584 KiB

After

Width:  |  Height:  |  Size: 52 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 584 KiB

View File

@@ -4287,7 +4287,7 @@ class JPGHEXGLITCH extends Shader {
JPGHEXGLITCH() {
name = "fxJPGHexGlitch";
params.add(new Param("byte amount to change probability", INTVAL, 2, 20, new int[]{RANDOM}));
params.add(new Param("iterations", INTVAL, 1, 10, new int[]{RANDOM}));
params.add(new Param("iterations", INTVAL, 2, 10, new int[]{RANDOM}));
params.add(new Param("direction", INTVAL, 0, 3, new int[]{RANDOM}));
directionParamIndex = 2;
rw = canvas.width;
@@ -4333,8 +4333,8 @@ class JPGHEXGLITCH extends Shader {
}
}
//println("Glitched " + glitchCount + " bytes");
saveBytes(dataPath("") + "/result.jpg", savebytes2);
img = loadImage(dataPath("") + "/result.jpg");
saveBytes(dataPath("") + "/JPGHex.jpg", savebytes2);
img = loadImage(dataPath("") + "/JPGHex.jpg");
}
canvas.endDraw();