ULRE/ShaderLibrary/Std3D/VertexLum3D.mtl

48 lines
438 B
Plaintext
Raw Normal View History

2023-10-07 20:09:16 +08:00
#Material
Name VertexLum3D
Base Std3D
#MaterialInstance
Length 16
Stage Vertex
Code
{
vec4 Color;
2023-10-07 20:09:16 +08:00
}
#VertexInput
float Luminance
2023-10-07 20:09:16 +08:00
#Vertex
2023-10-07 20:09:16 +08:00
Output
{
vec4 Color
}
Code
{
void main()
{
MaterialInstance mi=GetMI();
Output.Color=Luminance*mi.Color;
gl_Position=GetPosition3D();
}
}
#Fragment
Output
{
vec4 FragColor;
2023-10-07 20:09:16 +08:00
}
Code
{
void main()
{
FragColor=Input.Color;
2023-10-07 20:09:16 +08:00
}
}