32 lines
737 B
Plaintext
32 lines
737 B
Plaintext
// Copyright 2019-Present LexLiu. All Rights Reserved.
|
|
#include "/Engine/Public/Platform.ush"
|
|
|
|
float4x4 _MVP;
|
|
|
|
struct RenderMeshVSToPS
|
|
{
|
|
float4 position : SV_Position;
|
|
float2 uv : TEXCOORD0;
|
|
float2 uvMask : TEXCOORD1;
|
|
float3 localPosition : TEXCOORD2;
|
|
#if LGUI_BLEND_DEPTH
|
|
float4 screenPosition : TEXCOORD3;
|
|
#endif
|
|
};
|
|
|
|
void RenderMeshVS(
|
|
in float3 Position:ATTRIBUTE0,
|
|
in float2 TextureCoord0 : ATTRIBUTE1,
|
|
in float2 TextureCoord1 : ATTRIBUTE2,
|
|
out RenderMeshVSToPS v2p
|
|
)
|
|
{
|
|
v2p.position = mul(float4(Position.xyz, 1.0), _MVP);
|
|
v2p.localPosition = Position.xyz;
|
|
v2p.uv = TextureCoord0;
|
|
v2p.uvMask = TextureCoord1;
|
|
#if LGUI_BLEND_DEPTH
|
|
v2p.screenPosition = v2p.position;
|
|
#endif
|
|
}
|