- add_subwindow(new BC_Title(x, y, _("Slope:")));
- add_subwindow(slope = new ChromaKeySlope(plugin, x1, y));
-
- y += 30;
- add_subwindow(new BC_Title(x, y, _("Threshold:")));
- add_subwindow(threshold = new ChromaKeyThreshold(plugin, x1, y));
-
-
- y += 30;
- add_subwindow(use_value = new ChromaKeyUseValue(plugin, x1, y));
-
- y += 30;
- add_subwindow(use_colorpicker = new ChromaKeyUseColorPicker(plugin, this, x1, y));
-
- y += use_colorpicker->get_h() + 10;
- add_subwindow(new ChromaKeyReset(plugin, this, x, y));
+// Color section
+ add_subwindow(title_bar = new BC_TitleBar(x, y, get_w()-2*x, xs20, xs10, _("Color")));
+ y += ys20;
+ add_subwindow(color = new ChromaKeyColor(plugin, this, x, y));
+ // Info for Sample rectangle: x_slider w_slider w_sample
+ // \ | / y, w, h
+ add_subwindow(sample = new BC_SubWindow(x3 + xs200 - xs100, y, xs100, ys50));
+ y += ys30;
+ add_subwindow(use_colorpicker = new ChromaKeyUseColorPicker(plugin, this, x, y));
+
+// Key parameters section
+ y += ys30;
+ add_subwindow(title_bar = new BC_TitleBar(x, y, get_w()-2*x, xs20, xs10, _("Key parameters")));
+ y += ys20;
+ add_subwindow(title = new BC_Title(x, y, _("Threshold:")));
+ threshold_text = new ChromaKeyFText(plugin, this,
+ 0, &(plugin->config.threshold), (x + x2), y, MIN_VALUE, MAX_VALUE);
+ threshold_text->create_objects();
+ threshold_slider = new ChromaKeyFSlider(plugin,
+ threshold_text, &(plugin->config.threshold), x3, y, MIN_VALUE, MAX_VALUE, xs200);
+ add_subwindow(threshold_slider);
+ threshold_text->slider = threshold_slider;
+ add_subwindow(threshold_Clr = new ChromaKeyClr(plugin, this, clr_x, y, RESET_THRESHOLD));
+ y += ys30;
+
+ add_subwindow(title = new BC_Title(x, y, _("Slope:")));
+ slope_text = new ChromaKeyFText(plugin, this,
+ 0, &(plugin->config.slope), (x + x2), y, MIN_VALUE, MAX_VALUE);
+ slope_text->create_objects();
+ slope_slider = new ChromaKeyFSlider(plugin,
+ slope_text, &(plugin->config.slope), x3, y, MIN_VALUE, MAX_VALUE, xs200);
+ add_subwindow(slope_slider);
+ slope_text->slider = slope_slider;
+ add_subwindow(slope_Clr = new ChromaKeyClr(plugin, this, clr_x, y, RESET_SLOPE));
+ y += ys30;
+
+ add_subwindow(use_value = new ChromaKeyUseValue(plugin, x, y));
+ y += ys40;
+
+// Reset section
+ add_subwindow(bar = new BC_Bar(x, y, get_w()-2*x));
+ y += ys10;
+ add_subwindow(reset = new ChromaKeyReset(plugin, this, x, y));
+ add_subwindow(default_settings = new ChromaKeyDefaultSettings(plugin, this,
+ (get_w() - xs10 - defaultBtn_w), y, defaultBtn_w));