}
E_API void
-e_comp_image_filter_edge_detection_param_set(double thickness, int color_id)
+e_comp_image_filter_edge_detection_param_set(double thickness, unsigned int color_id)
{
e_comp->edge_detection_thickness = thickness;
e_comp->edge_detection_color_id = color_id;
EINTERN Eina_Bool
e_comp_object_image_filter_set(Evas_Object *obj, E_Comp_Image_Filter filter)
{
- char efl_gfx_lua_code[64] = "";
+ char efl_gfx_code[64] = "";
API_ENTRY EINA_FALSE;
EINA_SAFETY_ON_NULL_RETURN_VAL(cw->ec, EINA_FALSE);
if (e_object_is_del(E_OBJECT(cw->ec))) return EINA_FALSE;
if (!e_client_cdata_get(cw->ec)) return EINA_FALSE;
- if (cw->image_filter == filter) return EINA_TRUE;
-
switch (filter)
{
case E_COMP_IMAGE_FILTER_BLUR:
efl_gfx_filter_program_set(cw->obj, "inverse_color ()", "image_filter");
break;
case E_COMP_IMAGE_FILTER_EDGE_DETECTION:
- sprintf(efl_gfx_lua_code, "edge_detection { thickness = %lf, color_id = %d }",
+ snprintf(efl_gfx_code, sizeof(efl_gfx_code), "edge_detection { thickness = %lf, color_id = %u }",
e_comp->edge_detection_thickness, e_comp->edge_detection_color_id);
- efl_gfx_filter_program_set(cw->obj, efl_gfx_lua_code, "image_filter");
+ efl_gfx_filter_program_set(cw->obj, efl_gfx_code, "image_filter");
break;
case E_COMP_IMAGE_FILTER_NONE:
default:
E_Comp_Image_Filter image_filter;
double edge_detection_thickness;
- int edge_detection_color_id;
+ unsigned int edge_detection_color_id;
struct
{
E_API int e_comp_nocomp_override_get(void);
E_API Eina_Bool e_comp_image_filter_set(E_Comp_Image_Filter filter);
+E_API void e_comp_image_filter_edge_detection_param_set(double thickness, unsigned int color_id);
E_API E_Comp_Image_Filter e_comp_image_filter_get(void);
E_API void e_comp_ec_list_lock(void);