aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/libraries/evas/src/lib/cache/evas_cache_image.c
diff options
context:
space:
mode:
Diffstat (limited to 'libraries/evas/src/lib/cache/evas_cache_image.c')
-rw-r--r--libraries/evas/src/lib/cache/evas_cache_image.c17
1 files changed, 5 insertions, 12 deletions
diff --git a/libraries/evas/src/lib/cache/evas_cache_image.c b/libraries/evas/src/lib/cache/evas_cache_image.c
index d52c64e..73e4f8a 100644
--- a/libraries/evas/src/lib/cache/evas_cache_image.c
+++ b/libraries/evas/src/lib/cache/evas_cache_image.c
@@ -918,12 +918,8 @@ evas_cache_image_drop(Image_Entry *im)
918EAPI void 918EAPI void
919evas_cache_image_data_not_needed(Image_Entry *im) 919evas_cache_image_data_not_needed(Image_Entry *im)
920{ 920{
921 Evas_Cache_Image *cache;
922 int references; 921 int references;
923 922
924 /* FIXME: no one uses this api... well evas_cache_engine_parent_not_needed()
925 * does, but nothing uses that! */
926 cache = im->cache;
927#ifdef EVAS_FRAME_QUEUING 923#ifdef EVAS_FRAME_QUEUING
928 LKL(im->lock_references); 924 LKL(im->lock_references);
929#endif 925#endif
@@ -941,11 +937,12 @@ evas_cache_image_dirty(Image_Entry *im, unsigned int x, unsigned int y, unsigned
941{ 937{
942 Image_Entry *im_dirty = im; 938 Image_Entry *im_dirty = im;
943 Evas_Cache_Image *cache; 939 Evas_Cache_Image *cache;
944 int references;
945 940
946 cache = im->cache; 941 cache = im->cache;
947 if (!(im->flags.dirty)) 942 if (!(im->flags.dirty))
948 { 943 {
944#ifndef EVAS_CSERVE
945 int references;
949#ifdef EVAS_FRAME_QUEUING 946#ifdef EVAS_FRAME_QUEUING
950 LKL(im->lock_references); 947 LKL(im->lock_references);
951#endif 948#endif
@@ -953,21 +950,18 @@ evas_cache_image_dirty(Image_Entry *im, unsigned int x, unsigned int y, unsigned
953#ifdef EVAS_FRAME_QUEUING 950#ifdef EVAS_FRAME_QUEUING
954 LKU(im->lock_references); 951 LKU(im->lock_references);
955#endif 952#endif
956#ifndef EVAS_CSERVE
957 // if ref 1 also copy if using shared cache as its read-only 953 // if ref 1 also copy if using shared cache as its read-only
958 if (references == 1) im_dirty = im; 954 if (references == 1) im_dirty = im;
959 else 955 else
960#endif 956#endif
961 { 957 {
962 int error;
963
964 im_dirty = 958 im_dirty =
965 evas_cache_image_copied_data(cache, im->w, im->h, 959 evas_cache_image_copied_data(cache, im->w, im->h,
966 evas_cache_image_pixels(im), 960 evas_cache_image_pixels(im),
967 im->flags.alpha, im->space); 961 im->flags.alpha, im->space);
968 if (!im_dirty) goto on_error; 962 if (!im_dirty) goto on_error;
969 if (cache->func.debug) cache->func.debug("dirty-src", im); 963 if (cache->func.debug) cache->func.debug("dirty-src", im);
970 error = cache->func.dirty(im_dirty, im); 964 cache->func.dirty(im_dirty, im);
971 if (cache->func.debug) cache->func.debug("dirty-out", im_dirty); 965 if (cache->func.debug) cache->func.debug("dirty-out", im_dirty);
972#ifdef EVAS_FRAME_QUEUING 966#ifdef EVAS_FRAME_QUEUING
973 LKL(im_dirty->lock_references); 967 LKL(im_dirty->lock_references);
@@ -1014,15 +1008,13 @@ evas_cache_image_alone(Image_Entry *im)
1014 } 1008 }
1015 else 1009 else
1016 { 1010 {
1017 int error;
1018
1019 im_dirty = evas_cache_image_copied_data(cache, im->w, im->h, 1011 im_dirty = evas_cache_image_copied_data(cache, im->w, im->h,
1020 evas_cache_image_pixels(im), 1012 evas_cache_image_pixels(im),
1021 im->flags.alpha, 1013 im->flags.alpha,
1022 im->space); 1014 im->space);
1023 if (!im_dirty) goto on_error; 1015 if (!im_dirty) goto on_error;
1024 if (cache->func.debug) cache->func.debug("dirty-src", im); 1016 if (cache->func.debug) cache->func.debug("dirty-src", im);
1025 error = cache->func.dirty(im_dirty, im); 1017 cache->func.dirty(im_dirty, im);
1026 if (cache->func.debug) cache->func.debug("dirty-out", im_dirty); 1018 if (cache->func.debug) cache->func.debug("dirty-out", im_dirty);
1027#ifdef EVAS_FRAME_QUEUING 1019#ifdef EVAS_FRAME_QUEUING
1028 LKL(im_dirty->lock_references); 1020 LKL(im_dirty->lock_references);
@@ -1296,6 +1288,7 @@ evas_cache_image_preload_cancel(Image_Entry *im, const void *target)
1296 _evas_cache_image_entry_preload_remove(im, target); 1288 _evas_cache_image_entry_preload_remove(im, target);
1297#else 1289#else
1298 (void)im; 1290 (void)im;
1291 (void)target;
1299#endif 1292#endif
1300} 1293}
1301 1294