MCPcopy Create free account
hub / github.com/Hopson97/HopsonCraft / createProgram

Function createProgram

Source/Shaders/Shader_Loader.cpp:47–57  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

45 }
46
47 GLuint createProgram(GLuint vertexShaderID, GLuint fragmentShaderID)
48 {
49 auto id = glCreateProgram();
50
51 glAttachShader(id, vertexShaderID);
52 glAttachShader(id, fragmentShaderID);
53
54 glLinkProgram(id);
55
56 return id;
57 }
58
59 GLuint loadShader(const std::string& vertexShaderFile, const std::string& fragmentShaderFile)
60 {

Callers 1

loadShaderFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected