Mercurial > hg > forks > gldragon
annotate dmrender.h @ 91:4df8a7337e3e
Add simple 32bit texture version.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Mon, 18 Jan 2021 12:23:48 +0200 |
parents | cc1c35357e39 |
children | 28dd29f3a65f |
rev | line source |
---|---|
62
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
1 // |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
2 // GLDragon - OpenGL PLY model viewer / simple benchmark |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
3 // -- Basic renderer template |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
4 // Programmed and designed by Matti 'ccr' Hämäläinen <ccr@tnsp.org> |
76 | 5 // (C) Copyright 2019-2020 Tecnic Software productions (TNSP) |
62
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
6 // |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
7 // See file "COPYING" for license information. |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
8 // |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
9 #ifndef DMRENDER_H |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
10 #define DMRENDER_H 1 |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
11 |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
12 #include "dmscene.h" |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
13 #include <SDL.h> |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
14 |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
15 |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
16 struct DMSimpleRenderer |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
17 { |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
18 bool useShaders; |
63
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
19 int windowWidth, windowHeight; |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
20 SDL_Window *sdlWindow; |
62
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
21 |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
22 DMSimpleRenderer() |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
23 { |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
24 useShaders = false; |
63
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
25 sdlWindow = NULL; |
62
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
26 } |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
27 |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
28 virtual bool checkErrors(void) |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
29 { |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
30 return true; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
31 } |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
32 |
63
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
33 virtual bool initRenderer1(const char *title, |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
34 const int width, const int height, |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
35 const int sdlWindowHPos, const int sdlWindowVPos, |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
36 const int sdlFlags) |
62
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
37 { |
63
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
38 windowWidth = width; |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
39 windowHeight = height; |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
40 |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
41 if ((sdlWindow = SDL_CreateWindow(title, |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
42 sdlWindowHPos, sdlWindowVPos, |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
43 windowWidth, windowHeight, |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
44 sdlFlags)) == NULL) |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
45 { |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
46 dmError("Could not create SDL window: %s", |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
47 SDL_GetError()); |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
48 |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
49 return false; |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
50 } |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
51 else |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
52 return true; |
62
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
53 } |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
54 |
63
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
55 virtual bool initRenderer2(void) |
62
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
56 { |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
57 return false; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
58 } |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
59 |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
60 virtual void shutdownRenderer(void) |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
61 { |
63
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
62 if (sdlWindow != NULL) |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
63 SDL_DestroyWindow(sdlWindow); |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
64 } |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
65 |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
66 virtual void swapWindow(void) |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
67 { |
d6ffc59bb84d
Move more of the SDL and GL setup code to the renderer class.
Matti Hamalainen <ccr@tnsp.org>
parents:
62
diff
changeset
|
68 SDL_GL_SwapWindow(sdlWindow); |
62
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
69 } |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
70 |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
71 virtual void drawModel(const DMSimpleScene &scene, const DMModel &model, const float time) |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
72 { |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
73 (void) scene; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
74 (void) model; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
75 (void) time; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
76 } |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
77 |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
78 virtual void drawScene(const DMSimpleScene &scene, const float time) |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
79 { |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
80 (void) scene; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
81 (void) time; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
82 } |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
83 |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
84 virtual bool compileModelShaders(DMModel &model) |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
85 { |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
86 (void) model; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
87 return false; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
88 } |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
89 |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
90 virtual bool compileSceneShaders(DMSimpleScene &scene) |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
91 { |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
92 if (useShaders) |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
93 { |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
94 for (DMModel &model : scene.models) |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
95 { |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
96 if (!compileModelShaders(model)) |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
97 return false; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
98 } |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
99 } |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
100 return true; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
101 } |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
102 |
77 | 103 virtual bool deleteModelShaders(DMModel &model) |
104 { | |
105 (void) model; | |
106 return false; | |
107 } | |
108 | |
109 virtual bool deleteSceneShaders(DMSimpleScene &scene) | |
110 { | |
111 if (useShaders) | |
112 { | |
113 for (DMModel &model : scene.models) | |
114 { | |
115 if (!deleteModelShaders(model)) | |
116 return false; | |
117 } | |
118 } | |
119 return true; | |
120 } | |
121 | |
62
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
122 virtual bool setupLight(const int n, DMLight &light) |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
123 { |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
124 (void) n; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
125 (void) light; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
126 return true; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
127 } |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
128 |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
129 virtual bool setupLights(DMSimpleScene &scene) |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
130 { |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
131 for (size_t n = 0; n < scene.lights.size(); n++) |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
132 { |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
133 if (!setupLight(n, scene.lights[n])) |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
134 return false; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
135 } |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
136 return true; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
137 } |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
138 |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
139 virtual bool setupCamera(DMCamera &camera) |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
140 { |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
141 (void) camera; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
142 return true; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
143 } |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
144 |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
145 virtual bool animate(DMSimpleScene &scene, const float time) |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
146 { |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
147 (void) scene; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
148 (void) time; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
149 return true; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
150 } |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
151 }; |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
152 |
baccf2044289
Move the OpenGL rendering, setup etc. into a separate module/class, perhaps
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
153 #endif |