Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPablo Dobarro <pablodp606@gmail.com>2019-11-06 21:39:34 +0300
committerPablo Dobarro <pablodp606@gmail.com>2019-11-21 20:16:42 +0300
commitc3279be222bdca1981a8c1a8582b19a7e693009b (patch)
tree6a828ca6e1f83f2e72940d1549b83642fe1decad /source/blender/makesdna/DNA_brush_types.h
parentc23dbcf37d9ffed4d443e0f9ce36f14854a52009 (diff)
Sculpt: Multiplane Scrape Brush
The Multiplane Scrape brush creates sharp edges with a given fixed angle by trimming the mesh with two planes in local space at the same time. When working with stylized or hard surface models, this brush produces way better results and is more predictable than any other crease/flatten brush based on curves and alphas. It is also the first brush we have than can produce hard surface concave creases. The Multiplane Scrape Brush also has a dynamic mode where it samples the surface to fit the angle and scrape planes during a stroke. With this mode enabled you can sculpt multiple times over the same edge without creating artifacts. It can also create creases that change between concave and convex during the same stroke. The behavior of this brush will improve after merging patches like D5993 and its behavior in concave creases can still be improved, so I will keep tweaking its parameters and default values once we have all brush properties available. Reviewed By: jbakker Differential Revision: https://developer.blender.org/D6174
Diffstat (limited to 'source/blender/makesdna/DNA_brush_types.h')
-rw-r--r--source/blender/makesdna/DNA_brush_types.h17
1 files changed, 15 insertions, 2 deletions
diff --git a/source/blender/makesdna/DNA_brush_types.h b/source/blender/makesdna/DNA_brush_types.h
index 67bca60e7e1..c55ab81a733 100644
--- a/source/blender/makesdna/DNA_brush_types.h
+++ b/source/blender/makesdna/DNA_brush_types.h
@@ -247,7 +247,9 @@ typedef struct Brush {
int size;
/** General purpose flags. */
int flag;
+ int flag2;
int sampling_flag;
+
/** Pressure influence for mask. */
int mask_pressure;
/** Jitter the position of the brush. */
@@ -288,7 +290,8 @@ typedef struct Brush {
/** Source for fill tool color gradient application. */
char gradient_fill_mode;
- char _pad[5];
+ char _pad0;
+
/** Projection shape (sphere, circle). */
char falloff_shape;
float falloff_angle;
@@ -307,7 +310,7 @@ typedef struct Brush {
char mask_tool;
/** Active grease pencil tool. */
char gpencil_tool;
- char _pad0[1];
+ char _pad1[5];
float autosmooth_factor;
@@ -332,6 +335,9 @@ typedef struct Brush {
/* pose */
float pose_offset;
+ /* multiplane scrape */
+ float multiplane_scrape_angle;
+
/* overlay */
int texture_overlay_alpha;
int mask_overlay_alpha;
@@ -445,6 +451,12 @@ typedef enum eBrushSamplingFlags {
BRUSH_PAINT_ANTIALIASING = (1 << 0),
} eBrushSamplingFlags;
+/* Brush.flag2 */
+typedef enum eBrushFlags2 {
+ BRUSH_MULTIPLANE_SCRAPE_DYNAMIC = (1 << 0),
+ BRUSH_MULTIPLANE_SCRAPE_PLANES_PREVIEW = (1 << 1),
+} eBrushFlags2;
+
typedef enum {
BRUSH_MASK_PRESSURE_RAMP = (1 << 1),
BRUSH_MASK_PRESSURE_CUTOFF = (1 << 2),
@@ -488,6 +500,7 @@ typedef enum eBrushSculptTool {
SCULPT_TOOL_DRAW_SHARP = 20,
SCULPT_TOOL_ELASTIC_DEFORM = 21,
SCULPT_TOOL_POSE = 22,
+ SCULPT_TOOL_MULTIPLANE_SCRAPE = 23,
} eBrushSculptTool;
/* Brush.uv_sculpt_tool */