diff options
author | Germano Cavalcante <germano.costa@ig.com.br> | 2016-05-11 12:59:02 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2016-05-11 13:20:25 +0300 |
commit | 67d2de882841f56c9cd35f0f0e7329b0c9190c97 (patch) | |
tree | 49778334fe1d4e71e19a62a5876a8d10e4a6e2ff /source/blender/editors/include/ED_transform.h | |
parent | 4a135ad2b7886c3a4731f7db7ddce60af8068f32 (diff) |
Transform Volume rewrite/refactor
Take advantage of the efficiency provided by the snap_context.
Also fixes errors:
- volume snap fails based on view angle (T48394).
- multiple instances of dupli-objects break volume calculation.
Diffstat (limited to 'source/blender/editors/include/ED_transform.h')
-rw-r--r-- | source/blender/editors/include/ED_transform.h | 29 |
1 files changed, 10 insertions, 19 deletions
diff --git a/source/blender/editors/include/ED_transform.h b/source/blender/editors/include/ED_transform.h index c881e849cf5..933f480a554 100644 --- a/source/blender/editors/include/ED_transform.h +++ b/source/blender/editors/include/ED_transform.h @@ -158,19 +158,6 @@ void BIF_draw_manipulator(const struct bContext *C); /* Snapping */ - -typedef struct DepthPeel { - struct DepthPeel *next, *prev; - - float depth; - float p[3]; - float no[3]; - struct Object *ob; - int flag; -} DepthPeel; - -struct ListBase; - typedef enum SnapSelect { SNAP_ALL = 0, SNAP_NOT_SELECTED = 1, @@ -179,14 +166,18 @@ typedef enum SnapSelect { #define SNAP_MIN_DISTANCE 30 -bool peelObjectsTransForm( - struct TransInfo *t, const float mval[2], SnapSelect snap_select, +bool peelObjectsTransform( + struct TransInfo *t, const float mval[2], + SnapSelect snap_select, bool use_peel_object, /* return args */ - struct ListBase *r_depth_peels); -bool peelObjectsContext( - struct bContext *C, const float mval[2], SnapSelect snap_select, + float r_loc[3], float r_no[3], float *r_thickness); +bool peelObjectsSnapContext( + struct SnapObjectContext *sctx, + const float mval[2], + SnapSelect snap_select, bool use_peel_object, /* return args */ - struct ListBase *r_depth_peels); + float r_loc[3], float r_no[3], float *r_thickness); + bool snapObjectsTransform( struct TransInfo *t, const float mval[2], SnapSelect snap_select, float *dist_px, |