stick-the-quick/vfx/neon.gdshader

19 lines
502 B
Plaintext
Raw Permalink Normal View History

shader_type spatial;
#include "res://vfx/util.gdshaderinc"
UNIVERSAL_SOLID_PARAMS
uniform sampler2D image: TEXTURE_HINTS;
uniform float exponent = 1.0;
void fragment() {
ALBEDO = texture(image, UV).rgb;
EMISSION = ALBEDO*pow(rgb2hsv(ALBEDO).z, exponent);
METALLIC = mix(METALLIC, 0.25, wet);
SPECULAR = mix(SPECULAR, 1.0, wet);
ROUGHNESS = mix(ROUGHNESS, 0.0, wet);
CLEARCOAT = mix(CLEARCOAT, 1.0, wet);
CLEARCOAT_ROUGHNESS = mix(CLEARCOAT_ROUGHNESS, 0.0, wet);
UNIVERSAL_SOLID_PROCESSING
}