summaryrefslogtreecommitdiff
path: root/src/bin/ephoto_color.c
diff options
context:
space:
mode:
authorStephen Houston <smhouston88@gmail.com>2017-09-20 12:52:51 -0500
committerStephen Houston <smhouston88@gmail.com>2017-09-20 12:52:51 -0500
commit2863d68423dc8127e046bffefdb84480a3f6e5e2 (patch)
tree419f80bb964dd9a16d1ec0b949cce3e8e42fb3b0 /src/bin/ephoto_color.c
parent223076607ea045680579f96ca2cbabfff7cf3799 (diff)
Enter commit summary
Ephoto: Formatting And change details Committed via EDI: Cool!
Diffstat (limited to 'src/bin/ephoto_color.c')
-rw-r--r--src/bin/ephoto_color.c30
1 files changed, 20 insertions, 10 deletions
diff --git a/src/bin/ephoto_color.c b/src/bin/ephoto_color.c
index 36a0f20..4d9548d 100644
--- a/src/bin/ephoto_color.c
+++ b/src/bin/ephoto_color.c
@@ -27,7 +27,8 @@ enum _Ephoto_Color_Adjust
27}; 27};
28 28
29unsigned int * 29unsigned int *
30_ephoto_apply_color_adjustment(Ephoto_Color *eco, unsigned int *image_data, int adjust, Ephoto_Color_Adjust color) 30_ephoto_apply_color_adjustment(Ephoto_Color *eco, unsigned int *image_data,
31 int adjust, Ephoto_Color_Adjust color)
31{ 32{
32 unsigned int *im_data, *im_data_new, *p1, *p2; 33 unsigned int *im_data, *im_data_new, *p1, *p2;
33 Evas_Coord x, y; 34 Evas_Coord x, y;
@@ -103,9 +104,12 @@ _red_slider_changed(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
103 unsigned int *image_data, *image_data_two; 104 unsigned int *image_data, *image_data_two;
104 105
105 red = elm_slider_value_get(obj); 106 red = elm_slider_value_get(obj);
106 image_data = _ephoto_apply_color_adjustment(eco, NULL, red, EPHOTO_COLOR_ADJUST_RED); 107 image_data = _ephoto_apply_color_adjustment(eco, NULL, red,
107 image_data_two = _ephoto_apply_color_adjustment(eco, image_data, eco->green, EPHOTO_COLOR_ADJUST_GREEN); 108 EPHOTO_COLOR_ADJUST_RED);
108 _ephoto_apply_color_adjustment(eco, image_data_two, eco->blue, EPHOTO_COLOR_ADJUST_BLUE); 109 image_data_two = _ephoto_apply_color_adjustment(eco, image_data, eco->green,
110 EPHOTO_COLOR_ADJUST_GREEN);
111 _ephoto_apply_color_adjustment(eco, image_data_two, eco->blue,
112 EPHOTO_COLOR_ADJUST_BLUE);
109} 113}
110 114
111static void 115static void
@@ -117,9 +121,12 @@ _green_slider_changed(void *data, Evas_Object *obj,
117 unsigned int *image_data, *image_data_two; 121 unsigned int *image_data, *image_data_two;
118 122
119 green = elm_slider_value_get(obj); 123 green = elm_slider_value_get(obj);
120 image_data = _ephoto_apply_color_adjustment(eco, NULL, green, EPHOTO_COLOR_ADJUST_GREEN); 124 image_data = _ephoto_apply_color_adjustment(eco, NULL, green,
121 image_data_two = _ephoto_apply_color_adjustment(eco, image_data, eco->red, EPHOTO_COLOR_ADJUST_RED); 125 EPHOTO_COLOR_ADJUST_GREEN);
122 _ephoto_apply_color_adjustment(eco, image_data_two, eco->blue, EPHOTO_COLOR_ADJUST_BLUE); 126 image_data_two = _ephoto_apply_color_adjustment(eco, image_data, eco->red,
127 EPHOTO_COLOR_ADJUST_RED);
128 _ephoto_apply_color_adjustment(eco, image_data_two, eco->blue,
129 EPHOTO_COLOR_ADJUST_BLUE);
123} 130}
124 131
125static void 132static void
@@ -131,9 +138,12 @@ _blue_slider_changed(void *data, Evas_Object *obj,
131 unsigned int *image_data, *image_data_two; 138 unsigned int *image_data, *image_data_two;
132 139
133 blue = elm_slider_value_get(obj); 140 blue = elm_slider_value_get(obj);
134 image_data = _ephoto_apply_color_adjustment(eco, NULL, blue, EPHOTO_COLOR_ADJUST_BLUE); 141 image_data = _ephoto_apply_color_adjustment(eco, NULL, blue,
135 image_data_two = _ephoto_apply_color_adjustment(eco, image_data, eco->red, EPHOTO_COLOR_ADJUST_RED); 142 EPHOTO_COLOR_ADJUST_BLUE);
136 _ephoto_apply_color_adjustment(eco, image_data_two, eco->green, EPHOTO_COLOR_ADJUST_GREEN); 143 image_data_two = _ephoto_apply_color_adjustment(eco, image_data, eco->red,
144 EPHOTO_COLOR_ADJUST_RED);
145 _ephoto_apply_color_adjustment(eco, image_data_two, eco->green,
146 EPHOTO_COLOR_ADJUST_GREEN);
137} 147}
138 148
139static Eina_Bool 149static Eina_Bool