TDME2 1.9.121
ShadowMapRenderShaderDefaultImplementation.cpp
Go to the documentation of this file.
2
3#include <string>
4
5#include <tdme/tdme.h>
9
10using std::to_string;
11
16
17bool ShadowMapRenderShaderDefaultImplementation::isSupported(Renderer* renderer) {
18 return true;
19}
20
22{
23}
24
26{
27}
28
30 return "default";
31}
32
34{
35 auto shaderVersion = renderer->getShaderVersion();
36
37 // load shadow mapping shaders
40 "shader/" + shaderVersion + "/shadowmapping",
41 "render_vertexshader.vert"
42 );
43 if (vertexShaderId == 0) return;
44
47 "shader/" + shaderVersion + "/shadowmapping",
48 "render_fragmentshader.frag"
49 );
50 if (fragmentShaderId == 0) return;
51
52 // create shadow mapping render program
56
58}
59
61}
virtual int32_t loadShader(int32_t type, const string &pathName, const string &fileName, const string &definitions=string(), const string &functions=string())=0
Loads a shader.
virtual int32_t createProgram(int type)=0
Creates a shader program.
virtual void attachShaderToProgram(int32_t programId, int32_t shaderId)=0
Attaches a shader to a program.
virtual void updateShaderParameters(Renderer *renderer, int contextIdx) override
Update shader parameters.
File system singleton class.
Definition: FileSystem.h:14