![]() |
Ansel 0.0
A darktable fork - bloat + design vision
|
#include <cairo.h>#include <glib.h>#include <inttypes.h>#include <stddef.h>#include <stdint.h>#include "common/debug.h"#include "common/darktable.h"#include "common/dtpthread.h"#include "common/image.h"#include "control/settings.h"#include "develop/imageop.h"#include "develop/dev_history.h"#include "develop/dev_pixelpipe.h"
Include dependency graph for develop.h:Go to the source code of this file.
Data Structures | |
| struct | dt_develop_t |
Macros | |
| #define | dt_dev_configure(dev, wd, ht) DT_DEBUG_TRACE_WRAPPER(DT_DEBUG_DEV, dt_dev_configure_real, (dev), (wd), (ht)) |
Typedefs | |
| typedef enum dt_dev_overexposed_colorscheme_t | dt_dev_overexposed_colorscheme_t |
| typedef enum dt_dev_overlay_colors_t | dt_dev_overlay_colors_t |
| typedef enum dt_dev_rawoverexposed_mode_t | dt_dev_rawoverexposed_mode_t |
| typedef enum dt_dev_rawoverexposed_colorscheme_t | dt_dev_rawoverexposed_colorscheme_t |
| typedef enum dt_dev_transform_direction_t | dt_dev_transform_direction_t |
| typedef enum dt_dev_roi_space_t | dt_dev_roi_space_t |
| typedef enum dt_dev_pixelpipe_display_mask_t | dt_dev_pixelpipe_display_mask_t |
| typedef enum dt_develop_detail_mask_t | dt_develop_detail_mask_t |
| typedef enum dt_clipping_preview_mode_t | dt_clipping_preview_mode_t |
| typedef struct dt_develop_t | dt_develop_t |
| typedef enum dt_dev_image_storage_t | dt_dev_image_storage_t |
Functions | |
| static uint64_t | dt_dev_get_history_hash (const dt_develop_t *dev) |
| static void | dt_dev_set_history_hash (dt_develop_t *dev, const uint64_t history_hash) |
| void | dt_dev_init (dt_develop_t *dev, int32_t gui_attached) |
| void | dt_dev_cleanup (dt_develop_t *dev) |
| GList * | dt_dev_load_modules (dt_develop_t *dev) |
| dt_dev_image_storage_t | dt_dev_ensure_image_storage (dt_develop_t *dev, const int32_t imgid) |
| void | dt_dev_start_all_pipelines (dt_develop_t *dev) |
| dt_dev_image_storage_t | dt_dev_load_image (dt_develop_t *dev, const int32_t imgid) |
| int | dt_dev_is_current_image (dt_develop_t *dev, int32_t imgid) |
| void | dt_dev_get_processed_size (const dt_develop_t *dev, int *procw, int *proch) |
| float | dt_dev_get_zoom_scale (const dt_develop_t *dev, gboolean preview) |
| void | dt_dev_set_backbuf (dt_backbuf_t *backbuf, const int width, const int height, const size_t bpp, const int64_t hash, const int64_t history_hash) |
| void | dt_dev_coordinates_widget_to_image_norm (dt_develop_t *dev, float *points, size_t num_points) |
| Coordinate conversion helpers between widget, normalized image, and absolute image spaces. | |
| void | dt_dev_coordinates_widget_delta_to_image_delta (dt_develop_t *dev, float *points, size_t num_points) |
| Convert a widget-space distance to processed-image pixels. | |
| void | dt_dev_coordinates_image_norm_to_widget (dt_develop_t *dev, float *points, size_t num_points) |
| void | dt_dev_coordinates_image_norm_to_image_abs (dt_develop_t *dev, float *points, size_t num_points) |
| void | dt_dev_coordinates_image_abs_to_image_norm (dt_develop_t *dev, float *points, size_t num_points) |
| void | dt_dev_coordinates_raw_abs_to_raw_norm (dt_develop_t *dev, float *points, size_t num_points) |
| void | dt_dev_coordinates_raw_norm_to_raw_abs (dt_develop_t *dev, float *points, size_t num_points) |
| void | dt_dev_coordinates_image_norm_to_raw_norm (dt_develop_t *dev, float *points, size_t num_points) |
| void | dt_dev_coordinates_raw_norm_to_image_norm (dt_develop_t *dev, float *points, size_t num_points) |
| void | dt_dev_coordinates_image_norm_to_preview_abs (dt_develop_t *dev, float *points, size_t num_points) |
| void | dt_dev_coordinates_preview_abs_to_image_norm (dt_develop_t *dev, float *points, size_t num_points) |
| void | dt_dev_coordinates_image_abs_to_raw_norm (dt_develop_t *dev, float *points, size_t num_points) |
| void | dt_dev_retrieve_full_pos (dt_develop_t *dev, const int px, const int py, float *mouse_x, float *mouse_y) |
| Get a point position from widget space to preview buffer space [0..1]. | |
| void | dt_dev_configure_real (dt_develop_t *dev, int wd, int ht) |
| void | dt_dev_check_zoom_pos_bounds (dt_develop_t *dev, float *dev_x, float *dev_y, float *box_w, float *box_h) |
| Ensure that the current ROI position is within allowed bounds . | |
| void | dt_dev_modulegroups_switch_tab (dt_develop_t *dev, struct dt_iop_module_t *module) |
| void | dt_dev_signal_modules_moved (dt_develop_t *dev) |
| void | dt_dev_snapshot_request (dt_develop_t *dev, const char *filename) |
| void | dt_dev_masks_list_change (dt_develop_t *dev) |
| void | dt_dev_masks_list_update (dt_develop_t *dev) |
| void | dt_dev_masks_list_remove (dt_develop_t *dev, int formid, int parentid) |
| void | dt_dev_masks_selection_change (dt_develop_t *dev, struct dt_iop_module_t *module, const int selectid, const int throw_event) |
| void | dt_dev_masks_update_hash (dt_develop_t *dev) |
| struct dt_iop_module_t * | dt_dev_module_duplicate (dt_develop_t *dev, struct dt_iop_module_t *base) |
| void | dt_dev_module_remove (dt_develop_t *dev, struct dt_iop_module_t *module) |
| void | dt_dev_modules_update_multishow (dt_develop_t *dev) |
| gchar * | dt_dev_get_multi_name (const struct dt_iop_module_t *module) |
| gchar * | dt_dev_get_masks_group_name (const struct dt_iop_module_t *module) |
| gchar * | dt_history_item_get_name (const struct dt_iop_module_t *module) |
| gchar * | dt_history_item_get_name_html (const struct dt_iop_module_t *module) |
| gchar * | dt_history_item_get_label (const struct dt_iop_module_t *module) |
| int | dt_dev_coordinates_raw_abs_to_image_abs (dt_develop_t *dev, float *points, size_t points_count) |
| int | dt_dev_coordinates_image_abs_to_raw_abs (dt_develop_t *dev, float *points, size_t points_count) |
| int | dt_dev_distort_transform_plus (const struct dt_dev_pixelpipe_t *pipe, const double iop_order, const int transf_direction, float *points, size_t points_count) |
| int | dt_dev_distort_transform_locked (const struct dt_dev_pixelpipe_t *pipe, const double iop_order, const int transf_direction, float *points, size_t points_count) |
| int | dt_dev_distort_backtransform_plus (const struct dt_dev_pixelpipe_t *pipe, const double iop_order, const int transf_direction, float *points, size_t points_count) |
| struct dt_dev_pixelpipe_iop_t * | dt_dev_distort_get_iop_pipe (struct dt_dev_pixelpipe_t *pipe, struct dt_iop_module_t *module) |
| void | dt_dev_undo_start_record (dt_develop_t *dev) |
| void | dt_dev_undo_end_record (dt_develop_t *dev) |
| gboolean | dt_masks_get_lock_mode (dt_develop_t *dev) |
| void | dt_masks_set_lock_mode (dt_develop_t *dev, gboolean mode) |
| guint | dt_dev_mask_history_overload (GList *dev_history, guint threshold) |
| void | dt_dev_append_changed_tag (const int32_t imgid) |
| float | dt_dev_get_natural_scale (dt_develop_t *dev) |
| int | dt_dev_get_thumbnail_size (dt_develop_t *dev) |
| gboolean | dt_dev_pixelpipe_has_preview_output (const dt_develop_t *dev, const struct dt_dev_pixelpipe_t *pipe, const struct dt_iop_roi_t *roi) |
| Tell whether a GUI-attached pipe currently targets the darkroom preview-sized output. | |
| gboolean | dt_dev_pipelines_share_preview_output (dt_develop_t *dev) |
| Tell whether the darkroom main and preview pipes currently target the same GUI output. | |
| float | dt_dev_get_overlay_scale (dt_develop_t *dev) |
| Get the overlay scale factor in GUI logical coordinates. | |
| float | dt_dev_get_widget_zoom_scale (const dt_develop_t *dev, float scaling) |
| Convert a darkroom scaling factor to GUI logical zoom. | |
| void | dt_dev_get_widget_center (const dt_develop_t *dev, float *point) |
| Get the center of the darkroom widget in logical coordinates. | |
| void | dt_dev_get_image_box_in_widget (const dt_develop_t *dev, int32_t width, int32_t height, float *box) |
| Get the displayed image rectangle in darkroom widget coordinates. | |
| float | dt_dev_get_fit_scale (dt_develop_t *dev) |
| Get the scale factor that maps preview-buffer pixels to GUI coordinates. | |
| float | dt_dev_get_zoom_level (const dt_develop_t *dev) |
| void | dt_dev_reset_roi (dt_develop_t *dev) |
| void | dt_dev_convert_roi (const dt_develop_t *dev, const dt_iop_roi_t *roi_in, dt_iop_roi_t *roi_out, const dt_dev_roi_space_t from, const dt_dev_roi_space_t to) |
| Convert a full ROI object between pipeline raster coordinates and GUI logical coordinates. | |
| gboolean | dt_dev_clip_roi (dt_develop_t *dev, cairo_t *cr, int32_t width, int32_t height) |
| Clip the view to the ROI. WARNING: this must be done before any translation. | |
| gboolean | dt_dev_rescale_roi (dt_develop_t *dev, cairo_t *cr, int32_t width, int32_t height) |
| Scale the ROI to fit within given width/height, centered. | |
| gboolean | dt_dev_rescale_roi_to_input (dt_develop_t *dev, cairo_t *cr, int32_t width, int32_t height) |
| Scale the ROI to fit the input size within given width/height, centered. | |
| gboolean | dt_dev_check_zoom_scale_bounds (dt_develop_t *dev) |
| Ensure that the current zoom level is within allowed bounds (for scrolling). | |
| void | dt_dev_update_mouse_effect_radius (dt_develop_t *dev) |
Convert absolute output-image coordinates to input image space by calling dt_dev_coordinates_image_abs_to_raw_abs() directly, then normalize with dt_dev_coordinates_raw_abs_to_raw_norm() when normalized raw coordinates are required. | |
| #define dt_dev_configure | ( | dev, | |
| wd, | |||
| ht | |||
| ) | DT_DEBUG_TRACE_WRAPPER(DT_DEBUG_DEV, dt_dev_configure_real, (dev), (wd), (ht)) |
| typedef enum dt_clipping_preview_mode_t dt_clipping_preview_mode_t |
| typedef enum dt_dev_image_storage_t dt_dev_image_storage_t |
| typedef enum dt_dev_overlay_colors_t dt_dev_overlay_colors_t |
| typedef enum dt_dev_rawoverexposed_mode_t dt_dev_rawoverexposed_mode_t |
| typedef enum dt_dev_roi_space_t dt_dev_roi_space_t |
| typedef enum dt_dev_transform_direction_t dt_dev_transform_direction_t |
| typedef enum dt_develop_detail_mask_t dt_develop_detail_mask_t |
| typedef struct dt_develop_t dt_develop_t |
| enum dt_dev_roi_space_t |
| void dt_dev_append_changed_tag | ( | const int32_t | imgid | ) |
Definition at line 1672 of file develop.c.
References darktable, DT_DEBUG_CONTROL_SIGNAL_RAISE, DT_SIGNAL_TAG_CHANGED, dt_tag_attach(), dt_tag_new(), FALSE, and darktable_t::signals.
Referenced by dt_dev_load_image().
| void dt_dev_check_zoom_pos_bounds | ( | dt_develop_t * | dev, |
| float * | dev_x, | ||
| float * | dev_y, | ||
| float * | box_w, | ||
| float * | box_h | ||
| ) |
Ensure that the current ROI position is within allowed bounds .
| dev | the develop instance |
| dev_x | the normalized x position of ROI |
| dev_y | the normalized y position of ROI |
| box_w | the width of navigation's box |
| box_h | the height of navigation's box |
Definition at line 944 of file develop.c.
References CLAMPF, dt_dev_get_processed_size(), dt_dev_get_zoom_level(), dt_develop_t::height, IS_NULL_PTR, dt_develop_t::roi, dt_develop_t::scaling, and dt_develop_t::width.
Referenced by _change_scaling(), _darkroom_edge_pan_apply(), _key_scroll(), _lib_navigation_draw_callback(), _lib_navigation_set_position(), _zoom_preset_change(), dt_masks_center_view_on_form(), and mouse_moved().
| gboolean dt_dev_check_zoom_scale_bounds | ( | dt_develop_t * | dev | ) |
Ensure that the current zoom level is within allowed bounds (for scrolling).
| dev | the develop instance |
Definition at line 1844 of file develop.c.
References FALSE, dt_develop_t::natural_scale, dt_develop_t::roi, dt_develop_t::scaling, and TRUE.
Referenced by _change_scaling().
| void dt_dev_cleanup | ( | dt_develop_t * | dev | ) |
Definition at line 188 of file develop.c.
References dt_develop_t::allforms, dt_develop_t::alliop, dt_develop_t::allprofile_info, dt_develop_t::blend_params, dt_develop_t::chroma_adaptation, dt_develop_t::color_picker, dt_develop_t::colorscheme, dt_conf_set_float(), dt_conf_set_int(), dt_dev_free_history_item(), dt_dev_pixelpipe_cleanup(), dt_free, dt_free_align, dt_free_gpointer(), dt_gui_throttle_cancel(), dt_iop_cleanup_module(), dt_ioppr_cleanup_profile_info(), dt_masks_free_form(), dt_pthread_mutex_destroy(), dt_pthread_mutex_lock(), dt_pthread_mutex_unlock(), dt_pthread_rwlock_destroy, dt_pthread_rwlock_unlock, dt_pthread_rwlock_wrlock, dt_develop_t::forms, dt_develop_t::histogram_pre_levels, dt_develop_t::histogram_pre_tonecurve, dt_develop_t::history, dt_develop_t::history_mutex, dt_develop_t::iop, dt_develop_t::iop_order_list, IS_NULL_PTR, dt_develop_t::lower, dt_develop_t::masks_mutex, dt_develop_t::mode, dt_develop_t::overexposed, dt_develop_t::params, dt_develop_t::pipe, dt_develop_t::preview_pipe, dt_develop_t::primary_sample, dt_develop_t::proxy, dt_develop_t::rawoverexposed, dt_develop_t::threshold, dt_develop_t::transient_params, dt_develop_t::transient_params_mutex, dt_develop_t::undo_history_before_end, dt_develop_t::undo_history_before_iop_order_list, dt_develop_t::undo_history_before_snapshot, dt_develop_t::undo_history_depth, dt_develop_t::upper, dt_develop_t::virtual_pipe, void(), and dt_develop_t::wb_coeffs.
Referenced by _history_compress_apply(), _history_copy_and_paste_on_image_merge(), _lib_snapshot_capture_state(), _lib_snapshot_clear_state(), cleanup(), dt_dev_merge_history_into_image(), dt_focus_draw_clusters(), dt_imageio_export_with_flags(), and dt_styles_apply_to_image_merge().
| gboolean dt_dev_clip_roi | ( | dt_develop_t * | dev, |
| cairo_t * | cr, | ||
| int32_t | width, | ||
| int32_t | height | ||
| ) |
Clip the view to the ROI. WARNING: this must be done before any translation.
| dev | the develop instance |
| cr | the cairo context to clip on |
| width | the view width |
| height | the view height |
Definition at line 1781 of file develop.c.
References dt_develop_t::border_size, dt_dev_get_overlay_scale(), FALSE, height, dt_develop_t::preview_height, dt_develop_t::preview_width, dt_develop_t::roi, TRUE, and width.
Referenced by expose(), and gui_post_expose().
| void dt_dev_configure_real | ( | dt_develop_t * | dev, |
| int | wd, | ||
| int | ht | ||
| ) |
Definition at line 922 of file develop.c.
References dt_control_queue_redraw(), DT_DEBUG_DEV, dt_dev_convert_roi(), dt_dev_get_thumbnail_size(), dt_dev_pixelpipe_update_zoom_main, dt_dev_pixelpipe_update_zoom_preview, DT_DEV_ROI_GUI_LOGICAL, DT_DEV_ROI_PIPELINE, dt_print(), dt_develop_t::gui_inited, dt_develop_t::height, dt_iop_roi_t::height, dt_develop_t::roi, TRUE, dt_develop_t::width, dt_iop_roi_t::width, and dt_iop_roi_t::x.
| void dt_dev_convert_roi | ( | const dt_develop_t * | dev, |
| const dt_iop_roi_t * | roi_in, | ||
| dt_iop_roi_t * | roi_out, | ||
| const dt_dev_roi_space_t | from, | ||
| const dt_dev_roi_space_t | to | ||
| ) |
Convert a full ROI object between pipeline raster coordinates and GUI logical coordinates.
The pipeline stores ROI geometry in real buffer pixels while Gtk events and drawing use logical coordinates. x/y/width/height cross that boundary through the ppd factor, while roi->scale remains the same because it expresses image-space sampling, not GUI density.
| dev | the develop instance carrying the ppd factor |
| roi_in | the source ROI |
| roi_out | the converted ROI |
| from | the source coordinate space |
| to | the destination coordinate space |
Definition at line 1759 of file develop.c.
References darktable, DT_DEV_ROI_GUI_LOGICAL, DT_DEV_ROI_PIPELINE, factor, darktable_t::gui, dt_iop_roi_t::height, IS_NULL_PTR, dt_gui_gtk_t::ppd, dt_iop_roi_t::scale, dt_iop_roi_t::width, dt_iop_roi_t::x, and dt_iop_roi_t::y.
Referenced by dt_dev_configure_real().
| void dt_dev_coordinates_image_abs_to_image_norm | ( | dt_develop_t * | dev, |
| float * | points, | ||
| size_t | num_points | ||
| ) |
Definition at line 1075 of file develop.c.
References i, IS_NULL_PTR, dt_develop_t::processed_height, dt_develop_t::processed_width, and dt_develop_t::roi.
Referenced by dt_dev_coordinates_raw_norm_to_image_norm(), dt_drawlayer_layer_points_to_widget_coords(), dt_masks_center_view_on_form(), get_grab(), mouse_moved(), and set_points_from_grad().
| int dt_dev_coordinates_image_abs_to_raw_abs | ( | dt_develop_t * | dev, |
| float * | points, | ||
| size_t | points_count | ||
| ) |
reverse apply all transforms to the specified points (in virtual preview-pipe space)
Definition at line 1530 of file develop.c.
References dt_dev_distort_backtransform_locked(), DT_DEV_TRANSFORM_DIR_ALL, and dt_develop_t::virtual_pipe.
Referenced by _dt_masks_events_set_current_pos(), dt_dev_coordinates_image_abs_to_raw_norm(), dt_dev_coordinates_image_norm_to_raw_norm(), dt_masks_border_from_projected_handle(), dt_masks_rotate_with_anchor(), and dt_masks_set_source_pos_initial_value().
| void dt_dev_coordinates_image_abs_to_raw_norm | ( | dt_develop_t * | dev, |
| float * | points, | ||
| size_t | num_points | ||
| ) |
Definition at line 1138 of file develop.c.
References dt_dev_coordinates_image_abs_to_raw_abs(), and dt_dev_coordinates_raw_abs_to_raw_norm().
Referenced by _brush_events_button_released(), _brush_events_mouse_moved(), _polygon_events_mouse_moved(), button_released(), dt_masks_gui_delta_to_raw_norm(), and dt_masks_set_source_pos_initial_value().
| void dt_dev_coordinates_image_norm_to_image_abs | ( | dt_develop_t * | dev, |
| float * | points, | ||
| size_t | num_points | ||
| ) |
Definition at line 1060 of file develop.c.
References i, IS_NULL_PTR, dt_develop_t::processed_height, dt_develop_t::processed_width, and dt_develop_t::roi.
Referenced by _dt_masks_events_set_current_pos(), _picker_sample_box(), dt_dev_coordinates_image_norm_to_raw_norm(), dt_drawlayer_widget_points_to_layer_coords(), get_point_scale(), and set_grad_from_points().
| void dt_dev_coordinates_image_norm_to_preview_abs | ( | dt_develop_t * | dev, |
| float * | points, | ||
| size_t | num_points | ||
| ) |
Definition at line 1144 of file develop.c.
References i, IS_NULL_PTR, dt_develop_t::preview_height, dt_develop_t::preview_width, and dt_develop_t::roi.
Referenced by _pixelpipe_pick_from_image(), button_pressed(), button_released(), dt_drawlayer_layer_points_to_widget_coords(), dt_drawlayer_widget_points_to_layer_coords(), get_grab(), gui_post_expose(), and mouse_moved().
| void dt_dev_coordinates_image_norm_to_raw_norm | ( | dt_develop_t * | dev, |
| float * | points, | ||
| size_t | num_points | ||
| ) |
Definition at line 1124 of file develop.c.
References dt_dev_coordinates_image_abs_to_raw_abs(), dt_dev_coordinates_image_norm_to_image_abs(), and dt_dev_coordinates_raw_abs_to_raw_norm().
Referenced by _picker_initialize_geometry_raw(), button_pressed(), dt_lib_colorpicker_set_box_area(), and dt_lib_colorpicker_set_point().
| void dt_dev_coordinates_image_norm_to_widget | ( | dt_develop_t * | dev, |
| float * | points, | ||
| size_t | num_points | ||
| ) |
Definition at line 1031 of file develop.c.
References darktable, dt_dev_get_zoom_level(), darktable_t::gui, i, IS_NULL_PTR, dt_develop_t::orig_height, dt_develop_t::orig_width, dt_gui_gtk_t::ppd, dt_develop_t::processed_height, dt_develop_t::processed_width, dt_develop_t::roi, dt_develop_t::x, and dt_develop_t::y.
Referenced by dt_drawlayer_layer_points_to_widget_coords().
| void dt_dev_coordinates_preview_abs_to_image_norm | ( | dt_develop_t * | dev, |
| float * | points, | ||
| size_t | num_points | ||
| ) |
Definition at line 1159 of file develop.c.
References i, IS_NULL_PTR, dt_develop_t::preview_height, dt_develop_t::preview_width, and dt_develop_t::roi.
Referenced by _iop_clipping_set_max_clip(), _polygon_get_sizes(), _refresh_preview_cursor_sample(), _set_max_clip(), dt_drawlayer_layer_points_to_widget_coords(), and dt_drawlayer_widget_points_to_layer_coords().
| int dt_dev_coordinates_raw_abs_to_image_abs | ( | dt_develop_t * | dev, |
| float * | points, | ||
| size_t | points_count | ||
| ) |
apply all transforms to the specified points (in virtual preview-pipe space)
Definition at line 1525 of file develop.c.
References dt_dev_distort_transform_plus(), DT_DEV_TRANSFORM_DIR_ALL, and dt_develop_t::virtual_pipe.
Referenced by _circle_get_points(), _ellipse_get_points(), _gradient_get_points(), dt_dev_coordinates_raw_norm_to_image_norm(), and dt_masks_center_view_on_form().
| void dt_dev_coordinates_raw_abs_to_raw_norm | ( | dt_develop_t * | dev, |
| float * | points, | ||
| size_t | num_points | ||
| ) |
Definition at line 1092 of file develop.c.
References i, IS_NULL_PTR, dt_develop_t::raw_height, dt_develop_t::raw_width, and dt_develop_t::roi.
Referenced by _gradient_get_pts_border(), dt_dev_coordinates_image_abs_to_raw_norm(), dt_dev_coordinates_image_norm_to_raw_norm(), dt_masks_gui_cursor_to_raw_norm(), and dt_masks_set_source_pos_initial_value().
| void dt_dev_coordinates_raw_norm_to_image_norm | ( | dt_develop_t * | dev, |
| float * | points, | ||
| size_t | num_points | ||
| ) |
Definition at line 1131 of file develop.c.
References dt_dev_coordinates_image_abs_to_image_norm(), dt_dev_coordinates_raw_abs_to_image_abs(), and dt_dev_coordinates_raw_norm_to_raw_abs().
Referenced by _darkroom_sample_raw_box_to_image_norm(), _darkroom_sample_raw_point_to_image_norm(), _picker_raw_box_to_image_norm(), _picker_raw_point_to_image_norm(), _sample_raw_box_to_image_norm(), _sample_raw_point_to_image_norm(), button_pressed(), and mouse_moved().
| void dt_dev_coordinates_raw_norm_to_raw_abs | ( | dt_develop_t * | dev, |
| float * | points, | ||
| size_t | num_points | ||
| ) |
Definition at line 1109 of file develop.c.
References i, IS_NULL_PTR, dt_develop_t::raw_height, dt_develop_t::raw_width, and dt_develop_t::roi.
Referenced by _brush_get_pts_border(), _brush_initial_source_pos(), _circle_get_points_source(), _circle_initial_source_pos(), _ellipse_get_points_source(), _ellipse_initial_source_pos(), _ellipse_points_to_transform(), _gradient_get_points(), _gradient_get_pts_border(), _points_to_transform(), _points_to_transform(), _polygon_initial_source_pos(), dt_dev_coordinates_raw_norm_to_image_norm(), dt_masks_border_from_projected_handle(), and dt_masks_center_view_on_form().
| void dt_dev_coordinates_widget_delta_to_image_delta | ( | dt_develop_t * | dev, |
| float * | points, | ||
| size_t | num_points | ||
| ) |
Convert a widget-space distance to processed-image pixels.
Mouse drags and GUI handle sizes are expressed in darkroom logical pixels. Interactive modules compare them against image data, so this helper applies the current widget zoom once in the develop API instead of duplicating the same division in every callback.
| dev | the develop instance |
| points | pointer to num_points delta pairs stored as {dx, dy}; data is modified in place. |
| num_points | number of delta pairs referenced by points. |
Definition at line 986 of file develop.c.
References darktable, dt_dev_get_zoom_level(), darktable_t::gui, i, IS_NULL_PTR, and dt_gui_gtk_t::ppd.
Referenced by _darkroom_edge_pan_apply(), button_pressed(), key_pressed(), and mouse_moved().
| void dt_dev_coordinates_widget_to_image_norm | ( | dt_develop_t * | dev, |
| float * | points, | ||
| size_t | num_points | ||
| ) |
Coordinate conversion helpers between widget, normalized image, and absolute image spaces.
Widget space is assumed to be the darkroom center view and doesn't account for borders, zooming, panning, etc. RAW space is the full-resolution input fed to the pipeline. Image space is the output image resulting from applying a full history over the full-resolution input. Preview space is the downscaled output image preview as displayed in darkroom.
| dev | develop instance |
| points | pointer to num_points coordinate pairs stored as {x, y}; data is modified in place. |
| num_points | number of coordinate pairs referenced by points. |
Definition at line 1003 of file develop.c.
References darktable, dt_dev_get_zoom_level(), darktable_t::gui, i, IS_NULL_PTR, dt_develop_t::orig_height, dt_develop_t::orig_width, dt_gui_gtk_t::ppd, dt_develop_t::processed_height, dt_develop_t::processed_width, dt_develop_t::roi, dt_develop_t::x, and dt_develop_t::y.
Referenced by _dt_masks_events_set_current_pos(), button_pressed(), button_pressed(), button_released(), dt_drawlayer_widget_points_to_layer_coords(), get_point_scale(), gui_post_expose(), mouse_moved(), mouse_moved(), and scrolled().
| int dt_dev_distort_backtransform_plus | ( | const struct dt_dev_pixelpipe_t * | pipe, |
| const double | iop_order, | ||
| const int | transf_direction, | ||
| float * | points, | ||
| size_t | points_count | ||
| ) |
same fct as dt_dev_coordinates_image_abs_to_raw_abs, but we can specify iop with priority between pmin and pmax.
| struct dt_dev_pixelpipe_iop_t * dt_dev_distort_get_iop_pipe | ( | struct dt_dev_pixelpipe_t * | pipe, |
| struct dt_iop_module_t * | module | ||
| ) |
get the iop_pixelpipe instance corresponding to the iop in the given pipe
Definition at line 1593 of file develop.c.
References dt_dev_pixelpipe_t::nodes.
Referenced by _aspect_ratio_get(), _build_pre_module_filter_string(), _commit_box(), _create_background_layer_from_input(), _current_preview_hash(), _current_preview_luminance_hash(), _do_get_structure_lines(), _do_get_structure_quad(), _draw_retrieve_lines_from_params(), _iop_clipping_set_max_clip(), _ratio_get_aspect(), _set_max_clip(), button_pressed(), call_distort_transform(), commit_box(), do_crop(), gui_focus(), gui_post_expose(), mouse_moved(), set_grad_from_points(), and set_points_from_grad().
| int dt_dev_distort_transform_locked | ( | const struct dt_dev_pixelpipe_t * | pipe, |
| const double | iop_order, | ||
| const int | transf_direction, | ||
| float * | points, | ||
| size_t | points_count | ||
| ) |
same fct, but can only be called from a distort_transform function called by dt_dev_distort_transform_plus
| int dt_dev_distort_transform_plus | ( | const struct dt_dev_pixelpipe_t * | pipe, |
| const double | iop_order, | ||
| const int | transf_direction, | ||
| float * | points, | ||
| size_t | points_count | ||
| ) |
reverse apply all transforms to the specified points (in virtual preview-pipe space), but we can specify iop with priority between pmin and pmax. in/out as dt_dev_coordinates_raw_abs_to_image_abs
| dt_dev_image_storage_t dt_dev_ensure_image_storage | ( | dt_develop_t * | dev, |
| const int32_t | imgid | ||
| ) |
Definition at line 847 of file develop.c.
References _dt_dev_mipmap_prefetch_full(), _dt_dev_refresh_image_storage(), darktable, DT_DEV_IMAGE_STORAGE_DB_NOT_READ, DT_DEV_IMAGE_STORAGE_MIPMAP_NOT_FOUND, DT_DEV_IMAGE_STORAGE_OK, darktable_t::image_cache, and IS_NULL_PTR.
Referenced by _dt_dev_load_raw(), _styles_init_source_dev(), dt_dev_pop_history_items_ext(), dt_dev_read_history_ext(), and dt_dev_replace_history_on_image().
| float dt_dev_get_fit_scale | ( | dt_develop_t * | dev | ) |
Get the scale factor that maps preview-buffer pixels to GUI coordinates.
The pipeline ROI is stored in raster pixels. GUI drawing still happens in Gtk logical coordinates, so this helper exposes the explicit raster-to-GUI conversion used by overlays.
| dev | the develop instance |
Definition at line 1706 of file develop.c.
References darktable, darktable_t::gui, IS_NULL_PTR, dt_gui_gtk_t::ppd, dt_develop_t::roi, and dt_develop_t::scaling.
Referenced by _darkroom_pickers_draw(), button_pressed(), dt_dev_get_overlay_scale(), and dt_dev_rescale_roi().
|
inlinestatic |
Definition at line 504 of file develop.h.
References dt_atomic_get_uint64(), and dt_develop_t::history_hash.
Referenced by _resync_pipe_with_history(), dt_dev_add_history_item_real(), dt_dev_get_thumbnail_size(), dt_dev_pixelpipe_change(), dt_dev_pixelpipe_is_backbufer_valid(), dt_dev_pixelpipe_is_pipeline_valid(), dt_dev_write_history_ext(), gui_post_expose(), and gui_post_expose().
| void dt_dev_get_image_box_in_widget | ( | const dt_develop_t * | dev, |
| int32_t | width, | ||
| int32_t | height, | ||
| float * | box | ||
| ) |
Get the displayed image rectangle in darkroom widget coordinates.
Input callbacks often need to know whether the pointer is inside the image or in the margin area. This exposes the current displayed backbuffer footprint in logical coordinates, including the ppd conversion.
| dev | the develop instance |
| width | the current darkroom widget width |
| height | the current darkroom widget height |
| box | returned image box stored as {x, y, width, height} |
Definition at line 1730 of file develop.c.
References dt_develop_t::border_size, darktable, darktable_t::gui, height, IS_NULL_PTR, dt_gui_gtk_t::ppd, dt_develop_t::preview_height, dt_develop_t::preview_width, dt_develop_t::roi, dt_develop_t::scaling, and width.
Referenced by _build_preview_fallback_surface(), _darkroom_edge_pan_update_state(), gui_post_expose(), and mouse_in_imagearea().
| gchar * dt_dev_get_masks_group_name | ( | const struct dt_iop_module_t * | module | ) |
Get the module multi name, or the module name if no multi name is provided
Definition at line 1479 of file develop.c.
References dt_dev_get_multi_name(), dt_free, and dt_history_item_get_name().
Referenced by _blendop_masks_group_name_commit(), _set_group_name_from_module(), and dt_iop_gui_init_masks().
| gchar * dt_dev_get_multi_name | ( | const struct dt_iop_module_t * | module | ) |
generates item multi-instance name without mnemonics
Definition at line 1471 of file develop.c.
References dt_iop_module_t::multi_name.
Referenced by _ioporder_create_graph_node(), and dt_dev_get_masks_group_name().
| float dt_dev_get_natural_scale | ( | dt_develop_t * | dev | ) |
Definition at line 1697 of file develop.c.
References dt_develop_t::gui_inited, dt_develop_t::height, dt_develop_t::processed_height, dt_develop_t::processed_width, dt_develop_t::raw_inited, dt_develop_t::roi, and dt_develop_t::width.
Referenced by dt_dev_get_thumbnail_size(), and gui_post_expose().
| float dt_dev_get_overlay_scale | ( | dt_develop_t * | dev | ) |
Get the overlay scale factor in GUI logical coordinates.
This is the GUI-space scale used to draw preview overlays from the raster backbuffer dimensions stored in the pipeline ROI.
| dev | the develop instance |
Definition at line 1712 of file develop.c.
References dt_dev_get_fit_scale().
Referenced by _draw_near_point(), button_pressed(), dt_dev_clip_roi(), dt_drawlayer_compute_view_patch(), expose(), gui_post_expose(), gui_post_expose(), and mouse_moved().
| void dt_dev_get_processed_size | ( | const dt_develop_t * | dev, |
| int * | procw, | ||
| int * | proch | ||
| ) |
Definition at line 979 of file develop.c.
References IS_NULL_PTR, dt_develop_t::processed_height, dt_develop_t::processed_width, and dt_develop_t::roi.
Referenced by _aspect_apply(), _aspect_ratio_get(), _change_scaling(), _dev_translate_roi(), _lib_navigation_set_position(), _ratio_get_aspect(), apply_box_aspect(), dt_dev_check_zoom_pos_bounds(), dt_masks_events_post_expose(), and gui_post_expose().
| int dt_dev_get_thumbnail_size | ( | dt_develop_t * | dev | ) |
Definition at line 309 of file develop.c.
References dt_dev_pixelpipe_t::dev, DT_DEBUG_DEV, dt_dev_get_history_hash(), dt_dev_get_natural_scale(), DT_DEV_PIPE_REMOVE, DT_DEV_PIPE_SYNCH, DT_DEV_PIPE_UNCHANGED, dt_dev_pixelpipe_change(), dt_dev_pixelpipe_get_changed(), dt_dev_pixelpipe_get_history_hash(), dt_dev_pixelpipe_get_realtime(), dt_dev_pixelpipe_get_roi_out(), dt_dev_pixelpipe_or_changed(), dt_dev_pixelpipe_set_history_hash(), dt_dev_pixelpipe_set_input(), dt_dev_update_mouse_effect_radius(), DT_MIPMAP_FULL, dt_print(), dt_develop_t::gui_inited, dt_image_t::id, dt_dev_pixelpipe_t::iheight, dt_develop_t::image_storage, dt_dev_pixelpipe_t::imgid, dt_dev_pixelpipe_t::iwidth, dt_develop_t::natural_scale, dt_dev_pixelpipe_t::nodes, dt_develop_t::output_inited, dt_develop_t::pipe, dt_develop_t::preview_height, dt_develop_t::preview_width, dt_develop_t::processed_height, dt_develop_t::processed_width, dt_develop_t::raw_height, dt_develop_t::raw_inited, dt_develop_t::raw_width, dt_develop_t::roi, TRUE, and dt_develop_t::virtual_pipe.
Referenced by _darkroom_image_loaded_callback(), _dt_dev_history_compress_internal(), _enter_edit_mode(), _enter_edit_mode(), _event_commit_clicked(), _event_commit_clicked(), _event_process_after_ui_callback(), _history_apply_history_end(), do_crop(), dt_dev_add_history_item_real(), dt_dev_configure_real(), dt_dev_history_truncate(), dt_dev_pop_history_items(), and gui_focus().
| void dt_dev_get_widget_center | ( | const dt_develop_t * | dev, |
| float * | point | ||
| ) |
Get the center of the darkroom widget in logical coordinates.
| dev | the develop instance |
| point | returned widget center stored as {x, y} |
Definition at line 1723 of file develop.c.
References IS_NULL_PTR, dt_develop_t::orig_height, dt_develop_t::orig_width, and dt_develop_t::roi.
Referenced by _change_scaling(), and key_pressed().
| float dt_dev_get_widget_zoom_scale | ( | const dt_develop_t * | dev, |
| float | scaling | ||
| ) |
Convert a darkroom scaling factor to GUI logical zoom.
Pipeline zoom is tracked in raster-space units. Gtk callbacks and overlay drawing operate in logical widget coordinates, so the ppd correction belongs here rather than at every interactive call site.
| dev | the develop instance |
| scaling | the darkroom scaling factor to evaluate |
Definition at line 1717 of file develop.c.
References darktable, darktable_t::gui, IS_NULL_PTR, dt_develop_t::natural_scale, dt_gui_gtk_t::ppd, dt_develop_t::roi, and scaling.
Referenced by _change_scaling().
| float dt_dev_get_zoom_level | ( | const dt_develop_t * | dev | ) |
Definition at line 1745 of file develop.c.
References IS_NULL_PTR, dt_develop_t::natural_scale, dt_develop_t::roi, and dt_develop_t::scaling.
Referenced by _dev_translate_roi(), _lib_snapshots_refresh_pipe_image(), dt_dev_check_zoom_pos_bounds(), dt_dev_coordinates_image_norm_to_widget(), dt_dev_coordinates_widget_delta_to_image_delta(), dt_dev_coordinates_widget_to_image_norm(), dt_dev_rescale_roi_to_input(), dt_dev_update_mouse_effect_radius(), dt_masks_events_post_expose(), and gui_post_expose().
| float dt_dev_get_zoom_scale | ( | const dt_develop_t * | dev, |
| gboolean | preview | ||
| ) |
Definition at line 880 of file develop.c.
References dt_develop_t::height, dt_develop_t::pipe, dt_develop_t::processed_height, dt_dev_pixelpipe_t::processed_height, dt_develop_t::processed_width, dt_dev_pixelpipe_t::processed_width, dt_develop_t::roi, and dt_develop_t::width.
Referenced by button_pressed(), and get_zoom_scale().
| void dt_dev_init | ( | dt_develop_t * | dev, |
| int32_t | gui_attached | ||
| ) |
Definition at line 128 of file develop.c.
References dt_develop_t::color_picker, dt_develop_t::colorscheme, dt_develop_t::display_histogram, dt_develop_t::display_samples, dt_conf_get_bool(), dt_conf_get_float(), dt_conf_get_int(), dt_dev_load_modules(), dt_dev_pixelpipe_init(), dt_dev_pixelpipe_init_preview(), dt_dev_reset_roi(), dt_dev_set_backbuf(), dt_dev_set_history_hash(), dt_image_init(), DT_PIXELPIPE_CACHE_HASH_INVALID, dt_pthread_mutex_init(), dt_pthread_rwlock_init, dt_develop_t::gui_attached, dt_develop_t::height, dt_develop_t::histogram_pre_levels, dt_develop_t::histogram_pre_levels_max, dt_develop_t::histogram_pre_tonecurve, dt_develop_t::histogram_pre_tonecurve_max, dt_develop_t::history_mutex, dt_develop_t::image_storage, dt_develop_t::iop, dt_develop_t::live_samples_enabled, dt_develop_t::lower, dt_develop_t::masks_mutex, dt_develop_t::mode, dt_develop_t::output_histogram, dt_develop_t::overexposed, dt_develop_t::pipe, dt_develop_t::preview_pipe, dt_develop_t::primary_sample, dt_develop_t::proxy, dt_develop_t::raw_histogram, dt_develop_t::rawoverexposed, dt_develop_t::restrict_histogram, dt_develop_t::roi, dt_develop_t::threshold, dt_develop_t::transient_params_mutex, TRUE, dt_develop_t::upper, dt_develop_t::virtual_pipe, dt_develop_t::wb_coeffs, dt_develop_t::wb_is_D65, and dt_develop_t::width.
Referenced by _history_compress_apply(), _history_copy_and_paste_on_image_merge(), _lib_snapshot_capture_state(), _styles_init_source_dev(), dt_dev_merge_history_into_image(), dt_focus_draw_clusters(), dt_imageio_export_with_flags(), and init().
| int dt_dev_is_current_image | ( | dt_develop_t * | dev, |
| int32_t | imgid | ||
| ) |
checks if provided imgid is the image currently in develop
Definition at line 1176 of file develop.c.
References dt_image_t::id, and dt_develop_t::image_storage.
| dt_dev_image_storage_t dt_dev_load_image | ( | dt_develop_t * | dev, |
| const int32_t | imgid | ||
| ) |
Definition at line 887 of file develop.c.
References _dt_dev_load_raw(), darktable, darktable_t::develop, dt_dev_append_changed_tag(), dt_dev_history_notify_change(), dt_dev_read_history_ext(), dt_dev_write_history_ext(), dt_image_cache_get(), DT_IMAGE_CACHE_SAFE, dt_image_cache_write_release(), dt_pthread_rwlock_unlock, dt_pthread_rwlock_wrlock, dt_develop_t::history_mutex, darktable_t::image_cache, dt_develop_t::image_storage, and IS_NULL_PTR.
Referenced by _lib_snapshot_capture_state(), dt_focus_draw_clusters(), dt_imageio_export_with_flags(), and enter().
| GList * dt_dev_load_modules | ( | dt_develop_t * | dev | ) |
Definition at line 98 of file develop.c.
References darktable, dt_free, dt_iop_load_module_by_so(), dt_sort_iop_by_order(), and darktable_t::iop.
Referenced by dt_dev_init(), dt_dev_read_history_ext(), and enter().
| guint dt_dev_mask_history_overload | ( | GList * | dev_history, |
| guint | threshold | ||
| ) |
Definition at line 1214 of file dev_history.c.
References dt_dev_history_item_t::forms, and threshold.
Referenced by dt_dev_history_notify_change().
| void dt_dev_masks_list_change | ( | dt_develop_t * | dev | ) |
Definition at line 1187 of file develop.c.
References dt_develop_t::list_change, dt_develop_t::masks, and dt_develop_t::proxy.
Referenced by dt_dev_read_history_ext().
| void dt_dev_masks_list_remove | ( | dt_develop_t * | dev, |
| int | formid, | ||
| int | parentid | ||
| ) |
Definition at line 1197 of file develop.c.
References dt_develop_t::list_remove, dt_develop_t::masks, and dt_develop_t::proxy.
| void dt_dev_masks_list_update | ( | dt_develop_t * | dev | ) |
Definition at line 1192 of file develop.c.
References dt_develop_t::list_update, dt_develop_t::masks, and dt_develop_t::proxy.
Referenced by dt_dev_add_history_item_real().
| void dt_dev_masks_selection_change | ( | dt_develop_t * | dev, |
| struct dt_iop_module_t * | module, | ||
| const int | selectid, | ||
| const int | throw_event | ||
| ) |
Definition at line 1202 of file develop.c.
References dt_develop_t::masks, dt_develop_t::proxy, and dt_develop_t::selection_change.
Referenced by _blendop_masks_all_selection_changed(), _blendop_masks_group_selection_changed(), _tree_add_exist(), _tree_duplicate_shape(), dt_masks_events_button_released(), dt_masks_form_exit_creation(), dt_masks_remove_or_delete(), and dt_masks_set_edit_mode().
| void dt_dev_masks_update_hash | ( | dt_develop_t * | dev | ) |
integrity hash of the forms/shapes stack
Definition at line 1681 of file develop.c.
References dt_masks_group_get_hash(), dt_develop_t::forms, dt_develop_t::forms_changed, and dt_develop_t::forms_hash.
Referenced by _delayed_history_commit(), and dt_dev_read_history_ext().
| struct dt_iop_module_t * dt_dev_module_duplicate | ( | dt_develop_t * | dev, |
| dt_iop_module_t * | base | ||
| ) |
duplicate a existent module
Definition at line 1217 of file develop.c.
References dt_iop_module_t::dev, dt_iop_load_module(), dt_iop_update_multi_priority(), dt_ioppr_insert_module_instance(), dt_ioppr_move_iop_after(), dt_sort_iop_by_order(), FALSE, dt_iop_module_t::instance, dt_develop_t::iop, dt_iop_module_t::multi_name, dt_iop_module_t::multi_priority, dt_iop_module_t::so, and TRUE.
| void dt_dev_module_remove | ( | dt_develop_t * | dev, |
| struct dt_iop_module_t * | module | ||
| ) |
remove an existent module
Definition at line 1289 of file develop.c.
References DT_DEBUG_HISTORY, dt_dev_free_history_item(), dt_dev_get_history_end_ext(), dt_dev_history_undo_end_record_locked(), dt_dev_history_undo_invalidate_module(), dt_dev_history_undo_start_record_locked(), dt_dev_set_history_end_ext(), dt_print(), dt_pthread_rwlock_unlock, dt_pthread_rwlock_wrlock, dt_develop_t::gui_attached, dt_develop_t::history, dt_develop_t::history_mutex, dt_develop_t::iop, IS_NULL_PTR, MAX, dt_dev_history_item_t::multi_name, and dt_dev_history_item_t::op_name.
Referenced by _gui_delete_callback().
| void dt_dev_modulegroups_switch_tab | ( | dt_develop_t * | dev, |
| struct dt_iop_module_t * | module | ||
| ) |
request modulegroups to show the group of the given module
Definition at line 1181 of file develop.c.
References darktable, DT_DEBUG_CONTROL_SIGNAL_RAISE, DT_SIGNAL_DEVELOP_MODULEGROUPS_SET, IS_NULL_PTR, and darktable_t::signals.
Referenced by dt_iop_request_focus().
| void dt_dev_modules_update_multishow | ( | dt_develop_t * | dev | ) |
same, but for all modules
Definition at line 1390 of file develop.c.
References _dev_module_update_multishow(), dt_dev_get_history_end_ext(), dt_iop_gui_module_is_visible(), dt_ioppr_check_iop_order(), dt_develop_t::history, dt_iop_module_t::instance, dt_dev_multishow_state_t::instance_counts, dt_develop_t::iop, key, and state.
Referenced by _update_iop_visibility().
| gboolean dt_dev_pipelines_share_preview_output | ( | dt_develop_t * | dev | ) |
Tell whether the darkroom main and preview pipes currently target the same GUI output.
When both pipes would render the same geometry, preview must run first so the main pipe can reuse its backbuffer instead of recomputing the same image concurrently.
Definition at line 457 of file develop.c.
References _update_darkroom_roi(), FALSE, dt_develop_t::gui_attached, IS_NULL_PTR, dt_develop_t::output_inited, dt_develop_t::pipe, dt_develop_t::preview_pipe, and dt_develop_t::roi.
Referenced by expose().
| gboolean dt_dev_pixelpipe_has_preview_output | ( | const dt_develop_t * | dev, |
| const struct dt_dev_pixelpipe_t * | pipe, | ||
| const struct dt_iop_roi_t * | roi | ||
| ) |
Tell whether a GUI-attached pipe currently targets the darkroom preview-sized output.
GUI modules must no longer assume that dev->preview_pipe is the only pipe producing the full-image downsampled preview. When the main pipe renders the same geometry, it must follow the same heuristics.
Pass roi when the caller already knows the current output ROI for this processing run. Pass NULL to fall back to the pipe backbuffer size from the last completed run.
| gboolean dt_dev_rescale_roi | ( | dt_develop_t * | dev, |
| cairo_t * | cr, | ||
| int32_t | width, | ||
| int32_t | height | ||
| ) |
Scale the ROI to fit within given width/height, centered.
| dev | the develop instance |
| cr | the cairo context to draw on |
| width | the widget width |
| height | the widget height |
Definition at line 1824 of file develop.c.
References _dev_translate_roi(), dt_dev_get_fit_scale(), FALSE, height, TRUE, and width.
Referenced by _darkroom_pickers_draw(), expose(), and gui_post_expose().
| gboolean dt_dev_rescale_roi_to_input | ( | dt_develop_t * | dev, |
| cairo_t * | cr, | ||
| int32_t | width, | ||
| int32_t | height | ||
| ) |
Scale the ROI to fit the input size within given width/height, centered.
| dev | the develop instance |
| cr | the cairo context to draw on |
| width | the widget width |
| height | the widget height |
Definition at line 1834 of file develop.c.
References _dev_translate_roi(), darktable, dt_dev_get_zoom_level(), FALSE, darktable_t::gui, height, dt_gui_gtk_t::ppd, TRUE, and width.
Referenced by dt_masks_events_post_expose(), and gui_post_expose().
| void dt_dev_reset_roi | ( | dt_develop_t * | dev | ) |
Definition at line 1751 of file develop.c.
References dt_develop_t::natural_scale, dt_develop_t::roi, dt_develop_t::scaling, dt_develop_t::x, and dt_develop_t::y.
Referenced by dt_dev_init(), and reset().
| void dt_dev_retrieve_full_pos | ( | dt_develop_t * | dev, |
| const int | px, | ||
| const int | py, | ||
| float * | mouse_x, | ||
| float * | mouse_y | ||
| ) |
Get a point position from widget space to preview buffer space [0..1].
NOTE: The input point coordinates are without border subtraction.
| dev | the develop instance |
| px | the x point coordinate in widget space, with no border subtraction. |
| py | the y point coordinate in widget space, with no border subtraction. |
| mouse_x | the returned x point coordinate relative to processed image [0..1]. |
| mouse_y | the returned y point coordinate relative to processed image [0..1]. |
| void dt_dev_set_backbuf | ( | dt_backbuf_t * | backbuf, |
| const int | width, | ||
| const int | height, | ||
| const size_t | bpp, | ||
| const int64_t | hash, | ||
| const int64_t | history_hash | ||
| ) |
Definition at line 1886 of file develop.c.
References dt_backbuf_t::bpp, bpp, dt_dev_backbuf_set_hash(), dt_dev_backbuf_set_history_hash(), height, dt_backbuf_t::height, width, and dt_backbuf_t::width.
Referenced by _clear_histogram_backbuf(), _refresh_global_histogram_backbuf_for_hash(), _update_backbuf_cache_reference(), dt_dev_init(), dt_dev_pixelpipe_cleanup(), dt_dev_pixelpipe_init_cached(), and leave().
|
inlinestatic |
Definition at line 509 of file develop.h.
References dt_atomic_set_uint64(), and dt_develop_t::history_hash.
Referenced by _lib_snapshot_capture_state(), dt_dev_add_history_item_real(), dt_dev_init(), dt_dev_pop_history_items_ext(), dt_dev_set_history_end_ext(), dt_dev_write_history_ext(), dt_drawlayer_commit_dabs(), and gui_focus().
| void dt_dev_signal_modules_moved | ( | dt_develop_t * | dev | ) |
reorder the module list
Definition at line 1608 of file develop.c.
References darktable, DT_DEBUG_CONTROL_SIGNAL_RAISE, DT_SIGNAL_DEVELOP_MODULE_MOVED, IS_NULL_PTR, and darktable_t::signals.
Referenced by dt_dev_history_refresh_nodes_ext(), and dt_iop_gui_commit_iop_order_change().
| void dt_dev_snapshot_request | ( | dt_develop_t * | dev, |
| const char * | filename | ||
| ) |
request snapshot
Definition at line 1209 of file develop.c.
References dt_control_queue_redraw_center(), dt_develop_t::filename, dt_develop_t::proxy, dt_develop_t::request, dt_develop_t::snapshot, and TRUE.
| void dt_dev_start_all_pipelines | ( | dt_develop_t * | dev | ) |
Definition at line 811 of file develop.c.
References darktable_t::control, darktable, dt_control_add_job_res(), DT_CTL_WORKER_DARKROOM, dt_dev_process_job_create(), dt_develop_t::pipelines_started, and TRUE.
Referenced by _darkroom_image_loaded_callback().
| void dt_dev_undo_end_record | ( | dt_develop_t * | dev | ) |
Definition at line 1625 of file develop.c.
References darktable, DT_DEBUG_CONTROL_SIGNAL_RAISE, dt_dev_history_undo_end_record(), DT_SIGNAL_DEVELOP_HISTORY_CHANGE, DT_VIEW_DARKROOM, dt_view_manager_get_current_view(), dt_develop_t::gui_attached, darktable_t::signals, and darktable_t::view_manager.
Referenced by _darkroom_image_loaded_callback(), _gui_delete_callback(), _history_apply_history_end(), _styles_apply_callback(), compress_history_callback(), delete_history_callback(), dt_dev_add_history_item_real(), dt_drawlayer_commit_dabs(), gui_focus(), and gui_reset().
| void dt_dev_undo_start_record | ( | dt_develop_t * | dev | ) |
Definition at line 1614 of file develop.c.
References darktable, dt_dev_history_undo_start_record(), DT_VIEW_DARKROOM, dt_view_manager_get_current_view(), dt_develop_t::gui_attached, and darktable_t::view_manager.
Referenced by _darkroom_image_loaded_callback(), _gui_delete_callback(), _history_apply_history_end(), _styles_apply_callback(), compress_history_callback(), delete_history_callback(), dt_dev_add_history_item_real(), dt_drawlayer_commit_dabs(), gui_focus(), and gui_reset().
| void dt_dev_update_mouse_effect_radius | ( | dt_develop_t * | dev | ) |
Convert absolute output-image coordinates to input image space by calling dt_dev_coordinates_image_abs_to_raw_abs() directly, then normalize with dt_dev_coordinates_raw_abs_to_raw_norm() when normalized raw coordinates are required.
Definition at line 1869 of file develop.c.
References darktable, DT_DEBUG_MASKS, dt_dev_get_zoom_level(), DT_PIXEL_APPLY_DPI, dt_print(), dt_gui_gtk_t::effect_radius, dt_gui_gtk_t::effect_radius_clamped, darktable_t::gui, dt_gui_gtk_t::mouse, and dt_gui_gtk_t::ppd.
Referenced by dt_dev_get_thumbnail_size(), and dt_dev_pixelpipe_change_zoom_main().
| gchar * dt_history_item_get_label | ( | const struct dt_iop_module_t * | module | ) |
generate item multi-instance name with mnemonics, for Gtk labels
Definition at line 1458 of file develop.c.
References dt_iop_module_t::multi_name.
Referenced by _iop_panel_label().
| gchar * dt_history_item_get_name | ( | const struct dt_iop_module_t * | module | ) |
Definition at line 1493 of file develop.c.
References delete_underscore(), dt_capitalize_label(), dt_free, and dt_iop_module_t::multi_name.
Referenced by _blendop_masks_group_create(), _darkroom_autoset_label(), _gui_off_callback(), _lib_masks_blending_gui_changed_callback(), _lib_snapshots_add_button_clicked_callback(), _mask_indicator_tooltip(), _print_nan_debug(), _print_perf_debug(), _tree_format_form_usage_label(), dt_dev_get_masks_group_name(), dt_dev_pixelpipe_process_rec(), dt_iop_gui_init_blendif(), dt_iop_gui_init_masks(), dt_iop_set_mask_mode(), and dt_masks_iop_combo_populate().
| gchar * dt_history_item_get_name_html | ( | const struct dt_iop_module_t * | module | ) |
Definition at line 1509 of file develop.c.
References delete_underscore(), dt_free, and dt_iop_module_t::multi_name.
| gboolean dt_masks_get_lock_mode | ( | dt_develop_t * | dev | ) |
Definition at line 1637 of file develop.c.
References darktable, dt_pthread_mutex_lock(), dt_pthread_mutex_unlock(), FALSE, darktable_t::gui, dt_develop_t::gui_attached, dt_develop_t::mask_lock, dt_gui_gtk_t::mutex, and state.
| void dt_masks_set_lock_mode | ( | dt_develop_t * | dev, |
| gboolean | mode | ||
| ) |
Definition at line 1649 of file develop.c.
References darktable, dt_pthread_mutex_lock(), dt_pthread_mutex_unlock(), darktable_t::gui, dt_develop_t::gui_attached, dt_develop_t::mask_lock, and dt_gui_gtk_t::mutex.