2014-11-10 15:04:40 -08:00
|
|
|
#pragma once
|
|
|
|
|
2019-06-22 22:13:45 -07:00
|
|
|
static const char vertex_shader_string[] = "struct VertData \
|
2014-11-10 15:04:40 -08:00
|
|
|
{ \
|
|
|
|
float4 pos : SV_Position; \
|
|
|
|
float2 texCoord : TexCoord0; \
|
|
|
|
}; \
|
|
|
|
VertData main(VertData input) \
|
|
|
|
{ \
|
|
|
|
VertData output; \
|
|
|
|
output.pos = input.pos; \
|
|
|
|
output.texCoord = input.texCoord; \
|
|
|
|
return output; \
|
|
|
|
}";
|
|
|
|
|
2019-06-22 22:13:45 -07:00
|
|
|
static const char pixel_shader_string[] = "uniform Texture2D diffuseTexture; \
|
2014-11-10 15:04:40 -08:00
|
|
|
SamplerState textureSampler \
|
|
|
|
{ \
|
|
|
|
AddressU = Clamp; \
|
|
|
|
AddressV = Clamp; \
|
|
|
|
Filter = Linear; \
|
|
|
|
}; \
|
|
|
|
struct VertData \
|
|
|
|
{ \
|
|
|
|
float4 pos : SV_Position; \
|
|
|
|
float2 texCoord : TexCoord0; \
|
|
|
|
}; \
|
|
|
|
float4 main(VertData input) : SV_Target \
|
|
|
|
{ \
|
|
|
|
return diffuseTexture.Sample(textureSampler, input.texCoord); \
|
|
|
|
}";
|