Change CMakeLists.txt to add 2d_game project, and added irrKlang to LIBS.

Added irrKlang.dll and ikpMP2.dll to dlls folder.  Added irrKlang as a
sub-folder under includes.  Added irrKlang.lib to lib folder.  At this point
running cmake gave an error it couldn't find source files under 2d_game.
Moved 2d_game source up one folder level, then cmake found the files.
This commit is contained in:
rich_b
2020-06-23 14:39:31 -04:00
parent 68ea5ee345
commit a694c848c7
96 changed files with 3294 additions and 3 deletions

View File

@@ -1,48 +0,0 @@
/*******************************************************************
** This code is part of Breakout.
**
** Breakout is free software: you can redistribute it and/or modify
** it under the terms of the CC BY 4.0 license as published by
** Creative Commons, either version 4 of the License, or (at your
** option) any later version.
******************************************************************/
#ifndef SHADER_H
#define SHADER_H
#include <string>
#include <glad/glad.h>
#include <glm/glm.hpp>
#include <glm/gtc/type_ptr.hpp>
// General purpsoe shader object. Compiles from file, generates
// compile/link-time error messages and hosts several utility
// functions for easy management.
class Shader
{
public:
// state
unsigned int ID;
// constructor
Shader() { }
// sets the current shader as active
Shader &Use();
// compiles the shader from given source code
void Compile(const char *vertexSource, const char *fragmentSource, const char *geometrySource = nullptr); // note: geometry source code is optional
// utility functions
void SetFloat (const char *name, float value, bool useShader = false);
void SetInteger (const char *name, int value, bool useShader = false);
void SetVector2f (const char *name, float x, float y, bool useShader = false);
void SetVector2f (const char *name, const glm::vec2 &value, bool useShader = false);
void SetVector3f (const char *name, float x, float y, float z, bool useShader = false);
void SetVector3f (const char *name, const glm::vec3 &value, bool useShader = false);
void SetVector4f (const char *name, float x, float y, float z, float w, bool useShader = false);
void SetVector4f (const char *name, const glm::vec4 &value, bool useShader = false);
void SetMatrix4 (const char *name, const glm::mat4 &matrix, bool useShader = false);
private:
// checks if compilation or linking failed and if so, print the error logs
void checkCompileErrors(unsigned int object, std::string type);
};
#endif