1
0
mirror of https://github.com/DigvijaysinhGohil/Godot-Shader-Lib.git synced 2025-09-21 04:45:57 +08:00

UV nodes refactored

- Set the default value for uv input as 0, 0 to avoid errors when using with shader modes PARTICLES, SKY and FOG
- FlipbookUV node is now only available in shader modes SPATIAL and CANVAS_ITEM
This commit is contained in:
Digvijaysinh Gohil
2023-11-21 20:49:41 +05:30
parent 05dfe4c1fd
commit ecd09b5246
8 changed files with 52 additions and 8 deletions

View File

@ -2,10 +2,10 @@ vec3 node_scale_world(mat4 model_matrix){
vec3 _axis_x = model_matrix[0].xyz;
vec3 _axis_y = model_matrix[1].xyz;
vec3 _axis_z = model_matrix[2].xyz;
float _scale_x = length(_axis_x);
float _scale_y = length(_axis_y);
float _scale_z = length(_axis_z);
return vec3(_scale_x, _scale_y, _scale_z);
}