summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSavio Sena <savio@expertisesolutions.com.br>2014-09-29 19:48:07 -0300
committerSavio Sena <savio@expertisesolutions.com.br>2014-09-29 19:48:07 -0300
commitfb28488bdc417b31a400735291f82507ab510fc8 (patch)
treef51daeda2c5e697a57e9c12f291a9442183c3fcc
parent691498bfa6a2f0118af3b0ba19139abef3ab5300 (diff)
expedite-cxx: Fix position_set.
-rw-r--r--src/bin/cxx/image_blend_occlude1.cc2
-rw-r--r--src/bin/cxx/image_blend_occlude1_many.cc2
-rw-r--r--src/bin/cxx/image_blend_occlude1_very_many.cc2
-rw-r--r--src/bin/cxx/image_blend_occlude2_few.cc2
-rw-r--r--src/bin/cxx/image_blend_occlude2_many.cc2
-rw-r--r--src/bin/cxx/image_blend_occlude2_very_many.cc2
-rw-r--r--src/bin/cxx/image_blend_occlude3.cc2
-rw-r--r--src/bin/cxx/image_blend_occlude3_few.cc2
-rw-r--r--src/bin/cxx/image_blend_occlude3_many.cc4
-rw-r--r--src/bin/cxx/image_blend_occlude3_very_many.cc2
-rw-r--r--src/bin/cxx/proxy_image_offscreen.cc10
11 files changed, 18 insertions, 14 deletions
diff --git a/src/bin/cxx/image_blend_occlude1.cc b/src/bin/cxx/image_blend_occlude1.cc
index c2034b8..623c713 100644
--- a/src/bin/cxx/image_blend_occlude1.cc
+++ b/src/bin/cxx/image_blend_occlude1.cc
@@ -40,7 +40,7 @@ static void _setup(void)
40 x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8); 40 x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8);
41 y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8); 41 y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8);
42 o.file_set(build_path("image.png"), ""); 42 o.file_set(build_path("image.png"), "");
43 o.position_set(x, y); 43 o.evas::object::position_set(x, y);
44 } 44 }
45 o.fill_set(0, 0, 120, 160); 45 o.fill_set(0, 0, 120, 160);
46 o.evas::object::size_set(120, 160); 46 o.evas::object::size_set(120, 160);
diff --git a/src/bin/cxx/image_blend_occlude1_many.cc b/src/bin/cxx/image_blend_occlude1_many.cc
index 1c9f102..1c939bd 100644
--- a/src/bin/cxx/image_blend_occlude1_many.cc
+++ b/src/bin/cxx/image_blend_occlude1_many.cc
@@ -42,7 +42,7 @@ static void _setup(void)
42 x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8); 42 x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8);
43 y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8); 43 y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8);
44 o.file_set(build_path("image.png"), NULL); 44 o.file_set(build_path("image.png"), NULL);
45 o.position_set(x, y); 45 o.evas::object::position_set(x, y);
46 } 46 }
47 o.fill_set(0, 0, 120, 160); 47 o.fill_set(0, 0, 120, 160);
48 o.evas::object::size_set(120, 160); 48 o.evas::object::size_set(120, 160);
diff --git a/src/bin/cxx/image_blend_occlude1_very_many.cc b/src/bin/cxx/image_blend_occlude1_very_many.cc
index c8c5cbb..0768ab9 100644
--- a/src/bin/cxx/image_blend_occlude1_very_many.cc
+++ b/src/bin/cxx/image_blend_occlude1_very_many.cc
@@ -43,7 +43,7 @@ static void _setup(void)
43 Evas_Coord x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8); 43 Evas_Coord x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8);
44 Evas_Coord y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8); 44 Evas_Coord y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8);
45 o.file_set(build_path("image.png"), ""); 45 o.file_set(build_path("image.png"), "");
46 o.position_set(x, y); 46 o.evas::object::position_set(x, y);
47 } 47 }
48 o.fill_set(0, 0, 120, 160); 48 o.fill_set(0, 0, 120, 160);
49 o.evas::object::size_set(120, 160); 49 o.evas::object::size_set(120, 160);
diff --git a/src/bin/cxx/image_blend_occlude2_few.cc b/src/bin/cxx/image_blend_occlude2_few.cc
index 85716ae..84ef218 100644
--- a/src/bin/cxx/image_blend_occlude2_few.cc
+++ b/src/bin/cxx/image_blend_occlude2_few.cc
@@ -43,7 +43,7 @@ static void _setup(void)
43 Evas_Coord x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8); 43 Evas_Coord x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8);
44 Evas_Coord y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8); 44 Evas_Coord y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8);
45 o.file_set(build_path("image.png"), ""); 45 o.file_set(build_path("image.png"), "");
46 o.position_set(x, y); 46 o.evas::object::position_set(x, y);
47 } 47 }
48 o.fill_set(0, 0, 120, 160); 48 o.fill_set(0, 0, 120, 160);
49 o.size_set(120, 160); 49 o.size_set(120, 160);
diff --git a/src/bin/cxx/image_blend_occlude2_many.cc b/src/bin/cxx/image_blend_occlude2_many.cc
index f28554f..6a462b6 100644
--- a/src/bin/cxx/image_blend_occlude2_many.cc
+++ b/src/bin/cxx/image_blend_occlude2_many.cc
@@ -45,7 +45,7 @@ static void _setup(void)
45 x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8); 45 x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8);
46 y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8); 46 y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8);
47 o.file_set(build_path("image.png"), ""); 47 o.file_set(build_path("image.png"), "");
48 o.position_set(x, y); 48 o.evas::object::position_set(x, y);
49 } 49 }
50 o.fill_set(0, 0, 120, 160); 50 o.fill_set(0, 0, 120, 160);
51 o.evas::object::size_set(120, 160); 51 o.evas::object::size_set(120, 160);
diff --git a/src/bin/cxx/image_blend_occlude2_very_many.cc b/src/bin/cxx/image_blend_occlude2_very_many.cc
index 0a63bcf..4ad8dee 100644
--- a/src/bin/cxx/image_blend_occlude2_very_many.cc
+++ b/src/bin/cxx/image_blend_occlude2_very_many.cc
@@ -43,7 +43,7 @@ static void _setup(void)
43 Evas_Coord x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8); 43 Evas_Coord x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8);
44 Evas_Coord y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8); 44 Evas_Coord y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8);
45 o.file_set(build_path("image.png"), ""); 45 o.file_set(build_path("image.png"), "");
46 o.position_set(x, y); 46 o.evas::object::position_set(x, y);
47 } 47 }
48 o.fill_set(0, 0, 120, 160); 48 o.fill_set(0, 0, 120, 160);
49 o.evas::object::size_set(120, 160); 49 o.evas::object::size_set(120, 160);
diff --git a/src/bin/cxx/image_blend_occlude3.cc b/src/bin/cxx/image_blend_occlude3.cc
index ef488b4..832758c 100644
--- a/src/bin/cxx/image_blend_occlude3.cc
+++ b/src/bin/cxx/image_blend_occlude3.cc
@@ -42,7 +42,7 @@ static void _setup(void)
42 x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8); 42 x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8);
43 y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8); 43 y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8);
44 o.file_set(build_path("image.png"), ""); 44 o.file_set(build_path("image.png"), "");
45 o.position_set(x, y); 45 o.evas::object::position_set(x, y);
46 } 46 }
47 o.fill_set(0, 0, 120, 160); 47 o.fill_set(0, 0, 120, 160);
48 o.evas::object::size_set(120, 160); 48 o.evas::object::size_set(120, 160);
diff --git a/src/bin/cxx/image_blend_occlude3_few.cc b/src/bin/cxx/image_blend_occlude3_few.cc
index 040861d..327621b 100644
--- a/src/bin/cxx/image_blend_occlude3_few.cc
+++ b/src/bin/cxx/image_blend_occlude3_few.cc
@@ -45,7 +45,7 @@ static void _setup(void)
45 x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8); 45 x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8);
46 y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8); 46 y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8);
47 o.file_set(build_path("image.png"), ""); 47 o.file_set(build_path("image.png"), "");
48 o.position_set(x, y); 48 o.evas::object::position_set(x, y);
49 } 49 }
50 o.fill_set(0, 0, 120, 160); 50 o.fill_set(0, 0, 120, 160);
51 o.evas::object::size_set(120, 160); 51 o.evas::object::size_set(120, 160);
diff --git a/src/bin/cxx/image_blend_occlude3_many.cc b/src/bin/cxx/image_blend_occlude3_many.cc
index 7b02f7a..1e61262 100644
--- a/src/bin/cxx/image_blend_occlude3_many.cc
+++ b/src/bin/cxx/image_blend_occlude3_many.cc
@@ -41,10 +41,10 @@ static void _setup(void)
41 Evas_Coord x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8); 41 Evas_Coord x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8);
42 Evas_Coord y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8); 42 Evas_Coord y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8);
43 o.file_set(build_path("image.png"), ""); 43 o.file_set(build_path("image.png"), "");
44 o.position_set(x, y); 44 o.evas::object::position_set(x, y);
45 } 45 }
46 o.fill_set(0, 0, 120, 160); 46 o.fill_set(0, 0, 120, 160);
47 o.size_set(120, 160); 47 o.evas::object::size_set(120, 160);
48 o.visibility_set(true); 48 o.visibility_set(true);
49 } 49 }
50 done = 0; 50 done = 0;
diff --git a/src/bin/cxx/image_blend_occlude3_very_many.cc b/src/bin/cxx/image_blend_occlude3_very_many.cc
index 6b9eb6e..55da895 100644
--- a/src/bin/cxx/image_blend_occlude3_very_many.cc
+++ b/src/bin/cxx/image_blend_occlude3_very_many.cc
@@ -42,7 +42,7 @@ static void _setup(void)
42 Evas_Coord x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8); 42 Evas_Coord x = (win_w / 4) + (((rnd() & 0xff) * ((win_w / 2) - 120)) >> 8);
43 Evas_Coord y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8); 43 Evas_Coord y = (win_h / 4) + (((rnd() & 0xff) * ((win_h / 2) - 120)) >> 8);
44 o.file_set(build_path("image.png"), ""); 44 o.file_set(build_path("image.png"), "");
45 o.position_set(x, y); 45 o.evas::object::position_set(x, y);
46 } 46 }
47 o.fill_set(0, 0, 120, 160); 47 o.fill_set(0, 0, 120, 160);
48 o.size_set(120, 160); 48 o.size_set(120, 160);
diff --git a/src/bin/cxx/proxy_image_offscreen.cc b/src/bin/cxx/proxy_image_offscreen.cc
index ab93554..8b455a0 100644
--- a/src/bin/cxx/proxy_image_offscreen.cc
+++ b/src/bin/cxx/proxy_image_offscreen.cc
@@ -25,10 +25,13 @@ static void _setup(void)
25{ 25{
26 evas::canvas canvas(::eo_ref(G_evas)); 26 evas::canvas canvas(::eo_ref(G_evas));
27 evas::image o(efl::eo::parent = canvas); 27 evas::image o(efl::eo::parent = canvas);
28
28 o.file_set(build_path("logo.png"), ""); 29 o.file_set(build_path("logo.png"), "");
29 o.fill_set(0, 0, 120, 160); 30 o.fill_set(0, 0, 120, 160);
30 o.evas::object::size_set(120, 160); 31 o.evas::object::size_set(120, 160);
32 o.evas::object::position_set(-400, -300);
31 evas::image src = o; 33 evas::image src = o;
34
32 for (int i = 0; i < OBNUM / 2; i++) 35 for (int i = 0; i < OBNUM / 2; i++)
33 { 36 {
34 evas::image o(efl::eo::parent = canvas); 37 evas::image o(efl::eo::parent = canvas);
@@ -50,8 +53,8 @@ static void _cleanup()
50/* loop - do things */ 53/* loop - do things */
51static void _loop(double t, int f) 54static void _loop(double t, int f)
52{ 55{
53 auto itr = images.begin(); 56 int i = 0;
54 for (int i = 0; i < OBNUM; i++, ++itr) 57 for (evas::image& img : images)
55 { 58 {
56 Evas_Coord w = 120; 59 Evas_Coord w = 120;
57 Evas_Coord h = 160; 60 Evas_Coord h = 160;
@@ -59,8 +62,9 @@ static void _loop(double t, int f)
59 x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2); 62 x += sin((double)(f + (i * 13)) / (36.7 * SLOW)) * (w / 2);
60 Evas_Coord y = (win_h / 2) - (h / 2); 63 Evas_Coord y = (win_h / 2) - (h / 2);
61 y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2); 64 y += cos((double)(f + (i * 28)) / (43.8 * SLOW)) * (h / 2);
62 (*itr).position_set(x, y); 65 img.evas::object::position_set(x, y);
63 } 66 }
67 ++i;
64 FPS_STD(NAME); 68 FPS_STD(NAME);
65} 69}
66 70