Blender V4.3
paint_ops.cc File Reference
#include <cstddef>
#include <cstdlib>
#include <cstring>
#include "MEM_guardedalloc.h"
#include "BLI_listbase.h"
#include "BLI_math_vector.h"
#include "BLI_string.h"
#include "BLI_utildefines.h"
#include "IMB_interp.hh"
#include "DNA_brush_types.h"
#include "DNA_customdata_types.h"
#include "DNA_object_types.h"
#include "DNA_scene_types.h"
#include "BKE_brush.hh"
#include "BKE_context.hh"
#include "BKE_image.hh"
#include "BKE_lib_id.hh"
#include "BKE_main.hh"
#include "BKE_paint.hh"
#include "BKE_report.hh"
#include "ED_image.hh"
#include "ED_paint.hh"
#include "ED_screen.hh"
#include "WM_api.hh"
#include "WM_toolsystem.hh"
#include "WM_types.hh"
#include "RNA_access.hh"
#include "RNA_define.hh"
#include "curves_sculpt_intern.hh"
#include "paint_hide.hh"
#include "paint_intern.hh"
#include "paint_mask.hh"
#include "sculpt_intern.hh"

Go to the source code of this file.

Classes

struct  StencilControlData
 

Macros

#define PIXEL_MARGIN   5
 

Enumerations

enum  StencilControlMode { STENCIL_TRANSLATE , STENCIL_SCALE , STENCIL_ROTATE }
 
enum  StencilTextureMode { STENCIL_PRIMARY = 0 , STENCIL_SECONDARY = 1 }
 
enum  StencilConstraint { STENCIL_CONSTRAINT_X = 1 , STENCIL_CONSTRAINT_Y = 2 }
 

Functions

static int brush_scale_size_exec (bContext *C, wmOperator *op)
 
static void BRUSH_OT_scale_size (wmOperatorType *ot)
 
static int palette_new_exec (bContext *C, wmOperator *)
 
static void PALETTE_OT_new (wmOperatorType *ot)
 
static bool palette_poll (bContext *C)
 
static int palette_color_add_exec (bContext *C, wmOperator *)
 
static void PALETTE_OT_color_add (wmOperatorType *ot)
 
static int palette_color_delete_exec (bContext *C, wmOperator *)
 
static void PALETTE_OT_color_delete (wmOperatorType *ot)
 
static bool palette_extract_img_poll (bContext *C)
 
static int palette_extract_img_exec (bContext *C, wmOperator *op)
 
static void PALETTE_OT_extract_from_image (wmOperatorType *ot)
 
static int palette_sort_exec (bContext *C, wmOperator *op)
 
static void PALETTE_OT_sort (wmOperatorType *ot)
 
static int palette_color_move_exec (bContext *C, wmOperator *op)
 
static void PALETTE_OT_color_move (wmOperatorType *ot)
 
static int palette_join_exec (bContext *C, wmOperator *op)
 
static void PALETTE_OT_join (wmOperatorType *ot)
 
static void stencil_set_target (StencilControlData *scd)
 
static int stencil_control_invoke (bContext *C, wmOperator *op, const wmEvent *event)
 
static void stencil_restore (StencilControlData *scd)
 
static void stencil_control_cancel (bContext *, wmOperator *op)
 
static void stencil_control_calculate (StencilControlData *scd, const int mval[2])
 
static int stencil_control_modal (bContext *C, wmOperator *op, const wmEvent *event)
 
static bool stencil_control_poll (bContext *C)
 
static void BRUSH_OT_stencil_control (wmOperatorType *ot)
 
static int stencil_fit_image_aspect_exec (bContext *C, wmOperator *op)
 
static void BRUSH_OT_stencil_fit_image_aspect (wmOperatorType *ot)
 
static int stencil_reset_transform_exec (bContext *C, wmOperator *op)
 
static void BRUSH_OT_stencil_reset_transform (wmOperatorType *ot)
 
void ED_operatormacros_paint ()
 
void ED_operatortypes_paint ()
 
void ED_keymap_paint (wmKeyConfig *keyconf)
 

Macro Definition Documentation

◆ PIXEL_MARGIN

#define PIXEL_MARGIN   5

Enumeration Type Documentation

◆ StencilConstraint

Enumerator
STENCIL_CONSTRAINT_X 
STENCIL_CONSTRAINT_Y 

Definition at line 548 of file paint_ops.cc.

◆ StencilControlMode

Enumerator
STENCIL_TRANSLATE 
STENCIL_SCALE 
STENCIL_ROTATE 

Definition at line 537 of file paint_ops.cc.

◆ StencilTextureMode

Enumerator
STENCIL_PRIMARY 
STENCIL_SECONDARY 

Definition at line 543 of file paint_ops.cc.

Function Documentation

◆ BRUSH_OT_scale_size()

◆ BRUSH_OT_stencil_control()

◆ BRUSH_OT_stencil_fit_image_aspect()

◆ BRUSH_OT_stencil_reset_transform()

◆ brush_scale_size_exec()

◆ ED_keymap_paint()

◆ ED_operatormacros_paint()

◆ ED_operatortypes_paint()

void ED_operatortypes_paint ( )

Definition at line 969 of file paint_ops.cc.

References BRUSH_OT_curve_preset(), BRUSH_OT_scale_size(), BRUSH_OT_sculpt_curves_falloff_preset(), BRUSH_OT_stencil_control(), BRUSH_OT_stencil_fit_image_aspect(), BRUSH_OT_stencil_reset_transform(), PAINT_OT_add_simple_uvs(), PAINT_OT_add_texture_paint_slot(), PAINT_OT_brush_colors_flip(), PAINT_OT_face_select_all(), PAINT_OT_face_select_hide(), PAINT_OT_face_select_less(), PAINT_OT_face_select_linked(), PAINT_OT_face_select_linked_pick(), PAINT_OT_face_select_loop(), PAINT_OT_face_select_more(), PAINT_OT_face_vert_reveal(), PAINT_OT_grab_clone(), PAINT_OT_image_from_view(), PAINT_OT_image_paint(), PAINT_OT_project_image(), PAINT_OT_sample_color(), PAINT_OT_texture_paint_toggle(), PAINT_OT_vert_select_all(), PAINT_OT_vert_select_hide(), PAINT_OT_vert_select_less(), PAINT_OT_vert_select_linked(), PAINT_OT_vert_select_linked_pick(), PAINT_OT_vert_select_more(), PAINT_OT_vert_select_ungrouped(), PAINT_OT_vertex_color_brightness_contrast(), PAINT_OT_vertex_color_from_weight(), PAINT_OT_vertex_color_hsv(), PAINT_OT_vertex_color_invert(), PAINT_OT_vertex_color_levels(), PAINT_OT_vertex_color_set(), PAINT_OT_vertex_color_smooth(), PAINT_OT_vertex_paint(), PAINT_OT_vertex_paint_toggle(), PAINT_OT_weight_from_bones(), PAINT_OT_weight_gradient(), PAINT_OT_weight_paint(), PAINT_OT_weight_paint_toggle(), PAINT_OT_weight_sample(), PAINT_OT_weight_sample_group(), PAINT_OT_weight_set(), PAINTCURVE_OT_add_point(), PAINTCURVE_OT_cursor(), PAINTCURVE_OT_delete_point(), PAINTCURVE_OT_draw(), PAINTCURVE_OT_new(), PAINTCURVE_OT_select(), PAINTCURVE_OT_slide(), PALETTE_OT_color_add(), PALETTE_OT_color_delete(), PALETTE_OT_color_move(), PALETTE_OT_extract_from_image(), PALETTE_OT_join(), PALETTE_OT_new(), PALETTE_OT_sort(), SCULPT_OT_uv_sculpt_grab(), SCULPT_OT_uv_sculpt_pinch(), SCULPT_OT_uv_sculpt_relax(), and WM_operatortype_append().

Referenced by ED_spacetypes_init().

◆ palette_color_add_exec()

◆ palette_color_delete_exec()

◆ palette_color_move_exec()

◆ palette_extract_img_exec()

◆ palette_extract_img_poll()

static bool palette_extract_img_poll ( bContext * C)
static

◆ palette_join_exec()

◆ palette_new_exec()

static int palette_new_exec ( bContext * C,
wmOperator *  )
static

◆ PALETTE_OT_color_add()

◆ PALETTE_OT_color_delete()

◆ PALETTE_OT_color_move()

◆ PALETTE_OT_extract_from_image()

◆ PALETTE_OT_join()

◆ PALETTE_OT_new()

◆ PALETTE_OT_sort()

◆ palette_poll()

◆ palette_sort_exec()

◆ stencil_control_calculate()

◆ stencil_control_cancel()

static void stencil_control_cancel ( bContext * ,
wmOperator * op )
static

◆ stencil_control_invoke()

◆ stencil_control_modal()

◆ stencil_control_poll()

◆ stencil_fit_image_aspect_exec()

◆ stencil_reset_transform_exec()

◆ stencil_restore()

◆ stencil_set_target()