aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/evas/canvas/evas_object_image.c
diff options
context:
space:
mode:
authorCedric BAIL <cedric@osg.samsung.com>2015-04-14 15:21:52 +0200
committerCedric BAIL <cedric@osg.samsung.com>2015-08-05 15:12:33 +0200
commit2ebf315591e0554c308d762a5b7c1823649deb1d (patch)
treeb50f29d5617b8d611e34f475d3a265d59e2a7674 /src/lib/evas/canvas/evas_object_image.c
parentautotools: more cross platform dlfuncs/shm_open checks (diff)
downloadefl-2ebf315591e0554c308d762a5b7c1823649deb1d.tar.gz
evas: add a snapshot bool to Evas_Object_Image.
Snapshot object are rendering the content of the canvas below them into them. They can then be used for filter, map or proxy. Have fun !
Diffstat (limited to 'src/lib/evas/canvas/evas_object_image.c')
-rw-r--r--src/lib/evas/canvas/evas_object_image.c22
1 files changed, 21 insertions, 1 deletions
diff --git a/src/lib/evas/canvas/evas_object_image.c b/src/lib/evas/canvas/evas_object_image.c
index 8956f815bf..32191fdabf 100644
--- a/src/lib/evas/canvas/evas_object_image.c
+++ b/src/lib/evas/canvas/evas_object_image.c
@@ -4738,7 +4738,25 @@ _evas_object_image_video_overlay_do(Evas_Object *eo_obj)
o->delayed.video_hide = EINA_FALSE;
}
-/* vim:set ts=8 sw=3 sts=3 expandtab cino=>5n-2f0^-2{2(0W1st0 :*/
+static void
+_evas_image_snapshot_set(Eo *eo, Evas_Image_Data *pd EINA_UNUSED, Eina_Bool s)
+{
+ Evas_Object_Protected_Data *obj = eo_data_scope_get(eo, EVAS_OBJECT_CLASS);
+
+ if (obj->cur->snapshot == s) return ;
+
+ EINA_COW_STATE_WRITE_BEGIN(obj, state_write, cur)
+ state_write->snapshot = !!s;
+ EINA_COW_STATE_WRITE_END(obj, state_write, cur);
+}
+
+static Eina_Bool
+_evas_image_snapshot_get(Eo *eo, Evas_Image_Data *pd EINA_UNUSED)
+{
+ Evas_Object_Protected_Data *obj = eo_data_scope_get(eo, EVAS_OBJECT_CLASS);
+
+ return obj->cur->snapshot;
+}
EAPI void
evas_object_image_file_set(Eo *obj, const char *file, const char *key)
@@ -4811,3 +4829,5 @@ _evas_image_efl_gfx_filter_program_set(Eo *obj, Evas_Image_Data *pd EINA_UNUSED,
}
#include "canvas/evas_image.eo.c"
+
+/* vim:set ts=8 sw=3 sts=3 expandtab cino=>5n-2f0^-2{2(0W1st0 :*/