2 * This tests that proxy works fine if the proxy (of an image) works when
10 #define FNAME image_blend_unscaled_proxy_start
11 #define NAME "Proxy Offscreen"
12 #define ICON "blend.png"
21 static Evas_Object *o_images[OBNUM];
24 static void _setup(void)
29 o = eo_add(EFL_CANVAS_IMAGE_CLASS, evas);
30 efl_file_simple_load(o, build_path("logo.png"), NULL);
31 efl_gfx_fill_set(o, EINA_RECT(0, 0, 120, 160));
32 efl_gfx_entity_size_set(o, EINA_SIZE2D(120, 160));
33 efl_gfx_entity_position_set(o, EINA_POSITION2D(-400, -300));
36 for (i = 0; i < OBNUM / 2; i++)
38 o = eo_add(EFL_CANVAS_PROXY_CLASS, evas);
40 efl_canvas_proxy_source_set(o, src, NULL);
41 efl_gfx_entity_size_set(o, EINA_SIZE2D(120, 160));
42 efl_gfx_fill_set(o, EINA_RECT(0, 0, 120, 160));
43 efl_gfx_entity_visible_set(o, EINA_TRUE);
49 static void _cleanup(void)
52 for (i = 0; i < OBNUM; i++) eo_del(o_images[i]);
55 /* loop - do things */
56 static void _loop(double t, int f)
59 Evas_Coord x, y, w, h;
60 for (i = 0; i < OBNUM; i++)
64 x = (win_w / 2) - (w / 2);
65 x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
66 y = (win_h / 2) - (h / 2);
67 y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
68 efl_gfx_entity_position_set(o_images[i], EINA_POSITION2D(x, y));
73 /* prepend special key handlers if interactive (before STD) */
74 static void _key(const char *key)
90 /* template stuff - ignore */
95 _ui_menu_item_add(ICON, NAME, FNAME);
107 ui_func_set(_key, _loop);