You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I created a fragment shader and a function where I use the built-in variable TIME. I get the error "Unknown identifier in expression: TIME". However I can use TIME in the fragment()-function but not in my own functions.
Working example:
shader_type spatial;
render_mode unshaded;
void fragment()
{
vec3 col = 0.5 + 0.5*cos(vec3(0.0, TIME, 0.0));
ALBEDO = col;
}
Not working example:
shader_type spatial;
render_mode unshaded;
vec3 getColor()
{
vec3 col = 0.5 + 0.5*cos(vec3(0.0, TIME, 0.0));
return col;
}
void fragment()
{
vec3 col = getColor();
ALBEDO = col;
}
Steps to reproduce:
Create a fragment shader and write a function that uses TIME.
Godot version:
3.0.3
OS/device including version:
Fedora 26
Issue description:
I created a fragment shader and a function where I use the built-in variable TIME. I get the error "Unknown identifier in expression: TIME". However I can use TIME in the fragment()-function but not in my own functions.
Working example:
Not working example:
Steps to reproduce:
Create a fragment shader and write a function that uses TIME.
Minimal reproduction project:
shader_TIME.zip
The text was updated successfully, but these errors were encountered: