summaryrefslogtreecommitdiff
path: root/src/examples/elementary/performance
diff options
context:
space:
mode:
Diffstat (limited to 'src/examples/elementary/performance')
-rw-r--r--src/examples/elementary/performance/camera_light.c14
-rw-r--r--src/examples/elementary/performance/graphical.c20
-rw-r--r--src/examples/elementary/performance/performance.c160
-rw-r--r--src/examples/elementary/performance/tools_private.h8
4 files changed, 106 insertions, 96 deletions
diff --git a/src/examples/elementary/performance/camera_light.c b/src/examples/elementary/performance/camera_light.c
index 3c8f93b..98be8c2 100644
--- a/src/examples/elementary/performance/camera_light.c
+++ b/src/examples/elementary/performance/camera_light.c
@@ -226,7 +226,7 @@ init_panel_camera_light(Evas_Object *win, Eo *camera_node, Eo *light_node, doubl
226} 226}
227 227
228static void 228static void
229_camera_light_changeX_cb(void *data, Evas_Object *obj, void *event_info) 229_camera_light_changeX_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
230{ 230{
231 Evas_Real x, y, z; 231 Evas_Real x, y, z;
232 232
@@ -238,7 +238,7 @@ _camera_light_changeX_cb(void *data, Evas_Object *obj, void *event_info)
238 } 238 }
239} 239}
240static void 240static void
241_camera_light_changeY_cb(void *data, Evas_Object *obj, void *event_info) 241_camera_light_changeY_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
242{ 242{
243 Evas_Real x, y, z; 243 Evas_Real x, y, z;
244 244
@@ -250,7 +250,7 @@ _camera_light_changeY_cb(void *data, Evas_Object *obj, void *event_info)
250 } 250 }
251} 251}
252static void 252static void
253_camera_light_changeZ_cb(void *data, Evas_Object *obj, void *event_info) 253_camera_light_changeZ_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
254{ 254{
255 Evas_Real x, y, z; 255 Evas_Real x, y, z;
256 256
@@ -262,7 +262,7 @@ _camera_light_changeZ_cb(void *data, Evas_Object *obj, void *event_info)
262 } 262 }
263} 263}
264static void 264static void
265_camera_light_angle_change_cb(void *data, Evas_Object *obj, void *event_info) 265_camera_light_angle_change_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
266{ 266{
267 Axis_Key *key = evas_object_data_get(obj, axiskeys); 267 Axis_Key *key = evas_object_data_get(obj, axiskeys);
268 Evas_Real aw = 0; 268 Evas_Real aw = 0;
@@ -274,7 +274,7 @@ _camera_light_angle_change_cb(void *data, Evas_Object *obj, void *event_info)
274 } 274 }
275} 275}
276static void 276static void
277_camera_light_axisX_change_cb(void *data, Evas_Object *obj, void *event_info) 277_camera_light_axisX_change_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
278{ 278{
279 Evas_Object *fsa = (Evas_Object*)data; 279 Evas_Object *fsa = (Evas_Object*)data;
280 Axis_Key *key = evas_object_data_get(fsa, axiskeys); 280 Axis_Key *key = evas_object_data_get(fsa, axiskeys);
@@ -282,7 +282,7 @@ _camera_light_axisX_change_cb(void *data, Evas_Object *obj, void *event_info)
282 key->x = elm_spinner_value_get(obj); 282 key->x = elm_spinner_value_get(obj);
283} 283}
284static void 284static void
285_camera_light_axisY_change_cb(void *data, Evas_Object *obj, void *event_info) 285_camera_light_axisY_change_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
286{ 286{
287 Evas_Object *fsa = (Evas_Object*)data; 287 Evas_Object *fsa = (Evas_Object*)data;
288 Axis_Key *key = evas_object_data_get(fsa, axiskeys); 288 Axis_Key *key = evas_object_data_get(fsa, axiskeys);
@@ -290,7 +290,7 @@ _camera_light_axisY_change_cb(void *data, Evas_Object *obj, void *event_info)
290 key->y = elm_spinner_value_get(obj); 290 key->y = elm_spinner_value_get(obj);
291} 291}
292static void 292static void
293_camera_light_axisZ_change_cb(void *data, Evas_Object *obj, void *event_info) 293_camera_light_axisZ_change_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
294{ 294{
295 Evas_Object *fsa = (Evas_Object*)data; 295 Evas_Object *fsa = (Evas_Object*)data;
296 Axis_Key *key = evas_object_data_get(fsa, axiskeys); 296 Axis_Key *key = evas_object_data_get(fsa, axiskeys);
diff --git a/src/examples/elementary/performance/graphical.c b/src/examples/elementary/performance/graphical.c
index 06959ea..3c7caa2 100644
--- a/src/examples/elementary/performance/graphical.c
+++ b/src/examples/elementary/performance/graphical.c
@@ -1,5 +1,9 @@
1#define EFL_EO_API_SUPPORT 1#ifndef EFL_EO_API_SUPPORT
2#define EFL_BETA_API_SUPPORT 2# define EFL_EO_API_SUPPORT
3#endif
4#ifndef EFL_BETA_API_SUPPORT
5# define EFL_BETA_API_SUPPORT
6#endif
3 7
4#include <math.h> 8#include <math.h>
5#include <stdlib.h> 9#include <stdlib.h>
@@ -323,7 +327,7 @@ _change_scene_setup()
323 } 327 }
324 else 328 else
325 { 329 {
326 efl_file_set(globalGraphical.mesh, globalGraphical.model_path, NULL); 330 efl_file_simple_load(globalGraphical.mesh, globalGraphical.model_path, NULL);
327 evas_canvas3d_mesh_frame_material_set(globalGraphical.mesh, 0, globalGraphical.material); 331 evas_canvas3d_mesh_frame_material_set(globalGraphical.mesh, 0, globalGraphical.material);
328 evas_canvas3d_mesh_shader_mode_set(globalGraphical.mesh, EVAS_CANVAS3D_SHADER_MODE_PHONG); 332 evas_canvas3d_mesh_shader_mode_set(globalGraphical.mesh, EVAS_CANVAS3D_SHADER_MODE_PHONG);
329 } 333 }
@@ -427,7 +431,7 @@ _init_scene(Evas_Object *img)
427 431
428 globalGraphical.material = efl_add(EVAS_CANVAS3D_MATERIAL_CLASS, globalGraphical.evas); 432 globalGraphical.material = efl_add(EVAS_CANVAS3D_MATERIAL_CLASS, globalGraphical.evas);
429 globalGraphical.texture = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, globalGraphical.evas); 433 globalGraphical.texture = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, globalGraphical.evas);
430 efl_file_set(globalGraphical.texture, "target_texture.png", NULL); 434 efl_file_simple_load(globalGraphical.texture, "target_texture.png", NULL);
431 evas_canvas3d_texture_filter_set(globalGraphical.texture, EVAS_CANVAS3D_TEXTURE_FILTER_LINEAR, EVAS_CANVAS3D_TEXTURE_FILTER_LINEAR); 435 evas_canvas3d_texture_filter_set(globalGraphical.texture, EVAS_CANVAS3D_TEXTURE_FILTER_LINEAR, EVAS_CANVAS3D_TEXTURE_FILTER_LINEAR);
432 evas_canvas3d_texture_wrap_set(globalGraphical.texture, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT); 436 evas_canvas3d_texture_wrap_set(globalGraphical.texture, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT);
433 evas_canvas3d_material_texture_set(globalGraphical.material, EVAS_CANVAS3D_MATERIAL_ATTRIB_DIFFUSE, globalGraphical.texture); 437 evas_canvas3d_material_texture_set(globalGraphical.material, EVAS_CANVAS3D_MATERIAL_ATTRIB_DIFFUSE, globalGraphical.texture);
@@ -460,7 +464,7 @@ _init_scene(Evas_Object *img)
460 } 464 }
461 else 465 else
462 { 466 {
463 efl_file_set(globalGraphical.mesh, globalGraphical.model_path, NULL); 467 efl_file_simple_load(globalGraphical.mesh, globalGraphical.model_path, NULL);
464 evas_canvas3d_mesh_frame_material_set(globalGraphical.mesh, 0, globalGraphical.material); 468 evas_canvas3d_mesh_frame_material_set(globalGraphical.mesh, 0, globalGraphical.material);
465 evas_canvas3d_mesh_shader_mode_set(globalGraphical.mesh, EVAS_CANVAS3D_SHADER_MODE_PHONG); 469 evas_canvas3d_mesh_shader_mode_set(globalGraphical.mesh, EVAS_CANVAS3D_SHADER_MODE_PHONG);
466 } 470 }
@@ -492,7 +496,7 @@ _init_scene(Evas_Object *img)
492} 496}
493 497
494static Eina_Bool 498static Eina_Bool
495_xml_attr_data(void *data, const char *key, const char *value) 499_xml_attr_data(void *data EINA_UNUSED, const char *key, const char *value)
496{ 500{
497 char *format = NULL, *tmp = NULL, *a = NULL; 501 char *format = NULL, *tmp = NULL, *a = NULL;
498 int i; 502 int i;
@@ -533,8 +537,8 @@ _xml_attr_data(void *data, const char *key, const char *value)
533} 537}
534 538
535static Eina_Bool 539static Eina_Bool
536_xml_get_data(void *data, Eina_Simple_XML_Type type, const char *content, 540_xml_get_data(void *data EINA_UNUSED, Eina_Simple_XML_Type type, const char *content,
537 unsigned offset, unsigned length) 541 unsigned offset EINA_UNUSED, unsigned length)
538{ 542{
539 char str[512]; 543 char str[512];
540 switch (type) 544 switch (type)
diff --git a/src/examples/elementary/performance/performance.c b/src/examples/elementary/performance/performance.c
index 0ed4c5f..cced019 100644
--- a/src/examples/elementary/performance/performance.c
+++ b/src/examples/elementary/performance/performance.c
@@ -19,9 +19,6 @@
19 * @endverbatim 19 * @endverbatim
20 */ 20 */
21 21
22#define EFL_EO_API_SUPPORT
23#define EFL_BETA_API_SUPPORT
24
25/*enable automation test*/ 22/*enable automation test*/
26#ifdef ENABLE_ATPORT 23#ifdef ENABLE_ATPORT
27 #include "at_port.h" 24 #include "at_port.h"
@@ -33,6 +30,12 @@
33#include <stdio.h> 30#include <stdio.h>
34#include <stdlib.h> 31#include <stdlib.h>
35 32
33#ifndef EFL_EO_API_SUPPORT
34# define EFL_EO_API_SUPPORT
35#endif
36#ifndef EFL_BETA_API_SUPPORT
37# define EFL_BETA_API_SUPPORT
38#endif
36 39
37#include <Eo.h> 40#include <Eo.h>
38#include <Evas.h> 41#include <Evas.h>
@@ -60,17 +63,15 @@ void _clear_buf(char *buf)
60 buf[i] = '\0'; 63 buf[i] = '\0';
61} 64}
62 65
63void _value_int_to_char(char *buf, int value, const char *description) 66Eina_Slstr * _value_int_to_char(int value, const char *description)
64{ 67{
65 _clear_buf(buf);
66 if (description) 68 if (description)
67 sprintf(buf, "%s %d", description, value); 69 return eina_slstr_printf("%s %d", description, value);
68 else 70 return eina_slstr_printf("%d", value);
69 sprintf(buf, "%d", value);
70} 71}
71 72
72static Eina_Bool 73static Eina_Bool
73_timer_update(void *data) 74_timer_update(void *data EINA_UNUSED)
74{ 75{
75 printf(" frame rate = %f fps\n", fps_frames / 10.0); 76 printf(" frame rate = %f fps\n", fps_frames / 10.0);
76 fps_frames = 0; 77 fps_frames = 0;
@@ -165,19 +166,19 @@ _on_mouse_down(void *data, Evas *e EINA_UNUSED, Evas_Object *obj,
165 } 166 }
166} 167}
167static void 168static void
168_btnstart_cb(void *data, Evas_Object *obj, void *event_info) 169_btnstart_cb(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
169{ 170{
170 globalGraphical.change_scene_setup(); 171 globalGraphical.change_scene_setup();
171} 172}
172 173
173static void 174static void
174_btnexit_cb(void *data, Evas_Object *obj, void *event_info) 175_btnexit_cb(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
175{ 176{
176 elm_exit(); 177 elm_exit();
177} 178}
178 179
179static void 180static void
180_btnstop_cb(void *data, Evas_Object *obj, void *event_info) 181_btnstop_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
181{ 182{
182 const char *status = NULL; 183 const char *status = NULL;
183 status = elm_object_text_get(obj); 184 status = elm_object_text_get(obj);
@@ -193,7 +194,7 @@ _btnstop_cb(void *data, Evas_Object *obj, void *event_info)
193 } 194 }
194} 195}
195static void 196static void
196_node_orientation_change_cb(void *data, Evas_Object *obj, void *event_info) 197_node_orientation_change_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
197{ 198{
198 Elm_Object_Item *it; 199 Elm_Object_Item *it;
199 Eina_List *l; 200 Eina_List *l;
@@ -211,7 +212,7 @@ _node_orientation_change_cb(void *data, Evas_Object *obj, void *event_info)
211 } 212 }
212} 213}
213static void 214static void
214_node_position_change_cb(void *data, Evas_Object *obj, void *event_info) 215_node_position_change_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
215{ 216{
216 Elm_Object_Item *it; 217 Elm_Object_Item *it;
217 Eina_List *l; 218 Eina_List *l;
@@ -229,7 +230,7 @@ _node_position_change_cb(void *data, Evas_Object *obj, void *event_info)
229 } 230 }
230} 231}
231static void 232static void
232_node_scale_change_cb(void *data, Evas_Object *obj, void *event_info) 233_node_scale_change_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
233{ 234{
234 Elm_Object_Item *it; 235 Elm_Object_Item *it;
235 Eina_List *l; 236 Eina_List *l;
@@ -247,9 +248,9 @@ _node_scale_change_cb(void *data, Evas_Object *obj, void *event_info)
247 } 248 }
248} 249}
249static void 250static void
250_countdec10_cb(void *data, Evas_Object *obj, void *event_info) 251_countdec10_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
251{ 252{
252 char buf[CONVERT]; 253 Eina_Slstr *buf;
253 int tmp; 254 int tmp;
254 255
255 globalGraphical.count -= 10; 256 globalGraphical.count -= 10;
@@ -257,187 +258,188 @@ _countdec10_cb(void *data, Evas_Object *obj, void *event_info)
257 else 258 else
258 tmp = ((globalGraphical.count + 1) * (globalGraphical.count + 1)); 259 tmp = ((globalGraphical.count + 1) * (globalGraphical.count + 1));
259 260
260 _value_int_to_char(buf, ((tmp <= 1) ? 0 : tmp), "quantity:"); 261 buf = _value_int_to_char(((tmp <= 1) ? 0 : tmp), "quantity:");
261 elm_object_text_set((Evas_Object*)data, buf); 262 elm_object_text_set((Evas_Object*)data, buf);
262} 263}
263 264
264static void 265static void
265_countdec_cb(void *data, Evas_Object *obj, void *event_info) 266_countdec_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
266{ 267{
267 char buf[CONVERT]; 268 Eina_Slstr *buf;
268 int tmp; 269 int tmp;
270
269 globalGraphical.count--; 271 globalGraphical.count--;
270 if (globalGraphical.count < 0) tmp = globalGraphical.count = 0; 272 if (globalGraphical.count < 0) tmp = globalGraphical.count = 0;
271 else 273 else
272 tmp = ((globalGraphical.count + 1) * (globalGraphical.count + 1)); 274 tmp = ((globalGraphical.count + 1) * (globalGraphical.count + 1));
273 _value_int_to_char(buf, ((tmp <= 1) ? 0 : tmp), "quantity:"); 275 buf = _value_int_to_char(((tmp <= 1) ? 0 : tmp), "quantity:");
274 elm_object_text_set((Evas_Object*)data, buf); 276 elm_object_text_set((Evas_Object*)data, buf);
275} 277}
276 278
277static void 279static void
278_countinc_cb(void *data, Evas_Object *obj, void *event_info) 280_countinc_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
279{ 281{
280 char buf[CONVERT]; 282 Eina_Slstr *buf;
281 283
282 globalGraphical.count++; 284 globalGraphical.count++;
283 285
284 _value_int_to_char(buf, ((globalGraphical.count + 1) * (globalGraphical.count + 1)), "quantity:"); 286 buf = _value_int_to_char(((globalGraphical.count + 1) * (globalGraphical.count + 1)), "quantity:");
285 elm_object_text_set((Evas_Object*)data, buf); 287 elm_object_text_set((Evas_Object*)data, buf);
286} 288}
287 289
288static void 290static void
289_countinc10_cb(void *data, Evas_Object *obj, void *event_info) 291_countinc10_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
290{ 292{
291 char buf[CONVERT]; 293 Eina_Slstr *buf;
292 294
293 globalGraphical.count += 10; 295 globalGraphical.count += 10;
294 296
295 _value_int_to_char(buf, ((globalGraphical.count + 1) * (globalGraphical.count + 1)), "quantity:"); 297 buf = _value_int_to_char(((globalGraphical.count + 1) * (globalGraphical.count + 1)), "quantity:");
296 elm_object_text_set((Evas_Object*)data, buf); 298 elm_object_text_set((Evas_Object*)data, buf);
297} 299}
298 300
299static void 301static void
300_speeddec10_cb(void *data, Evas_Object *obj, void *event_info) 302_speeddec10_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
301{ 303{
302 char buf[CONVERT]; 304 Eina_Slstr *buf;
303 305
304 globalGraphical.speed -= 10; 306 globalGraphical.speed -= 10;
305 if (globalGraphical.speed <= 0) globalGraphical.speed = 10; 307 if (globalGraphical.speed <= 0) globalGraphical.speed = 10;
306 308
307 _value_int_to_char(buf, globalGraphical.speed, "speed:"); 309 buf = _value_int_to_char(globalGraphical.speed, "speed:");
308 elm_object_text_set((Evas_Object*)data, buf); 310 elm_object_text_set((Evas_Object*)data, buf);
309} 311}
310 312
311static void 313static void
312_speeddec_cb(void *data, Evas_Object *obj, void *event_info) 314_speeddec_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
313{ 315{
314 char buf[CONVERT]; 316 Eina_Slstr *buf;
315 317
316 globalGraphical.speed--; 318 globalGraphical.speed--;
317 if (globalGraphical.speed <= 0) globalGraphical.speed = 10; 319 if (globalGraphical.speed <= 0) globalGraphical.speed = 10;
318 320
319 _value_int_to_char(buf, globalGraphical.speed, "speed:"); 321 buf = _value_int_to_char(globalGraphical.speed, "speed:");
320 elm_object_text_set((Evas_Object*)data, buf); 322 elm_object_text_set((Evas_Object*)data, buf);
321} 323}
322 324
323static void 325static void
324_speedinc_cb(void *data, Evas_Object *obj, void *event_info) 326_speedinc_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
325{ 327{
326 char buf[CONVERT]; 328 Eina_Slstr *buf;
327 329
328 globalGraphical.speed++; 330 globalGraphical.speed++;
329 331
330 _value_int_to_char(buf, globalGraphical.speed, "speed:"); 332 buf = _value_int_to_char(globalGraphical.speed, "speed:");
331 elm_object_text_set((Evas_Object*)data, buf); 333 elm_object_text_set((Evas_Object*)data, buf);
332} 334}
333 335
334static void 336static void
335_speedinc10_cb(void *data, Evas_Object *obj, void *event_info) 337_speedinc10_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
336{ 338{
337 char buf[CONVERT]; 339 Eina_Slstr *buf;
338 340
339 globalGraphical.speed += 10; 341 globalGraphical.speed += 10;
340 342
341 _value_int_to_char(buf, globalGraphical.speed, "speed:"); 343 buf = _value_int_to_char(globalGraphical.speed, "speed:");
342 elm_object_text_set((Evas_Object*)data, buf); 344 elm_object_text_set((Evas_Object*)data, buf);
343} 345}
344 346
345static void 347static void
346_precisiondec10_cb(void *data, Evas_Object *obj, void *event_info) 348_precisiondec10_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
347{ 349{
348 char buf[CONVERT]; 350 Eina_Slstr *buf;
349 351
350 globalGraphical.precision -= 10; 352 globalGraphical.precision -= 10;
351 if (globalGraphical.precision <= 0) globalGraphical.precision = 10; 353 if (globalGraphical.precision <= 0) globalGraphical.precision = 10;
352 354
353 _value_int_to_char(buf, globalGraphical.precision, "precision:"); 355 buf = _value_int_to_char(globalGraphical.precision, "precision:");
354 elm_object_text_set((Evas_Object*)data, buf); 356 elm_object_text_set((Evas_Object*)data, buf);
355} 357}
356 358
357static void 359static void
358_precisiondec_cb(void *data, Evas_Object *obj, void *event_info) 360_precisiondec_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
359{ 361{
360 char buf[CONVERT]; 362 Eina_Slstr *buf;
361 363
362 globalGraphical.precision--; 364 globalGraphical.precision--;
363 if (globalGraphical.precision <= 0) globalGraphical.precision = 10; 365 if (globalGraphical.precision <= 0) globalGraphical.precision = 10;
364 366
365 _value_int_to_char(buf, globalGraphical.precision, "precision:"); 367 buf = _value_int_to_char(globalGraphical.precision, "precision:");
366 elm_object_text_set((Evas_Object*)data, buf); 368 elm_object_text_set((Evas_Object*)data, buf);
367} 369}
368 370
369static void 371static void
370_precisioninc_cb(void *data, Evas_Object *obj, void *event_info) 372_precisioninc_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
371{ 373{
372 char buf[CONVERT]; 374 Eina_Slstr *buf;
373 375
374 globalGraphical.precision++; 376 globalGraphical.precision++;
375 377
376 _value_int_to_char(buf, globalGraphical.precision, "precision:"); 378 buf = _value_int_to_char(globalGraphical.precision, "precision:");
377 elm_object_text_set((Evas_Object*)data, buf); 379 elm_object_text_set((Evas_Object*)data, buf);
378} 380}
379 381
380static void 382static void
381_precisioninc10_cb(void *data, Evas_Object *obj, void *event_info) 383_precisioninc10_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
382{ 384{
383 char buf[CONVERT]; 385 Eina_Slstr *buf;
384 386
385 globalGraphical.precision += 10; 387 globalGraphical.precision += 10;
386 388
387 _value_int_to_char(buf, globalGraphical.precision, "precision:"); 389 buf = _value_int_to_char(globalGraphical.precision, "precision:");
388 elm_object_text_set((Evas_Object*)data, buf); 390 elm_object_text_set((Evas_Object*)data, buf);
389
390} 391}
391 392
392static void 393static void
393_angledec10_cb(void *data, Evas_Object *obj, void *event_info) 394_angledec10_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
394{ 395{
395 char buf[CONVERT]; 396 Eina_Slstr *buf;
396 397
397 globalGraphical.angle -= 10; 398 globalGraphical.angle -= 10;
398 if (globalGraphical.angle <= 0) globalGraphical.angle = 10; 399 if (globalGraphical.angle <= 0) globalGraphical.angle = 10;
399 400
400 _value_int_to_char(buf, globalGraphical.angle, "angle:"); 401 buf = _value_int_to_char(globalGraphical.angle, "angle:");
401 elm_object_text_set((Evas_Object*)data, buf); 402 elm_object_text_set((Evas_Object*)data, buf);
402} 403}
403 404
404static void 405static void
405_angledec_cb(void *data, Evas_Object *obj, void *event_info) 406_angledec_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
406{ 407{
407 char buf[CONVERT]; 408 Eina_Slstr *buf;
408 409
409 globalGraphical.angle--; 410 globalGraphical.angle--;
410 if (globalGraphical.angle <= 0) globalGraphical.angle = 10; 411 if (globalGraphical.angle <= 0) globalGraphical.angle = 10;
411 412
412 _value_int_to_char(buf, globalGraphical.angle, "angle:"); 413 buf = _value_int_to_char(globalGraphical.angle, "angle:");
413 elm_object_text_set((Evas_Object*)data, buf); 414 elm_object_text_set((Evas_Object*)data, buf);
414} 415}
415 416
416static void 417static void
417_angleinc_cb(void *data, Evas_Object *obj, void *event_info) 418_angleinc_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
418{ 419{
419 char buf[CONVERT]; 420 Eina_Slstr *buf;
420 421
421 globalGraphical.angle++; 422 globalGraphical.angle++;
422 if (globalGraphical.angle >= 180) globalGraphical.angle = 180; 423 if (globalGraphical.angle >= 180) globalGraphical.angle = 180;
423 _value_int_to_char(buf, globalGraphical.angle, "angle:"); 424
425 buf = _value_int_to_char(globalGraphical.angle, "angle:");
424 elm_object_text_set((Evas_Object*)data, buf); 426 elm_object_text_set((Evas_Object*)data, buf);
425} 427}
426 428
427static void 429static void
428_angleinc10_cb(void *data, Evas_Object *obj, void *event_info) 430_angleinc10_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
429{ 431{
430 char buf[CONVERT]; 432 Eina_Slstr *buf;
431 433
432 globalGraphical.angle += 10; 434 globalGraphical.angle += 10;
433 if (globalGraphical.angle >= 180) globalGraphical.angle = 180; 435 if (globalGraphical.angle >= 180) globalGraphical.angle = 180;
434 436
435 _value_int_to_char(buf, globalGraphical.angle, "angle:"); 437 buf = _value_int_to_char(globalGraphical.angle, "angle:");
436 elm_object_text_set((Evas_Object*)data, buf); 438 elm_object_text_set((Evas_Object*)data, buf);
437} 439}
438 440
439static void 441static void
440_shadow_enable(void *data, Evas_Object *obj, void *event_info) 442_shadow_enable(void *data EINA_UNUSED, Evas_Object *obj, void *event_info EINA_UNUSED)
441{ 443{
442 if (elm_check_state_get(obj)) 444 if (elm_check_state_get(obj))
443 globalGraphical.flags.shadow_enable = EINA_TRUE; 445 globalGraphical.flags.shadow_enable = EINA_TRUE;
@@ -446,7 +448,7 @@ _shadow_enable(void *data, Evas_Object *obj, void *event_info)
446} 448}
447 449
448static void 450static void
449_colorpick_enable(void *data, Evas_Object *obj, void *event_info) 451_colorpick_enable(void *data EINA_UNUSED, Evas_Object *obj, void *event_info EINA_UNUSED)
450{ 452{
451 if (elm_check_state_get(obj)) 453 if (elm_check_state_get(obj))
452 globalGraphical.flags.colorpick_enable = EINA_TRUE; 454 globalGraphical.flags.colorpick_enable = EINA_TRUE;
@@ -455,7 +457,7 @@ _colorpick_enable(void *data, Evas_Object *obj, void *event_info)
455} 457}
456 458
457static void 459static void
458_fog_enable(void *data, Evas_Object *obj, void *event_info) 460_fog_enable(void *data EINA_UNUSED, Evas_Object *obj, void *event_info EINA_UNUSED)
459{ 461{
460 if (elm_check_state_get(obj)) 462 if (elm_check_state_get(obj))
461 globalGraphical.flags.fog_enable = EINA_TRUE; 463 globalGraphical.flags.fog_enable = EINA_TRUE;
@@ -464,7 +466,7 @@ _fog_enable(void *data, Evas_Object *obj, void *event_info)
464} 466}
465 467
466static void 468static void
467_blend_enable(void *data, Evas_Object *obj, void *event_info) 469_blend_enable(void *data EINA_UNUSED, Evas_Object *obj, void *event_info EINA_UNUSED)
468{ 470{
469 if (elm_check_state_get(obj)) 471 if (elm_check_state_get(obj))
470 globalGraphical.flags.blend_enable = EINA_TRUE; 472 globalGraphical.flags.blend_enable = EINA_TRUE;
@@ -473,7 +475,7 @@ _blend_enable(void *data, Evas_Object *obj, void *event_info)
473} 475}
474 476
475static void 477static void
476_cb_fps_enable(void *data, Evas_Object *obj, void *event_info) 478_cb_fps_enable(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
477{ 479{
478 if (elm_check_state_get(obj)) 480 if (elm_check_state_get(obj))
479 { 481 {
@@ -578,7 +580,7 @@ EAPI_MAIN
578 Evas_Object *navigation = NULL; 580 Evas_Object *navigation = NULL;
579 Evas_Object *fs_node = NULL, *bt_orientation = NULL, *bt_position = NULL, *bt_scale = NULL; 581 Evas_Object *fs_node = NULL, *bt_orientation = NULL, *bt_position = NULL, *bt_scale = NULL;
580 Ecore_Timer *fps_timer = NULL; 582 Ecore_Timer *fps_timer = NULL;
581 char buf[CONVERT]; 583 Eina_Slstr *buf;
582 584
583#ifdef ENABLE_ATPORT 585#ifdef ENABLE_ATPORT
584 at_port_h mf_at_port = NULL; 586 at_port_h mf_at_port = NULL;
@@ -693,7 +695,7 @@ EAPI_MAIN
693 evas_object_show(controlbox); 695 evas_object_show(controlbox);
694 696
695 vcount = elm_label_add(win); 697 vcount = elm_label_add(win);
696 _value_int_to_char(buf, 121, "quantity:"); 698 buf = _value_int_to_char(121, "quantity:");
697 elm_object_text_set(vcount, buf); 699 elm_object_text_set(vcount, buf);
698 700
699 countdec10 = elm_button_add(win); 701 countdec10 = elm_button_add(win);
@@ -732,7 +734,7 @@ EAPI_MAIN
732 evas_object_smart_callback_add(countinc10, "clicked", _countinc10_cb, vcount); 734 evas_object_smart_callback_add(countinc10, "clicked", _countinc10_cb, vcount);
733 735
734 vspeed = elm_label_add(win); 736 vspeed = elm_label_add(win);
735 _value_int_to_char(buf, 30, "speed:"); 737 buf = _value_int_to_char(30, "speed:");
736 elm_object_text_set(vspeed, buf); 738 elm_object_text_set(vspeed, buf);
737 739
738 speeddec10 = elm_button_add(win); 740 speeddec10 = elm_button_add(win);
@@ -771,7 +773,7 @@ EAPI_MAIN
771 evas_object_smart_callback_add(speedinc10, "clicked", _speedinc10_cb, vspeed); 773 evas_object_smart_callback_add(speedinc10, "clicked", _speedinc10_cb, vspeed);
772 774
773 vprecision = elm_label_add(win); 775 vprecision = elm_label_add(win);
774 _value_int_to_char(buf, 100, "precision:"); 776 buf = _value_int_to_char(100, "precision:");
775 elm_object_text_set(vprecision, buf); 777 elm_object_text_set(vprecision, buf);
776 778
777 precisiondec10 = elm_button_add(win); 779 precisiondec10 = elm_button_add(win);
@@ -810,7 +812,7 @@ EAPI_MAIN
810 evas_object_smart_callback_add(precisioninc10, "clicked", _precisioninc10_cb, vprecision); 812 evas_object_smart_callback_add(precisioninc10, "clicked", _precisioninc10_cb, vprecision);
811 813
812 vangle = elm_label_add(win); 814 vangle = elm_label_add(win);
813 _value_int_to_char(buf, 120, "angle:"); 815 buf = _value_int_to_char(120, "angle:");
814 elm_object_text_set(vangle, buf); 816 elm_object_text_set(vangle, buf);
815 817
816 angledec10 = elm_button_add(win); 818 angledec10 = elm_button_add(win);
@@ -914,13 +916,13 @@ EAPI_MAIN
914 image = init_graphical_window(image); 916 image = init_graphical_window(image);
915 917
916 /*Update data for count, speed, precision, angle*/ 918 /*Update data for count, speed, precision, angle*/
917 _value_int_to_char(buf, (globalGraphical.count + 1) * (globalGraphical.count + 1), "quantity:"); 919 buf = _value_int_to_char((globalGraphical.count + 1) * (globalGraphical.count + 1), "quantity:");
918 elm_object_text_set(vcount, buf); 920 elm_object_text_set(vcount, buf);
919 _value_int_to_char(buf, globalGraphical.speed, "speed:"); 921 buf = _value_int_to_char(globalGraphical.speed, "speed:");
920 elm_object_text_set(vspeed, buf); 922 elm_object_text_set(vspeed, buf);
921 _value_int_to_char(buf, globalGraphical.precision, "precision:"); 923 buf = _value_int_to_char(globalGraphical.precision, "precision:");
922 elm_object_text_set(vprecision, buf); 924 elm_object_text_set(vprecision, buf);
923 _value_int_to_char(buf, globalGraphical.angle, "angle:"); 925 buf = _value_int_to_char(globalGraphical.angle, "angle:");
924 elm_object_text_set(vangle, buf); 926 elm_object_text_set(vangle, buf);
925 if (globalGraphical.model_path) 927 if (globalGraphical.model_path)
926 evas_object_smart_callback_call(fs_bt, "file,chosen", (void *)globalGraphical.model_path); 928 evas_object_smart_callback_call(fs_bt, "file,chosen", (void *)globalGraphical.model_path);
diff --git a/src/examples/elementary/performance/tools_private.h b/src/examples/elementary/performance/tools_private.h
index 05c3c26..20aa80d 100644
--- a/src/examples/elementary/performance/tools_private.h
+++ b/src/examples/elementary/performance/tools_private.h
@@ -1,5 +1,9 @@
1#define EFL_EO_API_SUPPORT 1#ifndef EFL_EO_API_SUPPORT
2#define EFL_BETA_API_SUPPORT 2# define EFL_EO_API_SUPPORT
3#endif
4#ifndef EFL_BETA_API_SUPPORT
5# define EFL_BETA_API_SUPPORT
6#endif
3 7
4#include <math.h> 8#include <math.h>
5#include <stdlib.h> 9#include <stdlib.h>