aboutsummaryrefslogtreecommitdiffstats
path: root/src/examples/evas/evas-3d-aabb.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/examples/evas/evas-3d-aabb.c')
-rw-r--r--src/examples/evas/evas-3d-aabb.c32
1 files changed, 15 insertions, 17 deletions
diff --git a/src/examples/evas/evas-3d-aabb.c b/src/examples/evas/evas-3d-aabb.c
index c8d906c881..59c9a8b703 100644
--- a/src/examples/evas/evas-3d-aabb.c
+++ b/src/examples/evas/evas-3d-aabb.c
@@ -142,17 +142,16 @@ main(void)
evas = ecore_evas_get(ecore_evas);
- scene = eo_add(EVAS_CANVAS3D_SCENE_CLASS, evas);
+ eo_add(scene, EVAS_CANVAS3D_SCENE_CLASS, evas);
- root_node = eo_add(EVAS_CANVAS3D_NODE_CLASS, evas,
+ eo_add(root_node, EVAS_CANVAS3D_NODE_CLASS, evas,
evas_canvas3d_node_constructor(EVAS_CANVAS3D_NODE_TYPE_NODE));
- camera = eo_add(EVAS_CANVAS3D_CAMERA_CLASS, evas);
+ eo_add(camera, EVAS_CANVAS3D_CAMERA_CLASS, evas);
eo_do(camera,
evas_canvas3d_camera_projection_perspective_set(60.0, 1.0, 1.0, 500.0));
- camera_node =
- eo_add(EVAS_CANVAS3D_NODE_CLASS, evas,
+ eo_add(camera_node, EVAS_CANVAS3D_NODE_CLASS, evas,
evas_canvas3d_node_constructor(EVAS_CANVAS3D_NODE_TYPE_CAMERA));
eo_do(camera_node,
evas_canvas3d_node_camera_set(camera));
@@ -162,15 +161,14 @@ main(void)
evas_canvas3d_node_position_set(100.0, 50.0, 20.0),
evas_canvas3d_node_look_at_set(EVAS_CANVAS3D_SPACE_PARENT, 0.0, 0.0, 20.0,
EVAS_CANVAS3D_SPACE_PARENT, 0.0, 0.0, 1.0));
- light = eo_add(EVAS_CANVAS3D_LIGHT_CLASS, evas);
+ eo_add(light, EVAS_CANVAS3D_LIGHT_CLASS, evas);
eo_do(light,
evas_canvas3d_light_ambient_set(1.0, 1.0, 1.0, 1.0),
evas_canvas3d_light_diffuse_set(1.0, 1.0, 1.0, 1.0),
evas_canvas3d_light_specular_set(1.0, 1.0, 1.0, 1.0),
evas_canvas3d_light_directional_set(EINA_TRUE));
- light_node =
- eo_add(EVAS_CANVAS3D_NODE_CLASS, evas,
+ eo_add(light_node, EVAS_CANVAS3D_NODE_CLASS, evas,
evas_canvas3d_node_constructor(EVAS_CANVAS3D_NODE_TYPE_LIGHT));
eo_do(light_node,
evas_canvas3d_node_light_set(light),
@@ -180,15 +178,15 @@ main(void)
eo_do(root_node,
evas_canvas3d_node_member_add(light_node));
- mesh = eo_add(EVAS_CANVAS3D_MESH_CLASS, evas);
- material = eo_add(EVAS_CANVAS3D_MATERIAL_CLASS, evas);
+ eo_add(mesh, EVAS_CANVAS3D_MESH_CLASS, evas);
+ eo_add(material, EVAS_CANVAS3D_MATERIAL_CLASS, evas);
eo_do(mesh,
efl_file_set(model_path, NULL),
evas_canvas3d_mesh_frame_material_set(0, material),
evas_canvas3d_mesh_shade_mode_set(EVAS_CANVAS3D_SHADE_MODE_PHONG));
- texture = eo_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas);
+ eo_add(texture, EVAS_CANVAS3D_TEXTURE_CLASS, evas);
eo_do(texture,
evas_canvas3d_texture_file_set(image_path, NULL),
evas_canvas3d_texture_filter_set(EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST,
@@ -209,19 +207,19 @@ main(void)
1.0, 1.0, 1.0, 1.0),
evas_canvas3d_material_shininess_set(50.0));
- mesh_node = eo_add(EVAS_CANVAS3D_NODE_CLASS, evas,
+ eo_add(mesh_node, EVAS_CANVAS3D_NODE_CLASS, evas,
evas_canvas3d_node_constructor(EVAS_CANVAS3D_NODE_TYPE_MESH));
- mesh_box_node = eo_add(EVAS_CANVAS3D_NODE_CLASS, evas,
+ eo_add(mesh_box_node, EVAS_CANVAS3D_NODE_CLASS, evas,
evas_canvas3d_node_constructor(EVAS_CANVAS3D_NODE_TYPE_MESH));
- material_box = eo_add(EVAS_CANVAS3D_MATERIAL_CLASS, evas);
+ eo_add(material_box, EVAS_CANVAS3D_MATERIAL_CLASS, evas);
eo_do(material_box, evas_canvas3d_material_enable_set(EVAS_CANVAS3D_MATERIAL_ATTRIB_DIFFUSE, EINA_TRUE));
- cube = eo_add(EVAS_CANVAS3D_PRIMITIVE_CLASS, evas);
+ eo_add(cube, EVAS_CANVAS3D_PRIMITIVE_CLASS, evas);
eo_do(cube,
evas_canvas3d_primitive_form_set(EVAS_CANVAS3D_MESH_PRIMITIVE_CUBE));
- mesh_box = eo_add(EVAS_CANVAS3D_MESH_CLASS, evas);
+ eo_add(mesh_box, EVAS_CANVAS3D_MESH_CLASS, evas);
eo_do(mesh_box,
evas_canvas3d_mesh_from_primitive_set(0, cube),
evas_canvas3d_mesh_vertex_assembly_set(EVAS_CANVAS3D_VERTEX_ASSEMBLY_LINES),
@@ -244,7 +242,7 @@ main(void)
evas_canvas3d_scene_camera_node_set(camera_node),
evas_canvas3d_scene_size_set(WIDTH, HEIGHT));
- background = eo_add(EVAS_RECTANGLE_CLASS, evas);
+ eo_add(background, EVAS_RECTANGLE_CLASS, evas);
eo_do(background,
efl_gfx_color_set(0, 0, 0, 255),
efl_gfx_size_set(WIDTH, HEIGHT),