Sample project to showcase the use of UI Toolkit for Runtime based on the Unity Royale project.
您最多选择25个主题 主题必须以中文或者字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符
 
 
 
 

13 行
462 B

void LWRPLightingFunction_float (float3 ObjPos, out float3 Direction, out float3 Color, out float ShadowAttenuation)
{
#ifdef SHADERGRAPH_PREVIEW
Direction = float3(-0.5, 0.5, -0.5);
Color = float3(1, 1, 1);
ShadowAttenuation = 0.4;
#else
Light light = GetMainLight(GetShadowCoord(GetVertexPositionInputs(ObjPos)));
Direction = light.direction;
Color = light.color;
ShadowAttenuation = light.shadowAttenuation;
#endif
}