Commit 6979141d authored by Sadman Kazi's avatar Sadman Kazi 🎸

Change include directives for third party libraries

parent a750f093
Pipeline #69 failed
......@@ -14,8 +14,8 @@ GNU General Public License for more details.
*/
#include "coreEngine.h"
#include <windows.h>
#include <iostream>
#include <thread>
CoreEngine::CoreEngine(std::string title, int width, int height) : m_title(title), m_width(width), m_height(height)
{
......@@ -100,13 +100,13 @@ void CoreEngine::run() {
if (render) {
this->render();
frames++;
}
else
Sleep(1); //delay the loop so that calculations are not made too often
} else {
std::this_thread::sleep_for(std::chrono::milliseconds(1)); //delay the loop so that calculations are not made too often
}
}
}
void CoreEngine::stop() {
m_isRunning = false;
}
\ No newline at end of file
}
......@@ -13,6 +13,9 @@ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
*/
#ifndef CORE_ENGINE_H_
#define CORE_ENGINE_H_
#include <string>
#include "window.h"
#include "time.h"
......@@ -39,3 +42,4 @@ private:
void render();
};
#endif // CORE_ENGINE_H_
......@@ -15,6 +15,7 @@ GNU General Public License for more details.
#include "input.h"
#include <stdlib.h>
#include <algorithm>
std::vector<SDL_Keycode> Input::currentKeys(0);
std::vector<SDL_Keycode> Input::downKeys(0);
......@@ -113,4 +114,4 @@ glm::vec2 Input::getMousePos() { //TODO: might consider switching to a custom ve
int x, y;
SDL_GetMouseState(&x, &y);
return glm::vec2(x, y);
}
\ No newline at end of file
}
......@@ -12,10 +12,10 @@ but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
*/
#ifndef INPUT_H_INCLUDED
#define INPUT_H_INCLUDED
#ifndef INPUT_H_
#define INPUT_H_
#include <sdl/SDL.h> //required for getting the keyboard inputs
#include <SDL2/SDL.h> //required for getting the keyboard inputs
#include <vector>
#include <glm/glm.hpp>
......@@ -44,4 +44,4 @@ private:
static std::vector<Uint8> upMouse; //store the mouse buttons released in the current frame
};
#endif INPUT_H_INCLUDED
\ No newline at end of file
#endif // INPUT_H_
......@@ -16,7 +16,7 @@ GNU General Public License for more details.
#define MESH_H
#include "vertex.h"
#include <glew/glew.h>
#include <GL/glew.h>
#include "obj_loader.h"
class Mesh
......@@ -42,4 +42,4 @@ private:
unsigned int m_drawCount; //stores how big it is, how much we want to draw
};
#endif MESH_H
\ No newline at end of file
#endif MESH_H
#include <glew/glew.h>
#include <GL/glew.h>
#include <string>
#include <unordered_map>
#include <glm/glm.hpp>
......
......@@ -14,7 +14,8 @@ GNU General Public License for more details.
*/
#include "window.h"
#include <glew/glew.h>
#include <SDL2/SDL.h>
#include <GL/glew.h>
#include <iostream>
#include <cassert>
......@@ -93,4 +94,4 @@ void Window::update() {
}
else
Input::update(NULL);
}
\ No newline at end of file
}
......@@ -13,8 +13,11 @@ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
*/
#ifndef WINDOW_H_
#define WINDOW_H_
#include <string>
#include <sdl\SDL.h>
#include <SDL2/SDL.h>
#include "input.h"
class Window
......@@ -39,3 +42,5 @@ private:
bool m_isClosed;
int m_width, m_height;
};
#endif // WINDOW_H_
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment