1
0
Fork 0
mirror of https://github.com/ninjamuffin99/Funkin.git synced 2025-09-05 13:27:39 +00:00
Funkin/source/funkin/graphics/shaders/MosaicEffect.hx

23 lines
464 B
Haxe
Raw Permalink Normal View History

2024-06-15 05:08:55 +00:00
package funkin.graphics.shaders;
import flixel.addons.display.FlxRuntimeShader;
import flixel.math.FlxPoint;
2025-04-17 17:29:26 +00:00
@:nullSafety
2024-06-15 05:08:55 +00:00
class MosaicEffect extends FlxRuntimeShader
{
public var blockSize:FlxPoint = FlxPoint.get(1.0, 1.0);
public function new()
{
super(Assets.getText(Paths.frag('mosaic')));
setBlockSize(1.0, 1.0);
}
public function setBlockSize(w:Float, h:Float)
{
blockSize.set(w, h);
setFloatArray("uBlocksize", [w, h]);
}
}