Ansel 0.0
A darktable fork - bloat + design vision
Loading...
Searching...
No Matches
dt_drawlayer_brush_dab_t Struct Reference

Fully resolved input dab descriptor. More...

#include <brush.h>

+ Collaboration diagram for dt_drawlayer_brush_dab_t:

Data Fields

float x
 
float y
 
float wx
 
float wy
 
float radius
 
float dir_x
 
float dir_y
 
float sample_spacing
 
float sample_opacity_scale
 
float opacity
 
float flow
 
float sprinkles
 
float sprinkle_size
 
float sprinkle_coarseness
 
float hardness
 
float color [4]
 
float display_color [3]
 
int shape
 
int mode
 
uint32_t stroke_batch
 
uint8_t stroke_pos
 

Detailed Description

Fully resolved input dab descriptor.

Instances are produced by the stroke-level paint API (or equivalent caller code) and consumed by the brush rasterizer.

Definition at line 63 of file brush.h.

Field Documentation

◆ color

float dt_drawlayer_brush_dab_t::color[4]

Premultiplied-space source RGBA, alpha conventionally set to 1.

Definition at line 80 of file brush.h.

Referenced by _apply_quadratic_dab_smoothing(), _paint_build_segment_window_sample(), and dt_drawlayer_brush_rasterize_dab_rgbaf().

◆ dir_x

float dt_drawlayer_brush_dab_t::dir_x

Unit direction X along local stroke tangent (or 0 when unknown).

Definition at line 70 of file brush.h.

Referenced by _brush_runtime_view_from_state(), _emit_dab(), _enforce_dab_center_spacing(), and _paint_build_segment_window_sample().

◆ dir_y

float dt_drawlayer_brush_dab_t::dir_y

Unit direction Y along local stroke tangent (or 1 when unknown).

Definition at line 71 of file brush.h.

Referenced by _brush_runtime_view_from_state(), _emit_dab(), _enforce_dab_center_spacing(), and _paint_build_segment_window_sample().

◆ display_color

float dt_drawlayer_brush_dab_t::display_color[3]

Display-space RGB counterpart for GUI preview widgets.

Definition at line 81 of file brush.h.

Referenced by _apply_quadratic_dab_smoothing(), _paint_build_segment_window_sample(), and dt_drawlayer_brush_rasterize_dab_argb8().

◆ flow

float dt_drawlayer_brush_dab_t::flow

Per-dab flow in [0,1] after input mapping (API-level convention).

Definition at line 75 of file brush.h.

Referenced by _apply_quadratic_dab_smoothing(), _paint_build_segment_window_sample(), _prepare_analytic_pixel_context(), and dt_drawlayer_brush_rasterize().

◆ hardness

float dt_drawlayer_brush_dab_t::hardness

◆ mode

◆ opacity

◆ radius

◆ sample_opacity_scale

float dt_drawlayer_brush_dab_t::sample_opacity_scale

Precomputed spacing normalization consumed by rasterization.

Definition at line 73 of file brush.h.

Referenced by _freeze_emitted_dab_raster_state(), and dt_drawlayer_paint_rasterize_segment_to_buffer().

◆ sample_spacing

float dt_drawlayer_brush_dab_t::sample_spacing

Emission spacing chosen by the stroke sampler for this dab.

Definition at line 72 of file brush.h.

Referenced by _freeze_emitted_dab_raster_state(), and dt_drawlayer_paint_rasterize_segment_to_buffer().

◆ shape

◆ sprinkle_coarseness

float dt_drawlayer_brush_dab_t::sprinkle_coarseness

Octave mix control in [0,1] from fine (0) to coarse (1).

Definition at line 78 of file brush.h.

Referenced by _apply_quadratic_dab_smoothing(), _brush_runtime_view_from_state(), _paint_build_segment_window_sample(), and _prepare_sprinkle_preview().

◆ sprinkle_size

float dt_drawlayer_brush_dab_t::sprinkle_size

Sprinkle pattern spatial scale in pixels.

Definition at line 77 of file brush.h.

Referenced by _apply_quadratic_dab_smoothing(), _brush_runtime_view_from_state(), _paint_build_segment_window_sample(), and _prepare_sprinkle_preview().

◆ sprinkles

float dt_drawlayer_brush_dab_t::sprinkles

◆ stroke_batch

uint32_t dt_drawlayer_brush_dab_t::stroke_batch

Monotonic stroke id used for deterministic per-stroke noise seeding.

Definition at line 84 of file brush.h.

Referenced by _brush_runtime_view_from_state(), _paint_process_one_raw_input(), and _prepare_sprinkle_preview().

◆ stroke_pos

uint8_t dt_drawlayer_brush_dab_t::stroke_pos

Stroke position tag (first/middle/end), see paint API enum.

Definition at line 85 of file brush.h.

Referenced by _emit_first_sample_if_needed(), _paint_process_one_raw_input(), dt_drawlayer_paint_finalize_path(), and dt_drawlayer_paint_rasterize_segment_to_buffer().

◆ wx

float dt_drawlayer_brush_dab_t::wx

Dab center X in widget-space coordinates (for GUI overlays).

Definition at line 67 of file brush.h.

Referenced by _apply_quadratic_dab_smoothing(), _enforce_dab_center_spacing(), and _paint_build_segment_window_sample().

◆ wy

float dt_drawlayer_brush_dab_t::wy

Dab center Y in widget-space coordinates (for GUI overlays).

Definition at line 68 of file brush.h.

Referenced by _apply_quadratic_dab_smoothing(), _enforce_dab_center_spacing(), and _paint_build_segment_window_sample().

◆ x

◆ y


The documentation for this struct was generated from the following file: