-
Notifications
You must be signed in to change notification settings - Fork 2
/
RenderTask.h
62 lines (47 loc) · 1.52 KB
/
RenderTask.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
#ifndef RENDER_TASK_H_INCLUDED
#define RENDER_TASK_H_INCLUDED
#include "engine.h"
class CRenderTask : public ITask
{
public:
CRenderTask();
virtual ~CRenderTask();
bool Start();
void Update();
void Stop();
private:
float speed; //360 stopni/s
int lastTime;
float angle;
void animate();
void putpixel(SDL_Surface *surface, int x, int y, Uint32 pixel);
Uint32 getpixel( SDL_Surface *surface, int x, int y );
void LoadTexture(const char * image_path, GLuint* texture);
GLuint LoadShaders(const char * vertex_file_path,const char * fragment_file_path);
GLuint locTextureMap0;
GLuint locTextureMap1;
GLuint locTextureMap2;
GLuint programID;
GLuint programID2;
GLuint sunshader;
std::vector<glm::vec3> g_vertex_buffer_data;
std::vector<glm::vec2> g_uv_buffer_data;
std::vector<glm::vec3> g_normal_buffer_data;
glm::mat4 VP;
glm::mat4 Projection;
glm::mat4 View ;
GLuint MatrixID;
GLuint ModelMatrixID;
GLuint ViewID;
GLuint lightID1;
GLuint VertexArrayID;
GLuint vertexbuffer;
GLuint uvbuffer;
GLuint normalbuffer;
CMMPointer<CMeshObject> logo3d;
CMMPointer<CMeshObject> logo3d2;
CMMPointer<CMeshObject> sun;
//CMeshObject* logo3d;
AUTO_SIZE;
};
#endif // RENDERTASK_H_INCLUDED