-
Notifications
You must be signed in to change notification settings - Fork 0
/
view.h
62 lines (55 loc) · 1.08 KB
/
view.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 _VIEW_H_
#define _VIEW_H_
#include <cmath>
#include <vector>
#include <X11/Xlib.h>
#include <X11/keysym.h>
#include <GL/glx.h>
#include <iostream>
#include <cstdlib>
#include "game.h"
#include <string>
#include <string.h>
#include <unistd.h>
#include "charlesE.h"
#include "nickG.h"
#include "lizandroP.h"
#include "map.h"
#define PI 3.14159
using namespace std;
class Game;
class Mob;
class View
{
private:
int width;
int height;
int is3D;
GLdouble depth;
Display *dpy;
Window root;
Window win;
GLXContext glc;
Game *game;
float ox,oy,oz;
int wOverride, hOverride;
unsigned int mobTex, skyTex, Win, Lose,
keys, sheet, wallTex[2], floorTex, logo;
public:
View(Game *g, int w = 0, int h = 0);
void InitWindow();
void cleanupXWindows(void);
void set_title(void);
void ShowCursor(const int onoff);
void CenterCursor();
Display *GetDisplay();
int GetWidth();
int GetHeight();
void Render();
void SwitchTo3D();
void SwitchTo2D();
void Lighting();
void HUD();
~View();
};
#endif