Blender V5.0
blender::ed::sculpt_paint::PaintStroke Struct Reference

Public Attributes

std::unique_ptr< PaintModeDatamode_data
void * stroke_cursor
wmTimertimer
std::optional< RandomNumberGeneratorrng
ViewContext vc
Paintpaint
Brushbrush
UnifiedPaintSettingsups
PaintSample samples [PAINT_MAX_INPUT_SAMPLES]
int num_samples
int cur_sample
int tot_samples
float2 last_mouse_position
float3 last_world_space_position
float3 last_scene_spacing_delta
bool stroke_over_mesh
float stroke_distance
bool stroke_started
bool rake_started
int event_type
bool stroke_init
bool input_init
float2 initial_mouse
float cached_size_pressure
float last_pressure
int stroke_mode
float last_tablet_event_pressure
float zoom_2d
bool pen_flip
float2 tilt
bool constrain_line
float2 constrained_pos
StrokeGetLocation get_location
StrokeTestStart test_start
StrokeUpdateStep update_step
StrokeRedraw redraw
StrokeDone done
bool original

Detailed Description

Common structure for various paint operators (e.g. Sculpt, Grease Pencil, Curves Sculpt)

Callback functions defined and stored on this struct (e.g. StrokeGetLocation) allow each of these modes to customize specific behavior while still sharing other common handing.

See paint_stroke_modal for the majority of the paint operator logic.

Definition at line 75 of file paint_stroke.cc.

Member Data Documentation

◆ brush

◆ cached_size_pressure

float blender::ed::sculpt_paint::PaintStroke::cached_size_pressure

Definition at line 115 of file paint_stroke.cc.

Referenced by blender::ed::sculpt_paint::paint_brush_update().

◆ constrain_line

bool blender::ed::sculpt_paint::PaintStroke::constrain_line

◆ constrained_pos

float2 blender::ed::sculpt_paint::PaintStroke::constrained_pos

◆ cur_sample

int blender::ed::sculpt_paint::PaintStroke::cur_sample

Definition at line 91 of file paint_stroke.cc.

Referenced by blender::ed::sculpt_paint::paint_stroke_add_sample().

◆ done

StrokeDone blender::ed::sculpt_paint::PaintStroke::done

◆ event_type

int blender::ed::sculpt_paint::PaintStroke::event_type

◆ get_location

◆ initial_mouse

float2 blender::ed::sculpt_paint::PaintStroke::initial_mouse

Definition at line 114 of file paint_stroke.cc.

Referenced by blender::ed::sculpt_paint::paint_brush_update().

◆ input_init

bool blender::ed::sculpt_paint::PaintStroke::input_init

Definition at line 113 of file paint_stroke.cc.

Referenced by blender::ed::sculpt_paint::paint_brush_update().

◆ last_mouse_position

◆ last_pressure

◆ last_scene_spacing_delta

float3 blender::ed::sculpt_paint::PaintStroke::last_scene_spacing_delta

◆ last_tablet_event_pressure

float blender::ed::sculpt_paint::PaintStroke::last_tablet_event_pressure

Definition at line 120 of file paint_stroke.cc.

Referenced by blender::ed::sculpt_paint::paint_stroke_modal().

◆ last_world_space_position

◆ mode_data

std::unique_ptr<PaintModeData> blender::ed::sculpt_paint::PaintStroke::mode_data

◆ num_samples

int blender::ed::sculpt_paint::PaintStroke::num_samples

◆ original

◆ paint

◆ pen_flip

bool blender::ed::sculpt_paint::PaintStroke::pen_flip

◆ rake_started

bool blender::ed::sculpt_paint::PaintStroke::rake_started

Definition at line 107 of file paint_stroke.cc.

Referenced by blender::ed::sculpt_paint::paint_brush_update().

◆ redraw

◆ rng

std::optional<RandomNumberGenerator> blender::ed::sculpt_paint::PaintStroke::rng

Definition at line 79 of file paint_stroke.cc.

Referenced by blender::ed::sculpt_paint::paint_brush_update().

◆ samples

◆ stroke_cursor

void* blender::ed::sculpt_paint::PaintStroke::stroke_cursor

◆ stroke_distance

◆ stroke_init

bool blender::ed::sculpt_paint::PaintStroke::stroke_init

Definition at line 111 of file paint_stroke.cc.

Referenced by blender::ed::sculpt_paint::paint_stroke_modal().

◆ stroke_mode

◆ stroke_over_mesh

◆ stroke_started

◆ test_start

◆ tilt

float2 blender::ed::sculpt_paint::PaintStroke::tilt

◆ timer

wmTimer* blender::ed::sculpt_paint::PaintStroke::timer

◆ tot_samples

int blender::ed::sculpt_paint::PaintStroke::tot_samples

◆ update_step

◆ ups

UnifiedPaintSettings* blender::ed::sculpt_paint::PaintStroke::ups

Definition at line 85 of file paint_stroke.cc.

Referenced by blender::ed::sculpt_paint::paint_stroke_new().

◆ vc

◆ zoom_2d


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