-
Notifications
You must be signed in to change notification settings - Fork 0
/
heva.h
executable file
·73 lines (55 loc) · 1.15 KB
/
heva.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
63
64
65
66
67
68
69
70
71
72
73
//
// Created by scaled
//
//#define WEBCAM_ENABLE
//#define DEBUG_GEOMETRY
//#define X11_TRANSPARENT_WINDOW
#define COLLIDERS_FROM_MODEL
#pragma once
#include <Urho3D/Engine/Application.h>
namespace Urho3D
{
class Node;
class Scene;
class Sprite;
class Engine;
class Viewport;
}
using namespace Urho3D;
#ifdef X11_TRANSPARENT_WINDOW
class Heva : public Urho3D::Object
{
URHO3D_OBJECT(Heva, Urho3D::Object);
public:
/// Construct.
Heva(Context* context, void* window);
void Setup();
void Start();
void Stop();
void HandleUpdate();
void HandleKeyUp(int key);
private:
Urho3D::Scene* scene_;
Urho3D::Engine* engine_;
Urho3D::Viewport* viewport_;
void* window_ = NULL;
};
#else
class Heva : public Application
{
// Enable type information.
URHO3D_OBJECT(Heva, Application);
public:
/// Construct.
Heva(Context* context);
void Setup();
void Start();
void Stop();
private:
Urho3D::Scene* scene_;
Urho3D::Node* cameraNode_;
void HandleUpdate(StringHash eventType, VariantMap& eventData);
void HandleKeyUp(StringHash eventType, VariantMap& eventData);
void HandlePostRenderUpdate(StringHash eventType, VariantMap& eventData);
};
#endif