Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
Rubberduckycooly
GitHub Repository: Rubberduckycooly/RSDKv5-Decompilation
Path: blob/master/RSDKv5/RSDK/Graphics/DX11/BackupShaders.hpp
1168 views
1
const char backupHLSL[] =
2
R"(
3
cbuffer RSDKBuffer : register(b0)
4
{
5
float2 pixelSize;
6
float2 textureSize;
7
float2 viewSize;
8
9
#if defined(RETRO_REV02)
10
float2 screenDim;
11
#endif
12
};
13
14
Texture2D texDiffuse : register(t0);
15
SamplerState sampDiffuse : register(s0);
16
17
struct VertexInput {
18
float3 pos : SV_POSITION;
19
float2 tex : TEXCOORD;
20
};
21
22
struct VertexOutput {
23
float4 pos : SV_POSITION;
24
float4 tex : TEXCOORD;
25
};
26
27
struct PixelInput {
28
float4 pos : SV_POSITION;
29
float2 tex : TEXCOORD;
30
};
31
32
VertexOutput VSMain(VertexInput input)
33
{
34
VertexOutput output;
35
36
output.pos = float4(input.pos.xyz, 1.0);
37
output.tex = float4(input.tex.xy, 0.0, 0.0);
38
39
return output;
40
}
41
42
float4 PSMain(PixelInput input) : SV_TARGET
43
{
44
return texDiffuse.Sample(sampDiffuse, input.tex);
45
}
46
)";
47
48