summaryrefslogtreecommitdiff
path: root/src/lib/evas/canvas/evas_vg_private.h
diff options
context:
space:
mode:
authorsubhransu mohanty <sub.mohanty@samsung.com>2017-10-27 09:11:02 +0900
committerJean-Philippe Andre <jp.andre@samsung.com>2017-10-27 14:58:38 +0900
commit64231ae699858b34d65f6e27d665a1411ff1bcf0 (patch)
treed62003b960d325d8d91e9688003055ee96f28159 /src/lib/evas/canvas/evas_vg_private.h
parentbf79ec359d7f7c6bbb5d6cd5dbb22d233551ae58 (diff)
evas/vg: Added vg tree caching support
Diffstat (limited to 'src/lib/evas/canvas/evas_vg_private.h')
-rw-r--r--src/lib/evas/canvas/evas_vg_private.h43
1 files changed, 38 insertions, 5 deletions
diff --git a/src/lib/evas/canvas/evas_vg_private.h b/src/lib/evas/canvas/evas_vg_private.h
index d3e151aba1..dda171bdad 100644
--- a/src/lib/evas/canvas/evas_vg_private.h
+++ b/src/lib/evas/canvas/evas_vg_private.h
@@ -3,18 +3,41 @@
3 3
4#include <Ector.h> 4#include <Ector.h>
5 5
6typedef struct _Efl_VG_Data Efl_VG_Data; 6typedef struct _Efl_VG_Data Efl_VG_Data;
7typedef struct _Efl_VG_Container_Data Efl_VG_Container_Data; 7typedef struct _Efl_VG_Container_Data Efl_VG_Container_Data;
8typedef struct _Efl_VG_Gradient_Data Efl_VG_Gradient_Data; 8typedef struct _Efl_VG_Gradient_Data Efl_VG_Gradient_Data;
9typedef struct _Efl_VG_Interpolation Efl_VG_Interpolation; 9typedef struct _Efl_VG_Interpolation Efl_VG_Interpolation;
10 10
11typedef struct _Efl_Canvas_Vg_Data Efl_Canvas_Vg_Data; 11
12typedef struct _Efl_Canvas_Vg_Data Efl_Canvas_Vg_Data;
13
14typedef struct _Evas_Cache_Vg_Entry Evas_Cache_Vg_Entry;
15typedef struct _Evas_Cache_Vg Evas_Cache_Vg;
16
17struct _Evas_Cache_Vg
18{
19 Eina_Hash *vg_hash;
20 Eina_Hash *active;
21 int ref;
22};
23
24struct _Evas_Cache_Vg_Entry
25{
26 char *hash_key;
27 Eina_Stringshare *file;
28 Eina_Stringshare *key;
29 int w;
30 int h;
31 Efl_VG *root;
32 int ref;
33};
12 34
13struct _Efl_Canvas_Vg_Data 35struct _Efl_Canvas_Vg_Data
14{ 36{
15 void *engine_data; 37 void *engine_data;
16 Efl_VG *root; 38 Efl_VG *root;
17 Efl_VG *vg_tree; 39 Efl_VG *vg_tree;
40 Evas_Cache_Vg_Entry *vg_entry;
18 Eina_Rect fill; 41 Eina_Rect fill;
19 Eina_Rect viewbox; 42 Eina_Rect viewbox;
20 unsigned int width, height; 43 unsigned int width, height;
@@ -70,6 +93,16 @@ struct _Efl_VG_Interpolation
70 Eina_Point_3D skew; 93 Eina_Point_3D skew;
71}; 94};
72 95
96
97void evas_cache_vg_init(void);
98void evas_cache_vg_shutdown(void);
99Evas_Cache_Vg_Entry* evas_cache_vg_entry_find(const char *file, const char *key, int w, int h);
100Efl_VG* evas_cache_vg_tree_get(Evas_Cache_Vg_Entry *svg_entry);
101void evas_cache_vg_entry_del(Evas_Cache_Vg_Entry *svg_entry);
102Vg_File_Data * evas_cache_vg_file_info(const char *file, const char *key);
103
104Eina_Bool evas_vg_save_to_file(Vg_File_Data *evg_data, const char *file, const char *key, const char *flags);
105
73static inline Efl_VG_Data * 106static inline Efl_VG_Data *
74_evas_vg_render_pre(Efl_VG *child, Ector_Surface *s, Eina_Matrix3 *m) 107_evas_vg_render_pre(Efl_VG *child, Ector_Surface *s, Eina_Matrix3 *m)
75{ 108{