Shader: Throw on compile/link error, and print info logs
Also let go of the startup debug prints when compiling. The engine will now tell us properly which shader fails at which part.
This commit is contained in:
parent
680e407a38
commit
f2d2a1886f
2 changed files with 77 additions and 39 deletions
|
@ -44,8 +44,11 @@ protected:
|
|||
~Shader();
|
||||
|
||||
void init(const unsigned char *vert, int vertSize,
|
||||
const unsigned char *frag, int fragSize);
|
||||
void initFromFile(const char *vertFile, const char *fragFile);
|
||||
const unsigned char *frag, int fragSize,
|
||||
const char *vertName, const char *fragName,
|
||||
const char *programName);
|
||||
void initFromFile(const char *vertFile, const char *fragFile,
|
||||
const char *programName);
|
||||
|
||||
static void setVec4Uniform(GLint location, const Vec4 &vec);
|
||||
static void setTexUniform(GLint location, unsigned unitIndex, TEX::ID texture);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue