2020-12-31 12:58:39 +00:00
|
|
|
#ifndef GRAPHICS_H
|
|
|
|
#define GRAPHICS_H
|
|
|
|
|
2021-01-07 05:12:36 +00:00
|
|
|
#ifdef __APPLE__
|
|
|
|
#include <OpenGL/gl.h>
|
|
|
|
#else
|
2020-12-31 12:58:39 +00:00
|
|
|
#include <GL/gl.h>
|
2021-01-07 05:12:36 +00:00
|
|
|
#endif
|
|
|
|
|
2020-12-31 12:58:39 +00:00
|
|
|
#include <glm/vec2.hpp>
|
|
|
|
|
2021-02-04 14:58:03 +00:00
|
|
|
#include <cv.hpp>
|
|
|
|
|
|
|
|
extern GLuint transUniform;
|
|
|
|
|
2020-12-31 12:58:39 +00:00
|
|
|
void initGraphics ();
|
|
|
|
|
|
|
|
void graphicsFrame ();
|
|
|
|
|
2021-01-01 16:20:09 +00:00
|
|
|
void initBuffers (GLuint* vaoNum);
|
|
|
|
|
2021-02-04 14:58:03 +00:00
|
|
|
void initTexture (GLuint* texNum, unsigned char* buffer, size_t bufferLength);
|
2021-01-01 08:23:44 +00:00
|
|
|
|
|
|
|
void initShader();
|
|
|
|
|
2020-12-31 12:58:39 +00:00
|
|
|
void printShaderCompileLog(GLuint shader);
|
|
|
|
|
2021-02-04 14:58:03 +00:00
|
|
|
void updateModel(struct FaceData faceData);
|
2020-12-31 12:58:39 +00:00
|
|
|
|
|
|
|
#endif
|