diff options
-rw-r--r-- | roi.c | 9 |
1 files changed, 4 insertions, 5 deletions
@@ -109,14 +109,13 @@ static gboolean do_roi(struct roi *roi) { GdkPixbuf *match; - cairo_rectangle_t area; + double x, y, width, height; - calc_rubberband_rect(roi, &area.x, &area.y, &area.width, &area.height); - if (area.width < 1 || area.height < 1) + calc_rubberband_rect(roi, &x, &y, &width, &height); + if (width < 1 || height < 1) return FALSE; - match = gdk_pixbuf_new_subpixbuf(roi->input, area.x, area.y, - area.width, area.height); + match = gdk_pixbuf_new_subpixbuf(roi->input, x, y, width, height); calc_roi_interval(roi, match); g_object_unref(match); |