Fixing slang compilation temporarily, renaming vertexfactory
This commit is contained in:
1 parent
ab4a3b5e23
commit
f27859a02c
66 files changed
+1005
-627
No files matched your search
@@ -0,0 +1,40 @@
|
||||
struct MaterialVertexParameter
|
||||
{
|
||||
float3 worldPosition;
|
||||
float3x3 tangentToWorld;
|
||||
#if NUM_MATERIAL_TEXCOORDS
|
||||
float2 texCoords[NUM_MATERIAL_TEXCOORDS];
|
||||
#endif
|
||||
#if USE_INSTANCING
|
||||
float4x4 instanceLocalToWorld;
|
||||
float3 instanceLocalPosition;
|
||||
float4 perInstanceParams;
|
||||
uint instanceId;
|
||||
#endif
|
||||
//float3 preSkinnedPosition;
|
||||
//float3 perSkinnedNormal;
|
||||
float4 vertexColor;
|
||||
};
|
||||
|
||||
struct MaterialFragmentParameter
|
||||
{
|
||||
float3 worldPosition;
|
||||
float3 viewDir;
|
||||
float3 worldNormal;
|
||||
float3 worldTangent;
|
||||
float3 worldBiTangent;
|
||||
float4 clipPosition;
|
||||
float4 vertexColor;
|
||||
float3x3 tangentToWorld;
|
||||
#if USE_INSTANCING
|
||||
float3 perInstanceParams;
|
||||
#endif
|
||||
#if NUM_MATERIAL_TEXCOORDS
|
||||
float2 texCoords[NUM_MATERIAL_TEXCOORDS];
|
||||
#endif
|
||||
float3 transformNormalToWorld(float3 tangentSpaceNormal)
|
||||
{
|
||||
float3 result = mul(tangentToWorld, tangentSpaceNormal);
|
||||
return result;
|
||||
}
|
||||
};
|
||||
Reference in new issue
Block a user