![]() |
Ansel 0.0
A darktable fork - bloat + design vision
|
#include "common/extra_optimizations.h"#include <assert.h>#include <math.h>#include <stdlib.h>#include <stdio.h>#include <string.h>#include <time.h>#include "bauhaus/bauhaus.h"#include "common/darktable.h"#include "develop/masks.h"#include "common/fast_guided_filter.h"#include "common/eigf.h"#include "common/interpolation.h"#include "common/luminance_mask.h"#include "common/opencl.h"#include "common/collection.h"#include "control/conf.h"#include "control/control.h"#include "develop/blend.h"#include "develop/develop.h"#include "develop/imageop.h"#include "develop/imageop_math.h"#include "develop/imageop_gui.h"#include "develop/pixelpipe_cache.h"#include "dtgtk/drawingarea.h"#include "dtgtk/expander.h"#include "gui/color_picker_proxy.h"#include "gui/draw.h"#include "gui/gtk.h"#include "gui/presets.h"#include "iop/iop_api.h"#include "iop/choleski.h"
Include dependency graph for toneequal.c:Data Structures | |
| struct | dt_iop_toneequalizer_params_t |
| struct | dt_iop_toneequalizer_data_t |
| struct | dt_iop_toneequalizer_global_data_t |
| struct | dt_iop_toneequalizer_gui_data_t |
Macros | |
| #define | UI_SAMPLES 256 |
| #define | CONTRAST_FULCRUM exp2f(-4.0f) |
| #define | MIN_FLOAT exp2f(-16.0f) |
| #define | CHANNELS 9 |
| #define | PIXEL_CHAN 8 |
| #define | LUT_RESOLUTION 10000 |
| #define | DT_TONEEQ_USE_LUT TRUE |
| #define | TEMP_SAMPLES 2 * UI_SAMPLES |
Typedefs | |
| typedef enum dt_iop_toneequalizer_filter_t | dt_iop_toneequalizer_filter_t |
| typedef struct dt_iop_toneequalizer_params_t | dt_iop_toneequalizer_params_t |
| typedef struct dt_iop_toneequalizer_data_t | dt_iop_toneequalizer_data_t |
| typedef struct dt_iop_toneequalizer_global_data_t | dt_iop_toneequalizer_global_data_t |
| typedef struct dt_iop_toneequalizer_gui_data_t | dt_iop_toneequalizer_gui_data_t |
Enumerations | |
| enum | dt_iop_toneequalizer_filter_t { DT_TONEEQ_NONE = 0 , DT_TONEEQ_AVG_GUIDED , DT_TONEEQ_GUIDED , DT_TONEEQ_AVG_EIGF , DT_TONEEQ_EIGF } |
Functions | |
| const char * | name () |
| const char * | aliases () |
| const char ** | description (struct dt_iop_module_t *self) |
| int | default_group () |
| int | flags () |
| int | default_colorspace (dt_iop_module_t *self, dt_dev_pixelpipe_t *pipe, const dt_dev_pixelpipe_iop_t *piece) |
| void | input_format (dt_iop_module_t *self, dt_dev_pixelpipe_t *pipe, dt_dev_pixelpipe_iop_t *piece, dt_iop_buffer_dsc_t *dsc) |
| int | legacy_params (dt_iop_module_t *self, const void *const old_params, const int old_version, void *new_params, const int new_version) |
| static void | compress_shadows_highlight_preset_set_exposure_params (dt_iop_toneequalizer_params_t *p, const float step) |
| static void | dilate_shadows_highlight_preset_set_exposure_params (dt_iop_toneequalizer_params_t *p, const float step) |
| void | init_presets (dt_iop_module_so_t *self) |
| static gboolean | in_mask_editing (dt_iop_module_t *self) |
| static void | invalidate_luminance_cache (dt_iop_module_t *const self) |
| static int | sanity_check (dt_iop_module_t *self) |
| static float | get_luminance_from_buffer (const float *const buffer, const size_t width, const size_t height, const size_t x, const size_t y) |
| static float | gaussian_denom (const float sigma) |
| static float | gaussian_func (const float radius, const float denominator) |
| static __DT_CLONE_TARGETS__ void | apply_toneequalizer (const float *const restrict in, const float *const restrict luminance, float *const restrict out, const dt_iop_roi_t *const roi_in, const dt_iop_roi_t *const roi_out, const size_t ch, const dt_iop_toneequalizer_data_t *const d) |
| static float | pixel_correction (const float exposure, const float *const restrict factors, const float sigma) |
| static int | compute_luminance_mask (const float *const restrict in, float *const restrict luminance, const size_t width, const size_t height, const size_t ch, const dt_iop_toneequalizer_data_t *const d) |
| static __DT_CLONE_TARGETS__ void | display_luminance_mask (const float *const restrict in, const float *const restrict luminance, float *const restrict out, const dt_iop_roi_t *const roi_in, const dt_iop_roi_t *const roi_out, const dt_dev_pixelpipe_t *pipe, const size_t ch) |
| static int | toneeq_process (struct dt_iop_module_t *self, const dt_dev_pixelpipe_t *pipe, const dt_dev_pixelpipe_iop_t *piece, const void *const restrict ivoid, void *const restrict ovoid, const dt_iop_roi_t *const roi_in, const dt_iop_roi_t *const roi_out) |
| int | process (struct dt_iop_module_t *self, const dt_dev_pixelpipe_t *pipe, const dt_dev_pixelpipe_iop_t *piece, const void *const restrict ivoid, void *const restrict ovoid) |
| void | modify_roi_in (struct dt_iop_module_t *self, struct dt_dev_pixelpipe_iop_t *piece, const dt_iop_roi_t *roi_out, dt_iop_roi_t *roi_in) |
| static void | compute_correction_lut (float *restrict lut, const float sigma, const float *const restrict factors) |
| static void | get_channels_gains (float factors[9], const dt_iop_toneequalizer_params_t *p) |
| static void | get_channels_factors (float factors[9], const dt_iop_toneequalizer_params_t *p) |
| static int | compute_channels_factors (const float factors[8], float out[9], const float sigma) |
| static int | compute_channels_gains (const float in[9], float out[9]) |
| static int | commit_channels_gains (const float factors[9], dt_iop_toneequalizer_params_t *p) |
| static void | gui_cache_init (struct dt_iop_module_t *self) |
| static void | build_interpolation_matrix (float A[9 *8], const float sigma) |
| static __DT_CLONE_TARGETS__ void | compute_log_histogram_and_stats (const float *const restrict luminance, int histogram[256], const size_t num_elem, int *max_histogram, float *first_decile, float *last_decile) |
| static void | update_histogram (struct dt_iop_module_t *const self) |
| static __DT_CLONE_TARGETS__ void | compute_lut_correction (struct dt_iop_toneequalizer_gui_data_t *g, const float offset, const float scaling) |
| static gboolean | update_curve_lut (struct dt_iop_module_t *self) |
| void | init_global (dt_iop_module_so_t *module) |
| void | cleanup_global (dt_iop_module_so_t *module) |
| void | commit_params (struct dt_iop_module_t *self, dt_iop_params_t *p1, dt_dev_pixelpipe_t *pipe, dt_dev_pixelpipe_iop_t *piece) |
| void | init_pipe (struct dt_iop_module_t *self, dt_dev_pixelpipe_t *pipe, dt_dev_pixelpipe_iop_t *piece) |
| void | cleanup_pipe (struct dt_iop_module_t *self, dt_dev_pixelpipe_t *pipe, dt_dev_pixelpipe_iop_t *piece) |
| void | show_guiding_controls (struct dt_iop_module_t *self) |
| void | update_exposure_sliders (dt_iop_toneequalizer_gui_data_t *g, dt_iop_toneequalizer_params_t *p) |
| void | gui_update (struct dt_iop_module_t *self) |
| Refresh GUI controls from current params and configuration. | |
| void | gui_changed (dt_iop_module_t *self, GtkWidget *w, void *previous) |
| static void | smoothing_callback (GtkWidget *slider, gpointer user_data) |
| static void | auto_adjust_exposure_boost (GtkWidget *quad, gpointer user_data) |
| static void | auto_adjust_contrast_boost (GtkWidget *quad, gpointer user_data) |
| static void | show_luminance_mask_callback (GtkWidget *togglebutton, GdkEventButton *event, dt_iop_module_t *self) |
| static void | _switch_cursors (struct dt_iop_module_t *self) |
| int | mouse_moved (struct dt_iop_module_t *self, double x, double y, double pressure, int which) |
| int | mouse_leave (struct dt_iop_module_t *self) |
| static int | set_new_params_interactive (const float control_exposure, const float exposure_offset, const float blending_sigma, dt_iop_toneequalizer_gui_data_t *g, dt_iop_toneequalizer_params_t *p) |
| int | scrolled (struct dt_iop_module_t *self, double x, double y, int up, uint32_t state) |
| static gboolean | _init_drawing (dt_iop_module_t *const restrict self, GtkWidget *widget, dt_iop_toneequalizer_gui_data_t *const restrict g) |
| void | cairo_draw_hatches (cairo_t *cr, double center[2], double span[2], int instances, double line_width, double shade) |
| static void | get_shade_from_luminance (cairo_t *cr, const float luminance, const float alpha) |
| static void | draw_exposure_cursor (cairo_t *cr, const double pointerx, const double pointery, const double radius, const float luminance, const float zoom_scale, const int instances, const float alpha) |
| static void | match_color_to_background (cairo_t *cr, const float exposure, const float alpha) |
| void | gui_post_expose (struct dt_iop_module_t *self, cairo_t *cr, int32_t width, int32_t height, int32_t pointerx, int32_t pointery) |
| void | gui_focus (struct dt_iop_module_t *self, gboolean in) |
| static void | init_nodes_x (dt_iop_toneequalizer_gui_data_t *g) |
| static void | init_nodes_y (dt_iop_toneequalizer_gui_data_t *g) |
| static gboolean | area_draw (GtkWidget *widget, cairo_t *cr, gpointer user_data) |
| static gboolean | area_enter_notify (GtkWidget *widget, GdkEventCrossing *event, gpointer user_data) |
| static gboolean | area_leave_notify (GtkWidget *widget, GdkEventCrossing *event, gpointer user_data) |
| static gboolean | area_button_press (GtkWidget *widget, GdkEventButton *event, gpointer user_data) |
| static gboolean | area_motion_notify (GtkWidget *widget, GdkEventMotion *event, gpointer user_data) |
| static gboolean | area_button_release (GtkWidget *widget, GdkEventButton *event, gpointer user_data) |
| static gboolean | notebook_button_press (GtkWidget *widget, GdkEventButton *event, gpointer user_data) |
| static void | _develop_ui_pipe_started_callback (gpointer instance, gpointer user_data) |
| static void | _develop_preview_pipe_finished_callback (gpointer instance, gpointer user_data) |
| static void | _develop_ui_pipe_finished_callback (gpointer instance, gpointer user_data) |
| void | gui_reset (struct dt_iop_module_t *self) |
| void | gui_init (struct dt_iop_module_t *self) |
| void | gui_cleanup (struct dt_iop_module_t *self) |
Variables | |
| static const float centers_ops[8] | DT_ALIGNED_ARRAY |
| static const dt_colormatrix_t | gauss_kernel |
| #define CHANNELS 9 |
Build the exposures octaves : band-pass filters with gaussian windows spaced by 1 EV
| #define CONTRAST_FULCRUM exp2f(-4.0f) |
| #define DT_TONEEQ_USE_LUT TRUE |
| #define LUT_RESOLUTION 10000 |
| #define MIN_FLOAT exp2f(-16.0f) |
| #define PIXEL_CHAN 8 |
| #define TEMP_SAMPLES 2 * UI_SAMPLES |
| #define UI_SAMPLES 256 |
| typedef struct dt_iop_toneequalizer_data_t dt_iop_toneequalizer_data_t |
| typedef struct dt_iop_toneequalizer_gui_data_t dt_iop_toneequalizer_gui_data_t |
| typedef struct dt_iop_toneequalizer_params_t dt_iop_toneequalizer_params_t |
|
static |
References _switch_cursors(), g, and dt_iop_module_t::gui_data.
Referenced by gui_cleanup(), and gui_init().
|
static |
References _switch_cursors(), g, and dt_iop_module_t::gui_data.
Referenced by gui_cleanup(), and gui_init().
|
static |
Post pipe events
References _switch_cursors(), darktable, dt_iop_gui_enter_critical_section(), dt_iop_gui_leave_critical_section(), dt_iop_module_t::enabled, dt_iop_module_t::expanded, g, darktable_t::gui, dt_iop_module_t::gui_data, and dt_gui_gtk_t::reset.
Referenced by gui_cleanup(), and gui_init().
|
inlinestatic |
x axis
y axis
References darktable_t::bauhaus, CHANNELS, darktable, dt_gui_gtk_t::dpi, dt_cairo_image_surface_create(), dt_cairo_perceptual_gradient(), dt_iop_gui_enter_critical_section(), dt_iop_gui_leave_critical_section(), DT_PIXEL_APPLY_DPI, g, dt_bauhaus_t::graph_border, dt_bauhaus_t::graph_fg, darktable_t::gui, INNER_PADDING, dt_bauhaus_t::pango_font_desc, dt_bauhaus_t::quad_width, set_color(), TRUE, and value.
Referenced by area_draw(), and gui_post_expose().
|
static |
References darktable_t::control, darktable, dt_iop_module_t::dev, dt_control_change_cursor(), dt_control_hinter_message(), dt_control_queue_redraw_center(), dt_control_set_cursor(), dt_iop_color_picker_is_visible(), dt_iop_gui_enter_critical_section(), dt_iop_gui_leave_critical_section(), dt_ui_main_window(), dt_iop_module_t::expanded, g, darktable_t::gui, dt_develop_t::gui_attached, dt_iop_module_t::gui_data, in_mask_editing(), dt_develop_t::pipe, dt_develop_t::preview_pipe, dt_dev_pixelpipe_t::processing, sanity_check(), and dt_gui_gtk_t::ui.
Referenced by _develop_preview_pipe_finished_callback(), _develop_ui_pipe_finished_callback(), _develop_ui_pipe_started_callback(), gui_focus(), and mouse_moved().
| const char * aliases | ( | ) |
|
inlinestatic |
References d, dt_load_simd_aligned(), dt_store_simd_aligned(), factors, fast_clamp(), gaussian_denom(), gaussian_func(), dt_iop_roi_t::height, i, out, PIXEL_CHAN, and dt_iop_roi_t::width.
Referenced by toneeq_process().
|
static |
References d, darktable, dt_iop_module_t::default_params, darktable_t::develop, dt_dev_add_history_item, dt_iop_color_picker_reset(), dt_iop_request_focus(), dt_iop_module_t::enabled, FALSE, g, darktable_t::gui, dt_iop_module_t::gui_data, p, dt_iop_module_t::params, dt_gui_gtk_t::reset, TRUE, update_exposure_sliders(), and dt_iop_module_t::widget.
Referenced by gui_init().
|
static |
References darktable, darktable_t::develop, dt_dev_add_history_item, dt_iop_gui_enter_critical_section(), dt_iop_gui_leave_critical_section(), dt_iop_request_focus(), dt_iop_module_t::enabled, FALSE, g, darktable_t::gui, dt_iop_module_t::gui_data, p, dt_iop_module_t::params, dt_gui_gtk_t::reset, TRUE, and update_exposure_sliders().
Referenced by gui_init().
|
static |
References _init_drawing(), darktable_t::bauhaus, CHANNELS, dt_bauhaus_t::color_fill, darktable, dt_draw_grid(), dt_iop_gui_enter_critical_section(), dt_iop_gui_leave_critical_section(), DT_PIXEL_APPLY_DPI, dtgtk_cairo_paint_gamut_check(), dt_iop_module_t::enabled, FALSE, g, dt_bauhaus_t::graph_bg, dt_bauhaus_t::graph_border, dt_bauhaus_t::graph_fg, dt_iop_module_t::gui_data, init_nodes_x(), init_nodes_y(), dt_bauhaus_t::inset_histogram, M_PI, set_color(), TRUE, UI_SAMPLES, update_curve_lut(), and update_histogram().
Referenced by gui_init().
|
static |
References darktable, dt_iop_gui_enter_critical_section(), dt_iop_gui_leave_critical_section(), dt_iop_module_t::enabled, FALSE, g, darktable_t::gui, dt_iop_module_t::gui_data, dt_gui_gtk_t::reset, and TRUE.
Referenced by gui_init().
|
static |
References darktable, darktable_t::develop, dt_dev_add_history_item, dt_iop_gui_enter_critical_section(), dt_iop_gui_leave_critical_section(), dt_iop_module_t::enabled, FALSE, g, darktable_t::gui, dt_iop_module_t::gui_data, p, dt_iop_module_t::params, dt_gui_gtk_t::reset, TRUE, and update_exposure_sliders().
Referenced by gui_init().
|
static |
References c, CONTRAST_FULCRUM, darktable, dt_iop_module_t::dev, darktable_t::develop, dt_bauhaus_slider_set(), dt_control_log(), dt_dev_add_history_item, dt_iop_color_picker_reset(), dt_iop_gui_enter_critical_section(), dt_iop_gui_leave_critical_section(), dt_iop_request_focus(), DT_TONEEQ_EIGF, DT_TONEEQ_GUIDED, dt_iop_module_t::enabled, g, darktable_t::gui, dt_iop_module_t::gui_data, invalidate_luminance_cache(), mix(), p, dt_iop_module_t::params, dt_develop_t::pipe, dt_dev_pixelpipe_t::processing, dt_gui_gtk_t::reset, TRUE, and update_histogram().
Referenced by gui_init().
References c, CONTRAST_FULCRUM, darktable, dt_iop_module_t::dev, darktable_t::develop, dt_bauhaus_slider_set(), dt_control_log(), dt_dev_add_history_item, dt_iop_color_picker_reset(), dt_iop_gui_enter_critical_section(), dt_iop_gui_leave_critical_section(), dt_iop_request_focus(), dt_iop_module_t::enabled, g, darktable_t::gui, dt_iop_module_t::gui_data, invalidate_luminance_cache(), mix(), p, dt_iop_module_t::params, dt_develop_t::pipe, dt_dev_pixelpipe_t::processing, dt_gui_gtk_t::reset, TRUE, and update_histogram().
Referenced by gui_init().
|
inlinestatic |
References A, CHANNELS, gaussian_denom(), gaussian_func(), i, and PIXEL_CHAN.
Referenced by commit_params(), and update_curve_lut().
| void cairo_draw_hatches | ( | cairo_t * | cr, |
| double | center[2], | ||
| double | span[2], | ||
| int | instances, | ||
| double | line_width, | ||
| double | shade | ||
| ) |
References delta, double(), and i.
Referenced by draw_exposure_cursor().
| void cleanup_global | ( | dt_iop_module_so_t * | module | ) |
References dt_iop_module_so_t::data, and dt_free.
| void cleanup_pipe | ( | struct dt_iop_module_t * | self, |
| dt_dev_pixelpipe_t * | pipe, | ||
| dt_dev_pixelpipe_iop_t * | piece | ||
| ) |
References dt_dev_pixelpipe_iop_t::data, and dt_free_align.
|
static |
Referenced by set_new_params_interactive().
| void commit_params | ( | struct dt_iop_module_t * | self, |
| dt_iop_params_t * | p1, | ||
| dt_dev_pixelpipe_t * | pipe, | ||
| dt_dev_pixelpipe_iop_t * | piece | ||
| ) |
References A, build_interpolation_matrix(), CHANNELS, compute_correction_lut(), d, dt_dev_pixelpipe_iop_t::data, dt_iop_module_t::dev, DT_ALIGNED_ARRAY, dt_iop_gui_enter_critical_section(), dt_iop_gui_leave_critical_section(), dt_simd_memcpy(), factors, FALSE, g, get_channels_factors(), dt_develop_t::gui_attached, dt_iop_module_t::gui_data, p, PIXEL_CHAN, pseudo_solve(), and update_curve_lut().
|
static |
References p.
Referenced by init_presets().
|
static |
References CHANNELS, factors, i, out, PIXEL_CHAN, and pixel_correction().
Referenced by set_new_params_interactive().
|
static |
References CHANNELS, i, out, and PIXEL_CHAN.
Referenced by set_new_params_interactive().
|
static |
References factors, fast_clamp(), gaussian_denom(), gaussian_func(), i, lut, LUT_RESOLUTION, and PIXEL_CHAN.
Referenced by commit_params().
|
inlinestatic |
References i, TEMP_SAMPLES, and UI_SAMPLES.
Referenced by update_histogram().
|
inlinestatic |
References CONTRAST_FULCRUM, d, DT_GF_BLENDING_GEOMEAN, DT_GF_BLENDING_LINEAR, DT_TONEEQ_AVG_EIGF, DT_TONEEQ_AVG_GUIDED, DT_TONEEQ_EIGF, DT_TONEEQ_GUIDED, DT_TONEEQ_NONE, fast_eigf_surface_blur(), fast_surface_blur(), height, luminance_mask(), and width.
Referenced by toneeq_process().
|
inlinestatic |
References factors, g, pixel_correction(), scaling, UI_SAMPLES, and x.
Referenced by update_curve_lut().
| int default_colorspace | ( | dt_iop_module_t * | self, |
| dt_dev_pixelpipe_t * | pipe, | ||
| const dt_dev_pixelpipe_iop_t * | piece | ||
| ) |
References IOP_CS_RGB.
| int default_group | ( | ) |
References IOP_GROUP_TONES.
| const char ** description | ( | struct dt_iop_module_t * | self | ) |
References dt_iop_set_description().
|
static |
References p.
Referenced by init_presets().
|
inlinestatic |
References DT_DEV_PIXELPIPE_DISPLAY_MASK, dt_simd_set1(), dt_store_simd_aligned(), dt_iop_roi_t::height, i, dt_dev_pixelpipe_t::mask_display, out, dt_iop_roi_t::width, dt_iop_roi_t::x, and dt_iop_roi_t::y.
Referenced by toneeq_process().
|
static |
References cairo_draw_hatches(), DT_PIXEL_APPLY_DPI, get_shade_from_luminance(), and M_PI.
Referenced by gui_post_expose().
| int flags | ( | ) |
References IOP_FLAGS_INCLUDE_IN_STYLES, and IOP_FLAGS_SUPPORTS_BLENDING.
|
static |
|
static |
|
static |
References c, CHANNELS, factors, get_channels_gains(), and p.
Referenced by commit_params(), set_new_params_interactive(), smoothing_callback(), and update_curve_lut().
|
static |
References CHANNELS, factors, and p.
Referenced by get_channels_factors().
|
static |
References DT_ALIGNED_PIXEL, for_each_channel, gauss_kernel, height, i, MAX, MIN, width, and x.
Referenced by gui_post_expose(), mouse_moved(), and scrolled().
|
static |
Referenced by draw_exposure_cursor(), gui_post_expose(), and match_color_to_background().
|
static |
References dt_iop_gui_enter_critical_section(), dt_iop_gui_leave_critical_section(), DT_PIXELPIPE_CACHE_HASH_INVALID, FALSE, g, dt_iop_module_t::gui_data, and TRUE.
Referenced by gui_init().
| void gui_changed | ( | dt_iop_module_t * | self, |
| GtkWidget * | w, | ||
| void * | previous | ||
| ) |
| void gui_cleanup | ( | struct dt_iop_module_t * | self | ) |
References _develop_preview_pipe_finished_callback(), _develop_ui_pipe_finished_callback(), _develop_ui_pipe_started_callback(), darktable, dt_conf_set_int(), DT_DEBUG_CONTROL_SIGNAL_DISCONNECT, dt_dev_pixelpipe_cache_ref_count_entry(), DT_REQUEST_COLORPICK_OFF, FALSE, g, dt_iop_module_t::gui_data, IOP_GUI_FREE, darktable_t::pixelpipe_cache, dt_iop_module_t::request_color_pick, and darktable_t::signals.
| void gui_focus | ( | struct dt_iop_module_t * | self, |
| gboolean | in | ||
| ) |
References _switch_cursors(), darktable_t::collection, darktable_t::control, darktable, dt_iop_module_t::dev, dt_collection_hint_message(), dt_control_hinter_message(), dt_dev_distort_get_iop_pipe(), dt_dev_pixelpipe_cache_peek(), dt_dev_pixelpipe_cache_ref_count_entry(), dt_dev_pixelpipe_update_history_main, dt_dev_pixelpipe_update_history_preview, dt_hash(), dt_iop_gui_enter_critical_section(), dt_iop_gui_leave_critical_section(), dt_iop_module_t::enabled, dt_dev_pixelpipe_iop_t::enabled, FALSE, g, dt_dev_pixelpipe_iop_t::global_hash, dt_iop_module_t::gui_data, dt_iop_roi_t::height, darktable_t::pixelpipe_cache, dt_develop_t::preview_pipe, dt_dev_pixelpipe_t::processing, dt_dev_pixelpipe_iop_t::roi_in, TRUE, and dt_iop_roi_t::width.
| void gui_init | ( | struct dt_iop_module_t * | self | ) |
References _develop_preview_pipe_finished_callback(), _develop_ui_pipe_finished_callback(), _develop_ui_pipe_started_callback(), area_button_press(), area_button_release(), area_draw(), area_enter_notify(), area_leave_notify(), area_motion_notify(), auto_adjust_contrast_boost(), auto_adjust_exposure_boost(), darktable_t::bauhaus, darktable, dt_bauhaus_combobox_from_params(), dt_bauhaus_combobox_remove_at(), dt_bauhaus_slider_from_params(), dt_bauhaus_slider_new_with_range(), dt_bauhaus_slider_set_format(), dt_bauhaus_slider_set_soft_max(), dt_bauhaus_slider_set_soft_range(), dt_bauhaus_widget_set_label(), dt_bauhaus_widget_set_quad_paint(), dt_bauhaus_widget_set_quad_toggle(), dt_conf_get_int(), DT_DEBUG_CONTROL_SIGNAL_CONNECT, dt_gui_add_class(), DT_GUI_MODULE, dt_iop_togglebutton_new(), DT_SIGNAL_DEVELOP_HISTORY_CHANGE, DT_SIGNAL_DEVELOP_PREVIEW_PIPE_FINISHED, DT_SIGNAL_DEVELOP_UI_PIPE_FINISHED, DT_TONEEQ_LAST, dt_ui_label_new(), dt_ui_notebook_new(), dt_ui_notebook_page(), dtgtk_cairo_paint_showmask(), dtgtk_cairo_paint_wand(), dtgtk_drawing_area_new_with_aspect_ratio(), DTGTK_TOGGLEBUTTON, dtgtk_togglebutton_set_paint(), FALSE, g, darktable_t::gui, gui_cache_init(), IOP_GUI_ALLOC, notebook_button_press(), dt_gui_gtk_t::scroll_mask, show_luminance_mask_callback(), darktable_t::signals, smoothing_callback(), TRUE, and dt_iop_module_t::widget.
| void gui_post_expose | ( | struct dt_iop_module_t * | self, |
| cairo_t * | cr, | ||
| int32_t | width, | ||
| int32_t | height, | ||
| int32_t | pointerx, | ||
| int32_t | pointery | ||
| ) |
References _init_drawing(), darktable_t::bauhaus, CHANNELS, darktable, dt_iop_module_t::dev, dt_gui_gtk_t::dpi, draw_exposure_cursor(), DT_ALIGNED_ARRAY, dt_dev_get_overlay_scale(), dt_dev_pixelpipe_cache_rdlock_entry(), dt_dev_pixelpipe_cache_ref_count_entry(), dt_dev_rescale_roi(), dt_iop_gui_enter_critical_section(), dt_iop_gui_leave_critical_section(), DT_PIXEL_APPLY_DPI, dt_pixel_cache_entry_get_data(), dt_simd_memcpy(), dt_iop_module_t::enabled, factors, FALSE, g, get_luminance_from_buffer(), get_shade_from_luminance(), darktable_t::gui, dt_iop_module_t::gui_data, height, i, in_mask_editing(), M_PI, match_color_to_background(), dt_bauhaus_t::pango_font_desc, dt_develop_t::pipe, PIXEL_CHAN, pixel_correction(), darktable_t::pixelpipe_cache, dt_dev_pixelpipe_t::processing, sanity_check(), TRUE, dt_iop_module_t::widget, and width.
| void gui_reset | ( | struct dt_iop_module_t * | self | ) |
| void gui_update | ( | struct dt_iop_module_t * | self | ) |
Refresh GUI controls from current params and configuration.
gui callbacks, these are needed.
References dt_bauhaus_slider_set(), g, dt_iop_module_t::gui_data, invalidate_luminance_cache(), p, dt_iop_module_t::params, and show_guiding_controls().
|
static |
Helper functions
References dt_iop_module_t::dev, dt_masks_get_visible_form(), and dt_develop_t::form_gui.
Referenced by _switch_cursors(), and gui_post_expose().
| void init_global | ( | dt_iop_module_so_t * | module | ) |
|
inlinestatic |
References CHANNELS, g, i, and TRUE.
Referenced by area_draw().
|
inlinestatic |
References CHANNELS, g, i, and TRUE.
Referenced by area_draw().
| void init_pipe | ( | struct dt_iop_module_t * | self, |
| dt_dev_pixelpipe_t * | pipe, | ||
| dt_dev_pixelpipe_iop_t * | piece | ||
| ) |
References dt_dev_pixelpipe_iop_t::data, dt_dev_pixelpipe_iop_t::data_size, and dt_calloc_align().
| void init_presets | ( | dt_iop_module_so_t * | self | ) |
References compress_shadows_highlight_preset_set_exposure_params(), DEVELOP_BLEND_CS_RGB_SCENE, dilate_shadows_highlight_preset_set_exposure_params(), dt_gui_presets_add_generic(), DT_TONEEQ_EIGF, DT_TONEEQ_GUIDED, DT_TONEEQ_NONE, DT_TONEEQ_NORM_2, DT_TONEEQ_NORM_POWER, dt_iop_module_so_t::op, and p.
| void input_format | ( | dt_iop_module_t * | self, |
| dt_dev_pixelpipe_t * | pipe, | ||
| dt_dev_pixelpipe_iop_t * | piece, | ||
| dt_iop_buffer_dsc_t * | dsc | ||
| ) |
|
static |
References darktable, dt_dev_pixelpipe_cache_ref_count_entry(), dt_iop_gui_enter_critical_section(), dt_iop_gui_leave_critical_section(), DT_PIXELPIPE_CACHE_HASH_INVALID, FALSE, g, dt_iop_module_t::gui_data, and darktable_t::pixelpipe_cache.
Referenced by auto_adjust_contrast_boost(), auto_adjust_exposure_boost(), gui_changed(), and gui_update().
| int legacy_params | ( | dt_iop_module_t * | self, |
| const void *const | old_params, | ||
| const int | old_version, | ||
| void * | new_params, | ||
| const int | new_version | ||
| ) |
References d, dt_iop_module_t::default_params, and n.
|
static |
References get_shade_from_luminance().
Referenced by gui_post_expose().
| void modify_roi_in | ( | struct dt_iop_module_t * | self, |
| struct dt_dev_pixelpipe_iop_t * | piece, | ||
| const dt_iop_roi_t * | roi_out, | ||
| dt_iop_roi_t * | roi_in | ||
| ) |
| int mouse_leave | ( | struct dt_iop_module_t * | self | ) |
| int mouse_moved | ( | struct dt_iop_module_t * | self, |
| double | x, | ||
| double | y, | ||
| double | pressure, | ||
| int | which | ||
| ) |
References _switch_cursors(), darktable, dt_iop_module_t::dev, dt_dev_coordinates_image_norm_to_preview_abs(), dt_dev_coordinates_widget_to_image_norm(), dt_dev_pixelpipe_cache_rdlock_entry(), dt_dev_pixelpipe_cache_ref_count_entry(), dt_iop_gui_enter_critical_section(), dt_iop_gui_leave_critical_section(), dt_pixel_cache_entry_get_data(), FALSE, g, get_luminance_from_buffer(), dt_iop_module_t::gui_data, dt_develop_t::pipe, darktable_t::pixelpipe_cache, dt_develop_t::preview_height, dt_develop_t::preview_width, dt_dev_pixelpipe_t::processing, dt_develop_t::roi, sanity_check(), TRUE, and x.
| const char * name | ( | ) |
|
static |
References darktable, dt_iop_color_picker_reset(), dt_iop_request_focus(), darktable_t::gui, dt_gui_gtk_t::reset, and TRUE.
Referenced by gui_init().
|
inlinestatic |
References factors, fast_clamp(), gaussian_denom(), gaussian_func(), i, and PIXEL_CHAN.
Referenced by compute_channels_factors(), compute_lut_correction(), and gui_post_expose().
| int process | ( | struct dt_iop_module_t * | self, |
| const dt_dev_pixelpipe_t * | pipe, | ||
| const dt_dev_pixelpipe_iop_t * | piece, | ||
| const void *const restrict | ivoid, | ||
| void *const restrict | ovoid | ||
| ) |
References dt_dev_pixelpipe_iop_t::roi_in, dt_dev_pixelpipe_iop_t::roi_out, and toneeq_process().
|
static |
References darktable, dt_iop_module_t::dev, darktable_t::develop, dt_control_log(), dt_dev_add_history_item, dt_ioppr_get_iop_order(), dt_iop_module_t::enabled, FALSE, darktable_t::gui, dt_develop_t::gui_attached, dt_iop_module_t::iop_order, dt_develop_t::iop_order_list, dt_iop_module_t::off, dt_gui_gtk_t::reset, and TRUE.
Referenced by _switch_cursors(), gui_post_expose(), mouse_moved(), scrolled(), and toneeq_process().
| int scrolled | ( | struct dt_iop_module_t * | self, |
| double | x, | ||
| double | y, | ||
| int | up, | ||
| uint32_t | state | ||
| ) |
References darktable, dt_iop_module_t::dev, darktable_t::develop, dt_dev_add_history_item, dt_dev_pixelpipe_cache_rdlock_entry(), dt_dev_pixelpipe_cache_ref_count_entry(), dt_iop_gui_enter_critical_section(), dt_iop_gui_leave_critical_section(), dt_modifier_is(), dt_pixel_cache_entry_get_data(), dt_iop_module_t::enabled, FALSE, g, get_luminance_from_buffer(), darktable_t::gui, dt_iop_module_t::gui_data, dt_iop_module_t::off, p, dt_iop_module_t::params, dt_develop_t::pipe, darktable_t::pixelpipe_cache, dt_dev_pixelpipe_t::processing, dt_gui_gtk_t::reset, sanity_check(), set_new_params_interactive(), TRUE, and update_exposure_sliders().
|
inlinestatic |
References CHANNELS, commit_channels_gains(), compute_channels_factors(), compute_channels_gains(), DT_ALIGNED_ARRAY, dt_control_log(), dt_simd_memcpy(), factors, g, gaussian_denom(), gaussian_func(), get_channels_factors(), i, p, PIXEL_CHAN, and pseudo_solve().
Referenced by area_motion_notify(), and scrolled().
| void show_guiding_controls | ( | struct dt_iop_module_t * | self | ) |
References DT_TONEEQ_AVG_EIGF, DT_TONEEQ_AVG_GUIDED, DT_TONEEQ_EIGF, DT_TONEEQ_GUIDED, DT_TONEEQ_NONE, FALSE, g, dt_iop_module_t::gui_data, p, and TRUE.
Referenced by gui_changed(), and gui_update().
|
static |
References darktable, dt_iop_module_t::dev, DT_DEV_PIXELPIPE_DISPLAY_NONE, DT_DEV_PIXELPIPE_DISPLAY_PASSTHRU, dt_dev_pixelpipe_update_history_main, dt_iop_color_picker_reset(), dt_iop_request_focus(), dt_iop_set_cache_bypass(), g, darktable_t::gui, dt_iop_module_t::gui_data, dt_iop_module_t::off, dt_iop_module_t::request_mask_display, dt_gui_gtk_t::reset, and TRUE.
Referenced by gui_init().
References CHANNELS, darktable, darktable_t::develop, DT_ALIGNED_ARRAY, dt_bauhaus_slider_get(), dt_control_log(), dt_dev_add_history_item, dt_iop_color_picker_reset(), factors, g, get_channels_factors(), darktable_t::gui, dt_iop_module_t::gui_data, p, dt_iop_module_t::params, dt_gui_gtk_t::reset, TRUE, and update_curve_lut().
Referenced by gui_init().
|
static |
References apply_toneequalizer(), compute_luminance_mask(), d, darktable, dt_dev_pixelpipe_iop_t::data, dt_iop_module_t::dev, display_luminance_mask(), dt_check_sse_aligned(), dt_control_log(), dt_dev_pixelpipe_cache_get(), dt_dev_pixelpipe_cache_ref_count_entry(), dt_dev_pixelpipe_cache_remove(), dt_dev_pixelpipe_cache_wrlock_entry(), DT_DEV_PIXELPIPE_DISPLAY_PASSTHRU, DT_DEV_PIXELPIPE_FULL, dt_dev_pixelpipe_has_preview_output(), dt_hash(), dt_iop_gui_enter_critical_section(), dt_iop_gui_leave_critical_section(), dt_pixelpipe_cache_alloc_align_float, dt_pixelpipe_cache_free_align, DT_PIXELPIPE_CACHE_HASH_INVALID, dt_simd_memcpy(), FALSE, g, dt_dev_pixelpipe_iop_t::global_hash, dt_develop_t::gui_attached, dt_iop_module_t::gui_data, height, dt_iop_roi_t::height, dt_iop_module_t::iop_order, out, darktable_t::pixelpipe_cache, position(), sanity_check(), TRUE, dt_dev_pixelpipe_t::type, width, and dt_iop_roi_t::width.
Referenced by process().
|
inlinestatic |
References build_interpolation_matrix(), CHANNELS, compute_lut_correction(), DT_ALIGNED_ARRAY, dt_iop_gui_enter_critical_section(), dt_iop_gui_leave_critical_section(), dt_simd_memcpy(), factors, FALSE, g, get_channels_factors(), dt_iop_module_t::gui_data, p, dt_iop_module_t::params, PIXEL_CHAN, pseudo_solve(), and TRUE.
Referenced by area_draw(), commit_params(), and smoothing_callback().
| void update_exposure_sliders | ( | dt_iop_toneequalizer_gui_data_t * | g, |
| dt_iop_toneequalizer_params_t * | p | ||
| ) |
References darktable, dt_bauhaus_slider_set(), g, darktable_t::gui, p, and dt_gui_gtk_t::reset.
Referenced by area_button_press(), area_button_release(), area_leave_notify(), and scrolled().
|
inlinestatic |
References compute_log_histogram_and_stats(), darktable, dt_dev_pixelpipe_cache_rdlock_entry(), dt_dev_pixelpipe_cache_ref_count_entry(), dt_iop_gui_enter_critical_section(), dt_iop_gui_leave_critical_section(), dt_pixel_cache_entry_get_data(), DT_PIXELPIPE_CACHE_HASH_INVALID, FALSE, g, dt_iop_module_t::gui_data, height, darktable_t::pixelpipe_cache, TRUE, UI_SAMPLES, and width.
Referenced by area_draw(), auto_adjust_contrast_boost(), and auto_adjust_exposure_boost().
|
static |
Referenced by commit_params(), gui_post_expose(), set_new_params_interactive(), smoothing_callback(), and update_curve_lut().
|
static |
Referenced by get_luminance_from_buffer().