mirror of
https://github.com/Rundll86/Dog-Lynx-And-HCN.git
synced 2026-05-28 06:51:54 +08:00
添加Pixelization着色器,支持像素化效果
This commit is contained in:
@@ -0,0 +1,7 @@
|
||||
shader_type canvas_item;
|
||||
uniform int pixelSize;
|
||||
|
||||
void fragment() {
|
||||
vec2 uv = UV - mod(UV, vec2(float(pixelSize)) / vec2(textureSize(TEXTURE, 0)));
|
||||
COLOR = texture(TEXTURE, uv);
|
||||
}
|
||||
Reference in New Issue
Block a user