-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathWtrCamera.h
More file actions
61 lines (47 loc) · 1.11 KB
/
WtrCamera.h
File metadata and controls
61 lines (47 loc) · 1.11 KB
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
// WtrCamera.h: interface for the CWtrCamera class.
//
//////////////////////////////////////////////////////////////////////
#ifndef WTRCAMERA_H
#define WTRCAMERA_H
#include "common/wiskunde.h"
#include "Keys.h"
#define SPEED 1.0f
#define SPEED_REDUCE 0.5f
class __declspec(dllexport) CWtrCamera
{
private:
Matrix m_Viewmatrix;
Vector m_Position;
float m_fPitch;
float m_fRoll;
float m_fYaw;
float m_fVelocityX;
float m_fVelocityY;
float m_fVelocityZ;
float m_fFrameInterval;
int m_iCenterX, m_iCenterY;
bool m_bCaptureCursor;
void Reset();
void BuildViewmatrix();
void CalculateMovement();
void CalculateRotation();
void CalculateFrameInterval();
public:
CWtrCamera();
virtual ~CWtrCamera();
void MoveForward(float units);
void MoveRight(float units);
void MoveUp(float units);
void MoveX(float units);
void MoveY(float units);
void MoveZ(float units);
void Pitch(float degrees);
void Roll(float degrees);
void Yaw(float degrees);
void GetViewmatrix(float viewmatrix[4][4]);
void Update();
void SetCenter(int x, int y);
void SetCaptureCursor(bool value);
bool GetCaptureCursor();
};
#endif