shaderlib: Remove hsv_multiply and hsv_offset, rename hsv.gdshaderinc to colorspaces.gdshaderinc, update autocomplete and example accordingly; implements #36
This commit is contained in:
parent
50ddf6e6d3
commit
3b47d57353
3 changed files with 6 additions and 33 deletions
|
@ -1,6 +1,6 @@
|
|||
shader_type canvas_item;
|
||||
|
||||
#include "res://shaderlib/hsv.gdshaderinc"
|
||||
#include "res://shaderlib/colorspaces.gdshaderinc"
|
||||
#include "res://shaderlib/effects.gdshaderinc"
|
||||
|
||||
//!load ./images/swamp.jpg
|
||||
|
@ -8,6 +8,7 @@ shader_type canvas_item;
|
|||
void fragment() {
|
||||
COLOR = pixelate(TEXTURE, UV, 200.0);
|
||||
vec4 hsv = rgb2hsv(COLOR);
|
||||
COLOR = hsv_offset(COLOR, 0.65, .42-(hsv.y*.3), -.125);
|
||||
COLOR = hsv_multiply(COLOR, 1.0, 1.0, 1.25);
|
||||
hsv.xyz += vec3(0.65, .42-(hsv.y*.3), -.125);
|
||||
hsv.xyz *= vec3(1.0, 1.0, 1.25);
|
||||
COLOR = hsv2rgb(hsv);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue