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:
authorAntony Riakiotakis <kalast@gmail.com>2013-12-10 00:36:33 +0400
committerAntony Riakiotakis <kalast@gmail.com>2013-12-10 00:40:02 +0400
commitf0675b14d84392e65c9e746752defa707335626c (patch)
tree063c281b5b063d506d9a46bb1970e69f33975470 /source/blender/makesdna
parentec30d711ccfc28be494580df38d4fce9c0a00875 (diff)
Refactoring/cleanup, borrowed from soc-2013-paint branch.
* Move symmetry options to the paint struct (where all paint systems can make use of it) * Rename draw_pressure to stroke_active. This is what is really checked on those occasions that this is used. Also move turning on/off of this option to the stroke level and avoid doing it on every stroke system. * Rename BRUSH_RESTORE_MESH to BRUSH_DRAG_DOT. In image painting this won't restore any mesh, so better have a name that is directly linked to what the flag actually does.
Diffstat (limited to 'source/blender/makesdna')
-rw-r--r--source/blender/makesdna/DNA_brush_types.h2
-rw-r--r--source/blender/makesdna/DNA_scene_types.h20
2 files changed, 19 insertions, 3 deletions
diff --git a/source/blender/makesdna/DNA_brush_types.h b/source/blender/makesdna/DNA_brush_types.h
index 824091dab32..86fa7058f97 100644
--- a/source/blender/makesdna/DNA_brush_types.h
+++ b/source/blender/makesdna/DNA_brush_types.h
@@ -140,7 +140,7 @@ typedef enum BrushFlags {
BRUSH_LOCK_SIZE = (1 << 20),
// BRUSH_TEXTURE_OVERLAY = (1 << 21), /* obsolete, use overlay_flags |= BRUSH_OVERLAY_PRIMARY instead */
BRUSH_EDGE_TO_EDGE = (1 << 22),
- BRUSH_RESTORE_MESH = (1 << 23),
+ BRUSH_DRAG_DOT = (1 << 23),
BRUSH_INVERSE_SMOOTH_PRESSURE = (1 << 24),
BRUSH_RANDOM_ROTATION = (1 << 25),
BRUSH_PLANE_TRIM = (1 << 26),
diff --git a/source/blender/makesdna/DNA_scene_types.h b/source/blender/makesdna/DNA_scene_types.h
index 5291ad808b1..88f25bd57ae 100644
--- a/source/blender/makesdna/DNA_scene_types.h
+++ b/source/blender/makesdna/DNA_scene_types.h
@@ -770,7 +770,8 @@ typedef struct Paint {
* smooth the stroke */
int num_input_samples;
- int pad;
+ /* flags used for symmetry */
+ int symmetry_flags;
} Paint;
/* ------------------------------------------- */
@@ -919,8 +920,10 @@ typedef struct UnifiedPaintSettings {
int anchored_size;
float anchored_initial_mouse[2];
+ /* check is there an ongoing stroke right now */
+ int stroke_active;
+
/* drawing pressure */
- int draw_pressure;
float pressure_value;
/* position of mouse, used to sample the texture */
@@ -1550,16 +1553,29 @@ typedef enum {
PAINT_SHOW_BRUSH_ON_SURFACE = (1 << 2),
} PaintFlags;
+/* Paint.symmetry_flags
+ * (for now just a duplicate of sculpt symmetry flags) */
+typedef enum SymmetryFlags {
+ PAINT_SYMM_X = (1 << 0),
+ PAINT_SYMM_Y = (1 << 1),
+ PAINT_SYMM_Z = (1 << 2),
+ PAINT_SYMMETRY_FEATHER = (1 << 3)
+} SymmetryFlags;
+
/* Sculpt.flags */
/* These can eventually be moved to paint flags? */
typedef enum SculptFlags {
+ /* deprecated, part of paint struct symmetry_flags now */
SCULPT_SYMM_X = (1 << 0),
SCULPT_SYMM_Y = (1 << 1),
SCULPT_SYMM_Z = (1 << 2),
+
SCULPT_LOCK_X = (1 << 3),
SCULPT_LOCK_Y = (1 << 4),
SCULPT_LOCK_Z = (1 << 5),
+ /* deprecated, part of paint struct symmetry_flags now */
SCULPT_SYMMETRY_FEATHER = (1 << 6),
+
SCULPT_USE_OPENMP = (1 << 7),
SCULPT_ONLY_DEFORM = (1 << 8),
SCULPT_SHOW_DIFFUSE = (1 << 9),