24 lines
577 B
HLSL
24 lines
577 B
HLSL
// XC_BUILTIN_UNLIT_D3D12_PS
|
|
Texture2D gBaseColorTexture : register(t0);
|
|
SamplerState gLinearSampler : register(s0);
|
|
|
|
cbuffer PerObjectConstants : register(b0) {
|
|
float4x4 gProjectionMatrix;
|
|
float4x4 gViewMatrix;
|
|
float4x4 gModelMatrix;
|
|
float4x4 gNormalMatrix;
|
|
};
|
|
|
|
cbuffer MaterialConstants : register(b1) {
|
|
float4 gBaseColorFactor;
|
|
};
|
|
|
|
struct PSInput {
|
|
float4 position : SV_POSITION;
|
|
float2 texcoord : TEXCOORD0;
|
|
};
|
|
|
|
float4 MainPS(PSInput input) : SV_TARGET {
|
|
return gBaseColorTexture.Sample(gLinearSampler, input.texcoord) * gBaseColorFactor;
|
|
}
|