added Std2D/3D material files.
This commit is contained in:
39
ShaderLibrary/Std3D/VertexColor3D.mtl
Normal file
39
ShaderLibrary/Std3D/VertexColor3D.mtl
Normal file
@@ -0,0 +1,39 @@
|
||||
#Material
|
||||
Name VertexColor3D
|
||||
Base Std3D
|
||||
|
||||
#Vertex
|
||||
Input
|
||||
{
|
||||
vec4 Color
|
||||
}
|
||||
|
||||
Output
|
||||
{
|
||||
vec4 Color
|
||||
}
|
||||
|
||||
Code
|
||||
{
|
||||
void main()
|
||||
{
|
||||
Output.Color=Color;
|
||||
|
||||
gl_Position=GetPosition3D();
|
||||
}
|
||||
}
|
||||
|
||||
#Fragment
|
||||
|
||||
Output
|
||||
{
|
||||
vec4 Color;
|
||||
}
|
||||
|
||||
Code
|
||||
{
|
||||
void main()
|
||||
{
|
||||
Color=Input.Color;
|
||||
}
|
||||
}
|
49
ShaderLibrary/Std3D/VertexLum3D.mtl
Normal file
49
ShaderLibrary/Std3D/VertexLum3D.mtl
Normal file
@@ -0,0 +1,49 @@
|
||||
#Material
|
||||
Name VertexLum3D
|
||||
Base Std3D
|
||||
|
||||
#MaterialInstance
|
||||
Length 16
|
||||
Stage Vertex
|
||||
Code
|
||||
{
|
||||
vec4 Color
|
||||
}
|
||||
|
||||
#Vertex
|
||||
Input
|
||||
{
|
||||
float Luminance;
|
||||
}
|
||||
|
||||
Output
|
||||
{
|
||||
vec4 Color
|
||||
}
|
||||
|
||||
Code
|
||||
{
|
||||
void main()
|
||||
{
|
||||
MaterialInstance mi=GetMI();
|
||||
|
||||
Output.Color=Luminance*mi.Color;
|
||||
|
||||
gl_Position=GetPosition3D();
|
||||
}
|
||||
}
|
||||
|
||||
#Fragment
|
||||
|
||||
Output
|
||||
{
|
||||
vec4 Color;
|
||||
}
|
||||
|
||||
Code
|
||||
{
|
||||
void main()
|
||||
{
|
||||
Color=Input.Color;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user