summaryrefslogtreecommitdiff
path: root/src/lib/evas/canvas/evas_object_image.c
diff options
context:
space:
mode:
authorJean-Philippe Andre <jp.andre@samsung.com>2016-03-02 20:46:11 +0900
committerJean-Philippe Andre <jp.andre@samsung.com>2016-03-15 11:11:59 +0900
commitb458341a13b93b2f963745fae34b3ce14668f99d (patch)
treed10822600532ce5ea115b7a7e38e112bf196c87d /src/lib/evas/canvas/evas_object_image.c
parente3de15d72642a61f57dda280befe458cb546c527 (diff)
Efl.Gfx.Buffer: Add interface skeletton
Diffstat (limited to '')
-rw-r--r--src/lib/evas/canvas/evas_object_image.c306
1 files changed, 221 insertions, 85 deletions
diff --git a/src/lib/evas/canvas/evas_object_image.c b/src/lib/evas/canvas/evas_object_image.c
index 60802326b1..10fa5e8208 100644
--- a/src/lib/evas/canvas/evas_object_image.c
+++ b/src/lib/evas/canvas/evas_object_image.c
@@ -17,7 +17,6 @@
17#include "../common/evas_convert_colorspace.h" 17#include "../common/evas_convert_colorspace.h"
18#include "../common/evas_convert_yuv.h" 18#include "../common/evas_convert_yuv.h"
19 19
20#include "../efl/interfaces/efl_gfx_filter.eo.h"
21#include "evas_filter.eo.h" 20#include "evas_filter.eo.h"
22#include "evas_filter.h" 21#include "evas_filter.h"
23 22
@@ -662,9 +661,10 @@ _evas_image_source_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
662} 661}
663 662
664EOLIAN static void 663EOLIAN static void
665_evas_image_orient_set(Eo *eo_obj, Evas_Image_Data *o, Evas_Image_Orient orient) 664_evas_image_efl_image_orientation_set(Eo *eo_obj, Evas_Image_Data *o, Efl_Gfx_Orientation _orient)
666{ 665{
667 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 666 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
667 Evas_Image_Orient orient = (Evas_Image_Orient) _orient;
668 int iw, ih; 668 int iw, ih;
669 669
670 if (o->cur->orient == orient) return; 670 if (o->cur->orient == orient) return;
@@ -710,10 +710,10 @@ _evas_image_orient_set(Eo *eo_obj, Evas_Image_Data *o, Evas_Image_Orient orient)
710 evas_object_change(eo_obj, obj); 710 evas_object_change(eo_obj, obj);
711} 711}
712 712
713EOLIAN static Evas_Image_Orient 713EOLIAN static Efl_Gfx_Orientation
714_evas_image_orient_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) 714_evas_image_efl_image_orientation_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
715{ 715{
716 return o->cur->orient; 716 return (Efl_Gfx_Orientation) o->cur->orient;
717} 717}
718 718
719EAPI Eina_Bool 719EAPI Eina_Bool
@@ -792,7 +792,7 @@ _evas_image_eo_base_dbg_info_get(Eo *eo_obj, Evas_Image_Data *o, Eo_Dbg_Info *ro
792 if (evas_object_image_load_error_get(eo_obj) != EVAS_LOAD_ERROR_NONE) 792 if (evas_object_image_load_error_get(eo_obj) != EVAS_LOAD_ERROR_NONE)
793 { 793 {
794 Evas_Load_Error error = EVAS_LOAD_ERROR_GENERIC; 794 Evas_Load_Error error = EVAS_LOAD_ERROR_GENERIC;
795 error = evas_obj_image_load_error_get(eo_obj); 795 error = (Evas_Load_Error) efl_image_load_error_get(eo_obj);
796 EO_DBG_INFO_APPEND(group, "Load Error", EINA_VALUE_TYPE_STRING, 796 EO_DBG_INFO_APPEND(group, "Load Error", EINA_VALUE_TYPE_STRING,
797 evas_load_error_str(error)); 797 evas_load_error_str(error));
798 } 798 }
@@ -862,7 +862,7 @@ _evas_image_scene_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
862} 862}
863 863
864EOLIAN static void 864EOLIAN static void
865_evas_image_border_set(Eo *eo_obj, Evas_Image_Data *o, int l, int r, int t, int b) 865_evas_image_efl_image_border_set(Eo *eo_obj, Evas_Image_Data *o, int l, int r, int t, int b)
866{ 866{
867 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 867 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
868 868
@@ -889,7 +889,7 @@ _evas_image_border_set(Eo *eo_obj, Evas_Image_Data *o, int l, int r, int t, int
889} 889}
890 890
891EOLIAN static void 891EOLIAN static void
892_evas_image_border_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o, int *l, int *r, int *t, int *b) 892_evas_image_efl_image_border_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o, int *l, int *r, int *t, int *b)
893{ 893{
894 if (l) *l = o->cur->border.l; 894 if (l) *l = o->cur->border.l;
895 if (r) *r = o->cur->border.r; 895 if (r) *r = o->cur->border.r;
@@ -898,9 +898,11 @@ _evas_image_border_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o, int *l, int *
898} 898}
899 899
900EOLIAN static void 900EOLIAN static void
901_evas_image_border_center_fill_set(Eo *eo_obj, Evas_Image_Data *o, Evas_Border_Fill_Mode fill) 901_evas_image_efl_image_border_center_fill_set(Eo *eo_obj, Evas_Image_Data *o, Efl_Gfx_Border_Fill_Mode _fill)
902{ 902{
903 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 903 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
904 Evas_Border_Fill_Mode fill = (Evas_Border_Fill_Mode) _fill;
905
904 if (fill == o->cur->border.fill) return; 906 if (fill == o->cur->border.fill) return;
905 evas_object_async_block(obj); 907 evas_object_async_block(obj);
906 EINA_COW_IMAGE_STATE_WRITE_BEGIN(o, state_write) 908 EINA_COW_IMAGE_STATE_WRITE_BEGIN(o, state_write)
@@ -911,10 +913,10 @@ _evas_image_border_center_fill_set(Eo *eo_obj, Evas_Image_Data *o, Evas_Border_F
911 evas_object_change(eo_obj, obj); 913 evas_object_change(eo_obj, obj);
912} 914}
913 915
914EOLIAN static Evas_Border_Fill_Mode 916EOLIAN static Efl_Gfx_Border_Fill_Mode
915_evas_image_border_center_fill_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) 917_evas_image_efl_image_border_center_fill_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
916{ 918{
917 return o->cur->border.fill; 919 return (Efl_Gfx_Border_Fill_Mode) o->cur->border.fill;
918} 920}
919 921
920EOLIAN static void 922EOLIAN static void
@@ -950,7 +952,7 @@ _evas_image_efl_gfx_fill_filled_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
950} 952}
951 953
952EOLIAN static void 954EOLIAN static void
953_evas_image_border_scale_set(Eo *eo_obj, Evas_Image_Data *o, double scale) 955_evas_image_efl_image_border_scale_set(Eo *eo_obj, Evas_Image_Data *o, double scale)
954{ 956{
955 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 957 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
956 958
@@ -965,19 +967,11 @@ _evas_image_border_scale_set(Eo *eo_obj, Evas_Image_Data *o, double scale)
965} 967}
966 968
967EOLIAN static double 969EOLIAN static double
968_evas_image_border_scale_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) 970_evas_image_efl_image_border_scale_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
969{ 971{
970 return o->cur->border.scale; 972 return o->cur->border.scale;
971} 973}
972 974
973EAPI void
974evas_object_image_fill_set(Evas_Image *obj,
975 Evas_Coord x, Evas_Coord y,
976 Evas_Coord w, Evas_Coord h)
977{
978 efl_gfx_fill_set((Evas_Image *)obj, x, y, w, h);
979}
980
981EOLIAN static void 975EOLIAN static void
982_evas_image_efl_gfx_fill_fill_set(Eo *eo_obj, Evas_Image_Data *o, 976_evas_image_efl_gfx_fill_fill_set(Eo *eo_obj, Evas_Image_Data *o,
983 int x, int y, int w, int h) 977 int x, int y, int w, int h)
@@ -1083,12 +1077,6 @@ _evas_image_efl_gfx_view_view_size_set(Eo *eo_obj, Evas_Image_Data *o, int w, in
1083 evas_object_change(eo_obj, obj); 1077 evas_object_change(eo_obj, obj);
1084} 1078}
1085 1079
1086EAPI void
1087evas_object_image_size_get(const Evas_Image *obj, int *w, int *h)
1088{
1089 efl_gfx_view_size_get((Evas_Image *)obj, w, h);
1090}
1091
1092EOLIAN static void 1080EOLIAN static void
1093_evas_image_efl_gfx_view_view_size_get(Eo *eo_obj, Evas_Image_Data *o, int *w, int *h) 1081_evas_image_efl_gfx_view_view_size_get(Eo *eo_obj, Evas_Image_Data *o, int *w, int *h)
1094{ 1082{
@@ -1132,15 +1120,15 @@ _evas_image_efl_gfx_view_view_size_get(Eo *eo_obj, Evas_Image_Data *o, int *w, i
1132} 1120}
1133 1121
1134EOLIAN static int 1122EOLIAN static int
1135_evas_image_stride_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) 1123_evas_image_efl_gfx_buffer_buffer_stride_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
1136{ 1124{
1137 return o->cur->image.stride;; 1125 return o->cur->image.stride;
1138} 1126}
1139 1127
1140EOLIAN static Evas_Load_Error 1128EOLIAN static Efl_Image_Load_Error
1141_evas_image_load_error_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) 1129_evas_image_efl_image_load_load_error_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
1142{ 1130{
1143 return o->load_error; 1131 return (Efl_Image_Load_Error) o->load_error;
1144} 1132}
1145 1133
1146/* deprecated */ 1134/* deprecated */
@@ -1311,18 +1299,6 @@ _evas_image_data_get(const Eo *eo_obj, Evas_Image_Data *_pd EINA_UNUSED, Eina_Bo
1311 return data; 1299 return data;
1312} 1300}
1313 1301
1314EAPI void
1315evas_object_image_preload(Evas_Object *eo_obj, Eina_Bool cancel)
1316{
1317 MAGIC_CHECK(eo_obj, Evas_Object, MAGIC_OBJ);
1318 return;
1319 MAGIC_CHECK_END();
1320 if (cancel)
1321 evas_obj_image_preload_cancel(eo_obj);
1322 else
1323 evas_obj_image_preload_begin(eo_obj);
1324}
1325
1326static void 1302static void
1327_image_preload_internal(Eo *eo_obj, void *_pd, Eina_Bool cancel) 1303_image_preload_internal(Eo *eo_obj, void *_pd, Eina_Bool cancel)
1328{ 1304{
@@ -1356,7 +1332,7 @@ _image_preload_internal(Eo *eo_obj, void *_pd, Eina_Bool cancel)
1356} 1332}
1357 1333
1358EOLIAN static void 1334EOLIAN static void
1359_evas_image_preload_begin(Eo *eo_obj, Evas_Image_Data *_pd EINA_UNUSED) 1335_evas_image_efl_image_load_load_async_start(Eo *eo_obj, Evas_Image_Data *_pd EINA_UNUSED)
1360{ 1336{
1361 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 1337 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
1362 evas_object_async_block(obj); 1338 evas_object_async_block(obj);
@@ -1364,7 +1340,7 @@ _evas_image_preload_begin(Eo *eo_obj, Evas_Image_Data *_pd EINA_UNUSED)
1364} 1340}
1365 1341
1366EOLIAN static void 1342EOLIAN static void
1367_evas_image_preload_cancel(Eo *eo_obj, Evas_Image_Data *_pd EINA_UNUSED) 1343_evas_image_efl_image_load_load_async_cancel(Eo *eo_obj, Evas_Image_Data *_pd EINA_UNUSED)
1368{ 1344{
1369 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 1345 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
1370 evas_object_async_block(obj); 1346 evas_object_async_block(obj);
@@ -1417,7 +1393,7 @@ _evas_image_data_copy_set(Eo *eo_obj, Evas_Image_Data *o, void *data)
1417} 1393}
1418 1394
1419EOLIAN static void 1395EOLIAN static void
1420_evas_image_data_update_add(Eo *eo_obj, Evas_Image_Data *o, int x, int y, int w, int h) 1396_evas_image_efl_gfx_buffer_buffer_update_region_add(Eo *eo_obj, Evas_Image_Data *o, int x, int y, int w, int h)
1421{ 1397{
1422 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 1398 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
1423 Eina_Rectangle *r; 1399 Eina_Rectangle *r;
@@ -1460,7 +1436,7 @@ _evas_image_data_update_add(Eo *eo_obj, Evas_Image_Data *o, int x, int y, int w,
1460} 1436}
1461 1437
1462EOLIAN static void 1438EOLIAN static void
1463_evas_image_alpha_set(Eo *eo_obj, Evas_Image_Data *o, Eina_Bool has_alpha) 1439_evas_image_efl_image_alpha_set(Eo *eo_obj, Evas_Image_Data *o, Eina_Bool has_alpha)
1464{ 1440{
1465 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 1441 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
1466 1442
@@ -1506,7 +1482,7 @@ _evas_image_alpha_set(Eo *eo_obj, Evas_Image_Data *o, Eina_Bool has_alpha)
1506} 1482}
1507 1483
1508EOLIAN static Eina_Bool 1484EOLIAN static Eina_Bool
1509_evas_image_alpha_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) 1485_evas_image_efl_image_alpha_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
1510{ 1486{
1511 return o->cur->has_alpha; 1487 return o->cur->has_alpha;
1512} 1488}
@@ -1868,7 +1844,7 @@ _evas_image_pixels_dirty_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
1868} 1844}
1869 1845
1870EOLIAN static void 1846EOLIAN static void
1871_evas_image_load_dpi_set(Eo *eo_obj, Evas_Image_Data *o, double dpi) 1847_evas_image_efl_image_load_load_dpi_set(Eo *eo_obj, Evas_Image_Data *o, double dpi)
1872{ 1848{
1873 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 1849 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
1874 if (dpi == o->load_opts->dpi) return; 1850 if (dpi == o->load_opts->dpi) return;
@@ -1888,13 +1864,13 @@ _evas_image_load_dpi_set(Eo *eo_obj, Evas_Image_Data *o, double dpi)
1888} 1864}
1889 1865
1890EOLIAN static double 1866EOLIAN static double
1891_evas_image_load_dpi_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) 1867_evas_image_efl_image_load_load_dpi_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
1892{ 1868{
1893 return o->load_opts->dpi; 1869 return o->load_opts->dpi;
1894} 1870}
1895 1871
1896EOLIAN static void 1872EOLIAN static void
1897_evas_image_efl_image_load_size_set(Eo *eo_obj, Evas_Image_Data *o, int w, int h) 1873_evas_image_efl_image_load_load_size_set(Eo *eo_obj, Evas_Image_Data *o, int w, int h)
1898{ 1874{
1899 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 1875 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
1900 if ((o->load_opts->w == w) && (o->load_opts->h == h)) return; 1876 if ((o->load_opts->w == w) && (o->load_opts->h == h)) return;
@@ -1918,14 +1894,14 @@ _evas_image_efl_image_load_size_set(Eo *eo_obj, Evas_Image_Data *o, int w, int h
1918} 1894}
1919 1895
1920EOLIAN static void 1896EOLIAN static void
1921_evas_image_efl_image_load_size_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o, int *w, int *h) 1897_evas_image_efl_image_load_load_size_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o, int *w, int *h)
1922{ 1898{
1923 if (w) *w = o->load_opts->w; 1899 if (w) *w = o->load_opts->w;
1924 if (h) *h = o->load_opts->h; 1900 if (h) *h = o->load_opts->h;
1925} 1901}
1926 1902
1927EOLIAN static void 1903EOLIAN static void
1928_evas_image_load_scale_down_set(Eo *eo_obj, Evas_Image_Data *o, int scale_down) 1904_evas_image_efl_image_load_load_scale_down_set(Eo *eo_obj, Evas_Image_Data *o, int scale_down)
1929{ 1905{
1930 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 1906 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
1931 if (o->load_opts->scale_down_by == scale_down) return; 1907 if (o->load_opts->scale_down_by == scale_down) return;
@@ -1945,13 +1921,13 @@ _evas_image_load_scale_down_set(Eo *eo_obj, Evas_Image_Data *o, int scale_down)
1945} 1921}
1946 1922
1947EOLIAN static int 1923EOLIAN static int
1948_evas_image_load_scale_down_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) 1924_evas_image_efl_image_load_load_scale_down_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
1949{ 1925{
1950 return o->load_opts->scale_down_by; 1926 return o->load_opts->scale_down_by;
1951} 1927}
1952 1928
1953EOLIAN static void 1929EOLIAN static void
1954_evas_image_load_region_set(Eo *eo_obj, Evas_Image_Data *o, int x, int y, int w, int h) 1930_evas_image_efl_image_load_load_region_set(Eo *eo_obj, Evas_Image_Data *o, int x, int y, int w, int h)
1955{ 1931{
1956 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 1932 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
1957 if ((o->load_opts->region.x == x) && (o->load_opts->region.y == y) && 1933 if ((o->load_opts->region.x == x) && (o->load_opts->region.y == y) &&
@@ -1977,7 +1953,7 @@ _evas_image_load_region_set(Eo *eo_obj, Evas_Image_Data *o, int x, int y, int w,
1977} 1953}
1978 1954
1979EOLIAN static void 1955EOLIAN static void
1980_evas_image_load_region_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o, int *x, int *y, int *w, int *h) 1956_evas_image_efl_image_load_load_region_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o, int *x, int *y, int *w, int *h)
1981{ 1957{
1982 if (x) *x = o->load_opts->region.x; 1958 if (x) *x = o->load_opts->region.x;
1983 if (y) *y = o->load_opts->region.y; 1959 if (y) *y = o->load_opts->region.y;
@@ -1986,7 +1962,7 @@ _evas_image_load_region_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o, int *x,
1986} 1962}
1987 1963
1988EOLIAN static void 1964EOLIAN static void
1989_evas_image_load_orientation_set(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o, Eina_Bool enable) 1965_evas_image_efl_image_load_load_orientation_set(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o, Eina_Bool enable)
1990{ 1966{
1991 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 1967 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
1992 if (o->load_opts->orientation == !!enable) return; 1968 if (o->load_opts->orientation == !!enable) return;
@@ -1998,15 +1974,17 @@ _evas_image_load_orientation_set(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o, Ein
1998} 1974}
1999 1975
2000EOLIAN static Eina_Bool 1976EOLIAN static Eina_Bool
2001_evas_image_load_orientation_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) 1977_evas_image_efl_image_load_load_orientation_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
2002{ 1978{
2003 return o->load_opts->orientation;; 1979 return o->load_opts->orientation;;
2004} 1980}
2005 1981
2006EOLIAN static void 1982/* FIXME: This should be deprecated and a legacy binding for pixel_set should be added */
2007_evas_image_colorspace_set(Eo *eo_obj, Evas_Image_Data *o, Evas_Colorspace cspace) 1983EAPI void
1984evas_object_image_colorspace_set(Evas_Object *eo_obj, Evas_Colorspace cspace)
2008{ 1985{
2009 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 1986 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
1987 Evas_Image_Data *o = eo_data_scope_get(eo_obj, MY_CLASS);
2010 evas_object_async_block(obj); 1988 evas_object_async_block(obj);
2011 1989
2012 _evas_object_image_cleanup(eo_obj, obj, o); 1990 _evas_object_image_cleanup(eo_obj, obj, o);
@@ -2019,10 +1997,10 @@ _evas_image_colorspace_set(Eo *eo_obj, Evas_Image_Data *o, Evas_Colorspace cspac
2019 ENFN->image_colorspace_set(ENDT, o->engine_data, cspace); 1997 ENFN->image_colorspace_set(ENDT, o->engine_data, cspace);
2020} 1998}
2021 1999
2022EOLIAN static Evas_Colorspace 2000EOLIAN static Efl_Gfx_Colorspace
2023_evas_image_colorspace_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) 2001_evas_image_efl_gfx_buffer_colorspace_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
2024{ 2002{
2025 return o->cur->cspace; 2003 return (Efl_Gfx_Colorspace) o->cur->cspace;
2026} 2004}
2027 2005
2028EOLIAN static void 2006EOLIAN static void
@@ -2243,14 +2221,11 @@ _evas_image_content_hint_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o)
2243} 2221}
2244 2222
2245EOLIAN static Eina_Bool 2223EOLIAN static Eina_Bool
2246_evas_image_region_support_get(Eo *eo_obj, Evas_Image_Data *o) 2224_evas_image_efl_image_load_load_region_support_get(Eo *eo_obj, Evas_Image_Data *o)
2247{ 2225{
2248 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); 2226 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS);
2249 2227
2250 Eina_Bool region; 2228 return ENFN->image_can_region_get(ENDT, o->engine_data);
2251 region = ENFN->image_can_region_get(ENDT, o->engine_data);
2252
2253 return region;
2254} 2229}
2255 2230
2256/* animated feature */ 2231/* animated feature */
@@ -4887,15 +4862,32 @@ evas_object_image_filled_add(Evas *eo_e)
4887} 4862}
4888 4863
4889EAPI void 4864EAPI void
4890evas_object_image_filled_set(Evas_Object *eo_obj, Eina_Bool value) 4865evas_object_image_fill_set(Evas_Image *obj,
4866 Evas_Coord x, Evas_Coord y,
4867 Evas_Coord w, Evas_Coord h)
4891{ 4868{
4892 efl_gfx_fill_filled_set(eo_obj, value); 4869 efl_gfx_fill_set((Evas_Image *)obj, x, y, w, h);
4870}
4871
4872EAPI void
4873evas_object_image_preload(Evas_Object *eo_obj, Eina_Bool cancel)
4874{
4875 if (cancel)
4876 efl_image_load_async_cancel(eo_obj);
4877 else
4878 efl_image_load_async_start(eo_obj);
4893} 4879}
4894 4880
4895EAPI Eina_Bool 4881EAPI Eina_Bool
4896evas_object_image_filled_get(const Evas_Object *eo_obj) 4882evas_object_image_filled_get(const Evas_Object *eo_obj)
4897{ 4883{
4898 return efl_gfx_fill_filled_get((Eo *) eo_obj); 4884 return efl_gfx_fill_filled_get(eo_obj);
4885}
4886
4887EAPI void
4888evas_object_image_filled_set(Evas_Object *eo_obj, Eina_Bool value)
4889{
4890 efl_gfx_fill_filled_set(eo_obj, value);
4899} 4891}
4900 4892
4901EAPI void 4893EAPI void
@@ -4903,7 +4895,7 @@ evas_object_image_fill_get(const Evas_Image *obj,
4903 Evas_Coord *x, Evas_Coord *y, 4895 Evas_Coord *x, Evas_Coord *y,
4904 Evas_Coord *w, Evas_Coord *h) 4896 Evas_Coord *w, Evas_Coord *h)
4905{ 4897{
4906 efl_gfx_fill_get((Evas_Image *)obj, x, y, w, h); 4898 efl_gfx_fill_get(obj, x, y, w, h);
4907} 4899}
4908 4900
4909EAPI void 4901EAPI void
@@ -4921,45 +4913,117 @@ evas_object_image_fill_spread_get(const Evas_Image *obj EINA_UNUSED)
4921} 4913}
4922 4914
4923EAPI void 4915EAPI void
4916evas_object_image_alpha_set(Evas_Object *obj, Eina_Bool alpha)
4917{
4918 efl_image_alpha_set(obj, alpha);
4919}
4920
4921EAPI Eina_Bool
4922evas_object_image_alpha_get(const Evas_Object *obj)
4923{
4924 return efl_image_alpha_get(obj);
4925}
4926
4927EAPI void
4928evas_object_image_border_set(Evas_Object *obj, int l, int r, int t, int b)
4929{
4930 efl_image_border_set(obj, l, r, t, b);
4931}
4932
4933EAPI void
4934evas_object_image_border_get(const Evas_Object *obj, int *l, int *r, int *t, int *b)
4935{
4936 efl_image_border_get(obj, l, r, t, b);
4937}
4938
4939EAPI void
4940evas_object_image_border_scale_set(Evas_Object *obj, double scale)
4941{
4942 efl_image_border_scale_set(obj, scale);
4943}
4944
4945EAPI double
4946evas_object_image_border_scale_get(const Evas_Object *obj)
4947{
4948 return efl_image_border_scale_get(obj);
4949}
4950
4951EAPI void
4952evas_object_image_border_center_fill_set(Evas_Object *obj, Evas_Border_Fill_Mode fill)
4953{
4954 efl_image_border_center_fill_set(obj, (Efl_Gfx_Border_Fill_Mode) fill);
4955}
4956
4957EAPI Evas_Border_Fill_Mode
4958evas_object_image_border_center_fill_get(const Evas_Object *obj)
4959{
4960 return (Evas_Border_Fill_Mode) efl_image_border_center_fill_get(obj);
4961}
4962
4963EAPI void
4964evas_object_image_size_get(const Evas_Image *obj, int *w, int *h)
4965{
4966 efl_gfx_view_size_get((Evas_Image *)obj, w, h);
4967}
4968
4969EAPI void
4924evas_object_image_size_set(Evas_Image *obj, int w, int h) 4970evas_object_image_size_set(Evas_Image *obj, int w, int h)
4925{ 4971{
4926 efl_gfx_view_size_set((Evas_Image *)obj, w, h); 4972 efl_gfx_view_size_set(obj, w, h);
4973}
4974
4975EAPI Evas_Colorspace
4976evas_object_image_colorspace_get(const Evas_Object *obj)
4977{
4978 return (Evas_Colorspace) efl_gfx_buffer_colorspace_get(obj);
4979}
4980
4981EAPI int
4982evas_object_image_stride_get(const Evas_Object *obj)
4983{
4984 return efl_gfx_buffer_stride_get(obj);
4985}
4986
4987EAPI void
4988evas_object_image_data_update_add(Evas_Object *obj, int x, int y, int w, int h)
4989{
4990 efl_gfx_buffer_update_region_add(obj, x, y, w, h);
4927} 4991}
4928 4992
4929EAPI void 4993EAPI void
4930evas_object_image_file_set(Eo *obj, const char *file, const char *key) 4994evas_object_image_file_set(Eo *obj, const char *file, const char *key)
4931{ 4995{
4932 efl_file_set((Eo *) obj, file, key); 4996 efl_file_set(obj, file, key);
4933} 4997}
4934 4998
4935EAPI void 4999EAPI void
4936evas_object_image_file_get(const Eo *obj, const char **file, const char **key) 5000evas_object_image_file_get(const Eo *obj, const char **file, const char **key)
4937{ 5001{
4938 efl_file_get((Eo *) obj, file, key); 5002 efl_file_get(obj, file, key);
4939} 5003}
4940 5004
4941EAPI void 5005EAPI void
4942evas_object_image_mmap_set(Evas_Image *obj, const Eina_File *f, const char *key) 5006evas_object_image_mmap_set(Evas_Image *obj, const Eina_File *f, const char *key)
4943{ 5007{
4944 efl_file_mmap_set((Evas_Image *)obj, f, key); 5008 efl_file_mmap_set(obj, f, key);
4945} 5009}
4946 5010
4947EAPI void 5011EAPI void
4948evas_object_image_mmap_get(const Evas_Image *obj, const Eina_File **f, const char **key) 5012evas_object_image_mmap_get(const Evas_Image *obj, const Eina_File **f, const char **key)
4949{ 5013{
4950 efl_file_mmap_get((Evas_Image *)obj, f, key); 5014 efl_file_mmap_get(obj, f, key);
4951} 5015}
4952 5016
4953EAPI Eina_Bool 5017EAPI Eina_Bool
4954evas_object_image_save(const Eo *obj, const char *file, const char *key, const char *flags) 5018evas_object_image_save(const Eo *obj, const char *file, const char *key, const char *flags)
4955{ 5019{
4956 return efl_file_save((Eo *) obj, file, key, flags); 5020 return efl_file_save(obj, file, key, flags);
4957} 5021}
4958 5022
4959EAPI Eina_Bool 5023EAPI Eina_Bool
4960evas_object_image_animated_get(const Eo *obj) 5024evas_object_image_animated_get(const Eo *obj)
4961{ 5025{
4962 return efl_image_animated_get((Eo *) obj); 5026 return efl_image_animated_get(obj);
4963} 5027}
4964 5028
4965EAPI void 5029EAPI void
@@ -4995,25 +5059,97 @@ evas_object_image_animated_frame_duration_get(const Evas_Object *obj, int start_
4995EAPI void 5059EAPI void
4996evas_object_image_load_size_set(Eo *obj, int w, int h) 5060evas_object_image_load_size_set(Eo *obj, int w, int h)
4997{ 5061{
4998 efl_image_load_size_set((Eo *) obj, w, h); 5062 efl_image_load_size_set(obj, w, h);
4999} 5063}
5000 5064
5001EAPI void 5065EAPI void
5002evas_object_image_load_size_get(const Eo *obj, int *w, int *h) 5066evas_object_image_load_size_get(const Eo *obj, int *w, int *h)
5003{ 5067{
5004 efl_image_load_size_get((Eo *) obj, w, h); 5068 efl_image_load_size_get(obj, w, h);
5069}
5070
5071EAPI void
5072evas_object_image_load_dpi_set(Evas_Object *obj, double dpi)
5073{
5074 efl_image_load_dpi_set(obj, dpi);
5075}
5076
5077EAPI double
5078evas_object_image_load_dpi_get(const Evas_Object *obj)
5079{
5080 return efl_image_load_dpi_get(obj);
5081}
5082
5083EAPI void
5084evas_object_image_load_region_set(Evas_Object *obj, int x, int y, int w, int h)
5085{
5086 efl_image_load_region_set(obj, x, y, w, h);
5087}
5088
5089EAPI void
5090evas_object_image_load_region_get(const Evas_Object *obj, int *x, int *y, int *w, int *h)
5091{
5092 efl_image_load_region_get(obj, x, y, w, h);
5093}
5094
5095EAPI Eina_Bool
5096evas_object_image_region_support_get(const Evas_Image *obj)
5097{
5098 return efl_image_load_region_support_get(obj);
5099}
5100
5101EAPI void
5102evas_object_image_load_orientation_set(Evas_Object *obj, Eina_Bool enable)
5103{
5104 efl_image_load_orientation_set(obj, enable);
5105}
5106
5107EAPI Eina_Bool
5108evas_object_image_load_orientation_get(const Evas_Object *obj)
5109{
5110 return efl_image_load_orientation_get(obj);
5111}
5112
5113EAPI void
5114evas_object_image_load_scale_down_set(Evas_Object *obj, int scale_down)
5115{
5116 efl_image_load_scale_down_set(obj, scale_down);
5117}
5118
5119EAPI int
5120evas_object_image_load_scale_down_get(const Evas_Object *obj)
5121{
5122 return efl_image_load_scale_down_get(obj);
5123}
5124
5125EAPI Evas_Load_Error
5126evas_object_image_load_error_get(const Evas_Object *obj)
5127{
5128 return (Evas_Load_Error) efl_image_load_error_get(obj);
5005} 5129}
5006 5130
5007EAPI void 5131EAPI void
5008evas_object_image_smooth_scale_set(Eo *obj, Eina_Bool smooth_scale) 5132evas_object_image_smooth_scale_set(Eo *obj, Eina_Bool smooth_scale)
5009{ 5133{
5010 efl_image_smooth_scale_set((Eo *) obj, smooth_scale); 5134 efl_image_smooth_scale_set(obj, smooth_scale);
5011} 5135}
5012 5136
5013EAPI Eina_Bool 5137EAPI Eina_Bool
5014evas_object_image_smooth_scale_get(const Eo *obj) 5138evas_object_image_smooth_scale_get(const Eo *obj)
5015{ 5139{
5016 return efl_image_smooth_scale_get((Eo *) obj); 5140 return efl_image_smooth_scale_get(obj);
5141}
5142
5143EAPI void
5144evas_object_image_orient_set(Evas_Image *obj, Evas_Image_Orient orient)
5145{
5146 efl_image_orientation_set(obj, (Efl_Gfx_Orientation) orient);
5147}
5148
5149EAPI Evas_Image_Orient
5150evas_object_image_orient_get(const Evas_Image *obj)
5151{
5152 return (Evas_Image_Orient) efl_image_orientation_get(obj);
5017} 5153}
5018 5154
5019#include "canvas/evas_image.eo.c" 5155#include "canvas/evas_image.eo.c"