diff options
author | Campbell Barton <ideasman42@gmail.com> | 2017-08-04 08:34:01 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2017-08-04 08:34:01 +0300 |
commit | 54cea98046962a7557ce1b75b4a6146373bdda42 (patch) | |
tree | c65b87fe0881976c57a8e3e5a3a34adf615a2d14 /source/blender/editors/space_view3d/view3d_manipulator_camera.c | |
parent | 0a3295953c26c2af059d92d027093d0bb5986750 (diff) |
Manipulator: add manipulator space matrix
Render-border & crop-node 2d-cage manipulators where unreasonably
complicated to implement because there was no good way to define
the sub-region the manipulator was transforming in
(render border within the camera's frame for example).
Add matrix-space variable,
remove scale property from cage2d manipulator, use matrix instead.
Diffstat (limited to 'source/blender/editors/space_view3d/view3d_manipulator_camera.c')
-rw-r--r-- | source/blender/editors/space_view3d/view3d_manipulator_camera.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/editors/space_view3d/view3d_manipulator_camera.c b/source/blender/editors/space_view3d/view3d_manipulator_camera.c index fe5ca5d2df9..e5619c1fd25 100644 --- a/source/blender/editors/space_view3d/view3d_manipulator_camera.c +++ b/source/blender/editors/space_view3d/view3d_manipulator_camera.c @@ -343,11 +343,11 @@ static void WIDGETGROUP_camera_view_draw_prepare(const bContext *C, wmManipulato } wmManipulator *mpr = viewgroup->border; - unit_m4(mpr->matrix_basis); - mul_v3_fl(mpr->matrix_basis[0], BLI_rctf_size_x(&viewgroup->state.view_border)); - mul_v3_fl(mpr->matrix_basis[1], BLI_rctf_size_y(&viewgroup->state.view_border)); - mpr->matrix_basis[3][0] = viewgroup->state.view_border.xmin; - mpr->matrix_basis[3][1] = viewgroup->state.view_border.ymin; + unit_m4(mpr->matrix_space); + mul_v3_fl(mpr->matrix_space[0], BLI_rctf_size_x(&viewgroup->state.view_border)); + mul_v3_fl(mpr->matrix_space[1], BLI_rctf_size_y(&viewgroup->state.view_border)); + mpr->matrix_space[3][0] = viewgroup->state.view_border.xmin; + mpr->matrix_space[3][1] = viewgroup->state.view_border.ymin; } static void WIDGETGROUP_camera_view_refresh(const bContext *C, wmManipulatorGroup *mgroup) |