diff options
author | David Walter Seikel | 2014-05-03 18:33:58 +1000 |
---|---|---|
committer | David Walter Seikel | 2014-05-03 18:33:58 +1000 |
commit | 3c0fb329ecc4a719bd8d80257298d08f80b1bfd3 (patch) | |
tree | a0bb12ea6772588b90b0d26c855aeb802b6e56c3 /src/extantz/extantz.h | |
parent | Remove Evas_3d example stuff from GuiLua, now that it's in extantz. (diff) | |
download | SledjHamr-3c0fb329ecc4a719bd8d80257298d08f80b1bfd3.zip SledjHamr-3c0fb329ecc4a719bd8d80257298d08f80b1bfd3.tar.gz SledjHamr-3c0fb329ecc4a719bd8d80257298d08f80b1bfd3.tar.bz2 SledjHamr-3c0fb329ecc4a719bd8d80257298d08f80b1bfd3.tar.xz |
Move non GL_View stuff from gld -> ourGlobals. Plus some white space fixes.
Diffstat (limited to 'src/extantz/extantz.h')
-rw-r--r-- | src/extantz/extantz.h | 50 |
1 files changed, 25 insertions, 25 deletions
diff --git a/src/extantz/extantz.h b/src/extantz/extantz.h index b91124e..fab6708 100644 --- a/src/extantz/extantz.h +++ b/src/extantz/extantz.h | |||
@@ -161,23 +161,13 @@ typedef struct _Scene_Data | |||
161 | 161 | ||
162 | } Scene_Data; | 162 | } Scene_Data; |
163 | 163 | ||
164 | // GL related data here. | 164 | // Elm GL view related data here. |
165 | struct _GLData | 165 | struct _GLData |
166 | { | 166 | { |
167 | Evas_Object *win, *winwin; | 167 | Evas_Object *winwin; |
168 | Evas_Object *elmGl; | ||
169 | Evas_GL_API *glApi; | ||
168 | 170 | ||
169 | Ecore_Evas *ee; | ||
170 | Evas *canvas; | ||
171 | |||
172 | Evas_Object *elmGl; | ||
173 | Evas_GL_API *glApi; | ||
174 | |||
175 | GLuint program; | ||
176 | GLuint vtx_shader; | ||
177 | GLuint fgmt_shader; | ||
178 | int scr_w, scr_h; // The size of the screen. | ||
179 | int win_w, win_h; // The size of the window. | ||
180 | int win_x, win_y; // The position of the window. | ||
181 | int sfc_w, sfc_h; // This is what Irrlicht is using, size of the GL image surface / glview. | 171 | int sfc_w, sfc_h; // This is what Irrlicht is using, size of the GL image surface / glview. |
182 | int img_w, img_h; // Size of the viewport. DON'T reuse sfc_* here. Despite the fact that sfc_* is only used in the init when Irricht is disabled? WTF? | 172 | int img_w, img_h; // Size of the viewport. DON'T reuse sfc_* here. Despite the fact that sfc_* is only used in the init when Irricht is disabled? WTF? |
183 | int useIrr : 1; | 173 | int useIrr : 1; |
@@ -185,9 +175,6 @@ struct _GLData | |||
185 | int gearsInited : 1; | 175 | int gearsInited : 1; |
186 | int resized : 1; | 176 | int resized : 1; |
187 | 177 | ||
188 | Evas_Object *bx;//, *r1; | ||
189 | Ecore_Animator *animator; | ||
190 | |||
191 | IrrlichtDevice *device; | 178 | IrrlichtDevice *device; |
192 | IVideoDriver *driver; | 179 | IVideoDriver *driver; |
193 | ISceneManager *smgr; | 180 | ISceneManager *smgr; |
@@ -195,7 +182,11 @@ struct _GLData | |||
195 | 182 | ||
196 | cameraMove *move; | 183 | cameraMove *move; |
197 | 184 | ||
198 | // Gear Stuff | 185 | #if DO_GEARS |
186 | GLuint program; | ||
187 | GLuint vtx_shader; | ||
188 | GLuint fgmt_shader; | ||
189 | |||
199 | GLfloat view_rotx; | 190 | GLfloat view_rotx; |
200 | GLfloat view_roty; | 191 | GLfloat view_roty; |
201 | GLfloat view_rotz; | 192 | GLfloat view_rotz; |
@@ -212,16 +203,25 @@ struct _GLData | |||
212 | 203 | ||
213 | GLfloat proj[16]; | 204 | GLfloat proj[16]; |
214 | GLfloat light[3]; | 205 | GLfloat light[3]; |
206 | #endif | ||
215 | }; | 207 | }; |
216 | 208 | ||
217 | typedef struct _globals | 209 | typedef struct _globals |
218 | { | 210 | { |
219 | Evas *evas; | 211 | // Ecore_Evas *ee; |
212 | Evas *evas; | ||
220 | Evas_Object *win; // Our Elm window. | 213 | Evas_Object *win; // Our Elm window. |
221 | Evas_Object *tb; // Our Elm toolbar. | 214 | Evas_Object *tb; // Our Elm toolbar. |
215 | Evas_Object *bx; // Our box. | ||
222 | Eina_Clist widgets; // Our windows widgets. | 216 | Eina_Clist widgets; // Our windows widgets. |
223 | int logDom; // Our logging domain. | 217 | int logDom; // Our logging domain. |
224 | 218 | ||
219 | int scr_w, scr_h; // The size of the screen. | ||
220 | int win_w, win_h; // The size of the window. | ||
221 | int win_x, win_y; // The position of the window. | ||
222 | |||
223 | Ecore_Animator *animator; | ||
224 | |||
225 | struct _GLData gld; | 225 | struct _GLData gld; |
226 | Scene_Data *scene; | 226 | Scene_Data *scene; |
227 | } globals; | 227 | } globals; |
@@ -233,7 +233,7 @@ void gears_init(GLData *gld); | |||
233 | void drawGears(GLData *gld); | 233 | void drawGears(GLData *gld); |
234 | void free_gear(Gear *gear); | 234 | void free_gear(Gear *gear); |
235 | 235 | ||
236 | EPhysics_World *ephysicsAdd(GLData *gld); | 236 | EPhysics_World *ephysicsAdd(globals *ourGlobals); |
237 | 237 | ||
238 | EAPI int startIrr(GLData *gld); | 238 | EAPI int startIrr(GLData *gld); |
239 | EAPI void drawIrr_start(GLData *gld); | 239 | EAPI void drawIrr_start(GLData *gld); |
@@ -246,12 +246,12 @@ void Evas_3D_Demo_fini(globals *ourGlobals); | |||
246 | 246 | ||
247 | void cameraAdd(Evas_Object *win, GLData *gld); | 247 | void cameraAdd(Evas_Object *win, GLData *gld); |
248 | 248 | ||
249 | Evas_Object *fang_win_add(GLData *gld); | 249 | Evas_Object *fang_win_add(globals *ourGlobals); |
250 | void fang_win_complete(GLData *gld, Evas_Object *win, int x, int y, int w, int h); | 250 | void fang_win_complete(globals *ourGlobals, Evas_Object *win, int x, int y, int w, int h); |
251 | void overlay_add(GLData *gld); | 251 | void overlay_add(globals *ourGlobals); |
252 | 252 | ||
253 | void chat_add(GLData *gld); | 253 | void chat_add(globals *ourGlobals); |
254 | void woMan_add(GLData *gld); | 254 | void woMan_add(globals *ourGlobals); |
255 | 255 | ||
256 | 256 | ||
257 | #ifdef __cplusplus | 257 | #ifdef __cplusplus |