summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Schmidt <s.schmidt@samsung.com>2014-11-17 16:47:15 +0100
committerStefan Schmidt <s.schmidt@samsung.com>2014-11-17 16:47:15 +0100
commitf059aa24978580b623237c7e1c41d6d431d96780 (patch)
treedea16042b362a6c0d7ff4b1a0342211c59e2ada1
parent233317221d844e4818f830590d78017408b9d9fb (diff)
examples/evas-3d-shooter: Rename varibales to avopid shadowing
Scene is used as local variable in a lot places so we rename the global scene here.
-rw-r--r--src/examples/evas/shooter/evas-3d-shooter.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/examples/evas/shooter/evas-3d-shooter.c b/src/examples/evas/shooter/evas-3d-shooter.c
index b13aa11381..a5fcc91f9d 100644
--- a/src/examples/evas/shooter/evas-3d-shooter.c
+++ b/src/examples/evas/shooter/evas-3d-shooter.c
@@ -23,7 +23,7 @@
23#define GUN_DIR_Z 105 23#define GUN_DIR_Z 105
24#define GUN_SPEED 0.001 24#define GUN_SPEED 0.001
25 25
26Evas_3D_Scene *scene = NULL; 26Evas_3D_Scene *global_scene = NULL;
27Ecore_Evas *ecore_evas = NULL; 27Ecore_Evas *ecore_evas = NULL;
28static float angle_camera = 0.0f; 28static float angle_camera = 0.0f;
29static float angle_eagle = 180.0f; 29static float angle_eagle = 180.0f;
@@ -635,14 +635,14 @@ _continue_camera(void *data)
635 635
636/* calculate new angle of rotation */ 636/* calculate new angle of rotation */
637static void 637static void
638_reload_camera(void *data, Evas *evas EINA_UNUSED, Evas_Object *eo EINA_UNUSED, void *event_info) 638_reload_camera(void *data, Evas *e EINA_UNUSED, Evas_Object *eo EINA_UNUSED, void *event_info)
639{ 639{
640 Evas_Event_Mouse_Down *ev = event_info; 640 Evas_Event_Mouse_Down *ev = event_info;
641 Evas_3D_Node *n; 641 Evas_3D_Node *n;
642 Evas_3D_Mesh *m; 642 Evas_3D_Mesh *m;
643 Evas_Real s, t; 643 Evas_Real s, t;
644 644
645 eo_do(scene, 645 eo_do(global_scene,
646 evas_3d_scene_pick(ev->canvas.x, ev->canvas.y, &n, &m, &s, &t)); 646 evas_3d_scene_pick(ev->canvas.x, ev->canvas.y, &n, &m, &s, &t));
647 647
648 d_angle_camera = 0; 648 d_angle_camera = 0;
@@ -1375,9 +1375,9 @@ _mesh_setup_snake(Scene_Data *data)
1375void 1375void
1376_scene_setup(Scene_Data *data) 1376_scene_setup(Scene_Data *data)
1377{ 1377{
1378 scene = eo_add(EVAS_3D_SCENE_CLASS, evas); 1378 global_scene = eo_add(EVAS_3D_SCENE_CLASS, evas);
1379 1379
1380 eo_do(scene, 1380 eo_do(global_scene,
1381 evas_3d_scene_size_set(WIDTH, HEIGHT), 1381 evas_3d_scene_size_set(WIDTH, HEIGHT),
1382 evas_3d_scene_background_color_set(0.5, 0.5, 0.5, 0.0)); 1382 evas_3d_scene_background_color_set(0.5, 0.5, 0.5, 0.0));
1383 1383
@@ -1446,7 +1446,7 @@ _scene_setup(Scene_Data *data)
1446 1446
1447 _mesh_aabb(&data->mesh_cube, data); 1447 _mesh_aabb(&data->mesh_cube, data);
1448 1448
1449 eo_do(scene, 1449 eo_do(global_scene,
1450 evas_3d_scene_root_node_set(data->root_node), 1450 evas_3d_scene_root_node_set(data->root_node),
1451 evas_3d_scene_camera_node_set(data->camera_node)); 1451 evas_3d_scene_camera_node_set(data->camera_node));
1452 1452
@@ -1486,7 +1486,7 @@ main(void)
1486 1486
1487 /* Set the image object as render target for 3D scene. */ 1487 /* Set the image object as render target for 3D scene. */
1488 eo_do(image, 1488 eo_do(image,
1489 evas_obj_image_scene_set(scene)); 1489 evas_obj_image_scene_set(global_scene));
1490 1490
1491 evas_object_focus_set(image, EINA_TRUE); 1491 evas_object_focus_set(image, EINA_TRUE);
1492 1492