diff options
author | Hermet Park <hermetpark@gmail.com> | 2018-12-07 18:42:45 +0900 |
---|---|---|
committer | Hermet Park <hermetpark@gmail.com> | 2018-12-07 19:08:34 +0900 |
commit | 950059ce9a85b070a094d7e17ad43c27dd52065e (patch) | |
tree | fd57d967712b92b83fb2ded223a0677c44532459 /src/lib/evas/canvas/evas_vg_private.h | |
parent | 072f5a2fa0ec6d714de03a983a24330bfbf856a7 (diff) |
evas vg: revise basic vg cache logic.
There was a big trouble that vg cache didn't free cached data properly.
Plus, there was a unnecessary copy of vg tree data.
This revised version is a improvement of our evas vg cache
in stable and optmization.
Diffstat (limited to 'src/lib/evas/canvas/evas_vg_private.h')
-rw-r--r-- | src/lib/evas/canvas/evas_vg_private.h | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/lib/evas/canvas/evas_vg_private.h b/src/lib/evas/canvas/evas_vg_private.h index 5852b1b9b1..a4d11d06cb 100644 --- a/src/lib/evas/canvas/evas_vg_private.h +++ b/src/lib/evas/canvas/evas_vg_private.h | |||
@@ -25,6 +25,8 @@ typedef struct _Vg_Cache_Entry | |||
25 | int h; | 25 | int h; |
26 | Efl_VG *root; | 26 | Efl_VG *root; |
27 | int ref; | 27 | int ref; |
28 | Vg_File_Data *vfd; | ||
29 | |||
28 | } Vg_Cache_Entry; | 30 | } Vg_Cache_Entry; |
29 | 31 | ||
30 | // holds the vg tree info set by the user | 32 | // holds the vg tree info set by the user |
@@ -100,9 +102,10 @@ struct _Efl_Canvas_Vg_Interpolation | |||
100 | 102 | ||
101 | void evas_cache_vg_init(void); | 103 | void evas_cache_vg_init(void); |
102 | void evas_cache_vg_shutdown(void); | 104 | void evas_cache_vg_shutdown(void); |
103 | Vg_Cache_Entry* evas_cache_vg_entry_find(const char *file, const char *key, int w, int h); | 105 | Vg_Cache_Entry* evas_cache_vg_entry_resize(Vg_Cache_Entry *entry, int w, int h); |
104 | Efl_VG* evas_cache_vg_tree_get(Vg_Cache_Entry *svg_entry); | 106 | Vg_Cache_Entry* evas_cache_vg_entry_create(const char *file, const char *key, int w, int h); |
105 | void evas_cache_vg_entry_del(Vg_Cache_Entry *svg_entry); | 107 | Efl_VG* evas_cache_vg_tree_get(Vg_Cache_Entry *vg_entry); |
108 | void evas_cache_vg_entry_del(Vg_Cache_Entry *vg_entry); | ||
106 | Vg_File_Data * evas_cache_vg_file_open(const char *file, const char *key); | 109 | Vg_File_Data * evas_cache_vg_file_open(const char *file, const char *key); |
107 | Eina_Bool evas_cache_vg_file_save(Efl_VG *root, int w, int h, const char *file, const char *key, const char *flags); | 110 | Eina_Bool evas_cache_vg_file_save(Efl_VG *root, int w, int h, const char *file, const char *key, const char *flags); |
108 | Eina_Bool evas_cache_vg_entry_file_save(Vg_Cache_Entry *vg_entry, const char *file, const char *key, const char *flags); | 111 | Eina_Bool evas_cache_vg_entry_file_save(Vg_Cache_Entry *vg_entry, const char *file, const char *key, const char *flags); |