Ansel 0.0
A darktable fork - bloat + design vision
Loading...
Searching...
No Matches
pixelpipe_raster_masks.c File Reference

Raster-mask retrieval and transport through already-processed pipeline nodes. More...

+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

static gboolean _dt_dev_raster_mask_check (dt_dev_pixelpipe_iop_t *source_piece, dt_dev_pixelpipe_iop_t *current_piece, const dt_iop_module_t *target_module)
 Check that the raster-mask provider/consumer relation is still valid in the current pipe.
 
float * dt_dev_get_raster_mask (dt_dev_pixelpipe_t *pipe, const dt_iop_module_t *raster_mask_source, const int raster_mask_id, const dt_iop_module_t *target_module, gboolean *free_mask, int *error)
 

Detailed Description

Raster-mask retrieval and transport through already-processed pipeline nodes.

These routines are private to the pixelpipe implementation. They operate on pipeline node state that is already planned and partially processed, so they stay in the develop subsystem and are included from pixelpipe_hb.c.

The goal is to keep raster-mask specific lifecycle code out of the main pixel-processing recursion file: raster masks are not part of normal pixel transport, they are side-band buffers fetched from providers and optionally distorted through downstream modules until they reach the consumer.

Function Documentation

◆ _dt_dev_raster_mask_check()

static gboolean _dt_dev_raster_mask_check ( dt_dev_pixelpipe_iop_t source_piece,
dt_dev_pixelpipe_iop_t current_piece,
const dt_iop_module_t target_module 
)
static

Check that the raster-mask provider/consumer relation is still valid in the current pipe.

We loop over the already-synchronized pipeline nodes looking for 2 things:

  • the source module providing the raster mask,
  • the current target module consuming it.

If either end of the relation cannot be found, or if the source exists but is disabled, the mask cannot be trusted and the caller needs to stop the blending path with an explanatory error.

References delete_underscore(), dt_control_log(), dt_free, dt_dev_pixelpipe_iop_t::enabled, FALSE, dt_iop_module_t::multi_name, and TRUE.

Referenced by dt_dev_get_raster_mask().

◆ dt_dev_get_raster_mask()