|
Blender V4.3
|
#include <cstdlib>#include "DNA_windowmanager_types.h"#include "BLI_math_matrix.h"#include "BLI_math_vector.h"#include "BLI_task.h"#include "BKE_image.hh"#include "BKE_unit.hh"#include "ED_screen.hh"#include "RNA_access.hh"#include "UI_interface.hh"#include "transform.hh"#include "transform_constraints.hh"#include "transform_convert.hh"#include "transform_mode.hh"#include "transform_snap.hh"Go to the source code of this file.
Classes | |
| struct | ElemResizeData |
Functions | |
Transform (Resize) Element | |
| static void | element_resize_fn (void *__restrict iter_data_v, const int iter, const TaskParallelTLS *__restrict) |
Transform (Resize) | |
| static float | ResizeBetween (TransInfo *t, const float p1[3], const float p2[3]) |
| static void | ApplySnapResize (TransInfo *t, float vec[3]) |
| static void | constrain_scale_to_boundary (const float numerator, const float denominator, float *scale) |
| static bool | clip_uv_transform_resize (TransInfo *t, float vec[2]) |
| static void | applyResize (TransInfo *t) |
| static void | resize_transform_matrix_fn (TransInfo *t, float mat_xform[4][4]) |
| static void | initResize (TransInfo *t, wmOperator *op) |
Variables | |
| TransModeInfo | TransMode_resize |
|
static |
Definition at line 192 of file transform_mode_resize.cc.
References add_v3_v3(), applyNumInput(), TransCon::applySize, TransInfo::area, BLI_parallel_range_settings_defaults(), BLI_task_parallel_range(), clip_uv_transform_resize(), clipUVData(), TransInfo::con, CON_APPLY, CON_AXIS0, constraintNumInput(), copy_m3_m3(), copy_v3_fl(), copy_v3_v3(), ED_area_status_text(), element_resize_fn(), ElementResize(), TransInfo::flag, FOREACH_TRANS_DATA_CONTAINER, headerResize(), TransInfo::mat, TransCon::mode, TransInfo::num, recalc_data(), size_to_mat3(), str, ElemResizeData::t, T_CLIP_UV, T_INPUT_IS_VALUES_FINAL, T_PROP_EDIT, TD_SKIP, TRANSDATA_THREAD_LIMIT, transform_snap_increment(), transform_snap_mixed_apply(), UI_MAX_DRAW_STR, TransInfo::values, TransInfo::values_final, and TransInfo::values_modal_offset.
Definition at line 84 of file transform_mode_resize.cc.
References copy_v3_fl(), getSnapPoint(), ResizeBetween(), TransSnap::snap_source, TRANSFORM_DIST_INVALID, and TransInfo::tsnap.
Definition at line 139 of file transform_mode_resize.cc.
References TransInfo::area, TransInfo::around, TransInfo::aspect, BKE_image_find_nearest_tile_with_offset(), TransInfo::center_global, TransInfo::con, CON_AXIS0, CON_AXIS1, constrain_scale_to_boundary(), ListBase::first, FOREACH_TRANS_DATA_CONTAINER, SpaceImage::image, min, TransCon::mode, ScrArea::spacedata, and transdata_check_local_center().
Referenced by applyResize().
|
static |
Find the correction for the scaling factor when "Constrain to Bounds" is active.
| numerator | How far the UV boundary (unit square) is from the origin of the scale. |
| denominator | How far the AABB is from the origin of the scale. |
| scale | Scale parameter to update. |
Definition at line 101 of file transform_mode_resize.cc.
References fabsf.
Referenced by clip_uv_transform_resize().
|
static |
Definition at line 44 of file transform_mode_resize.cc.
References ElementResize(), and TD_SKIP.
Referenced by applyResize().
|
static |
Definition at line 297 of file transform_mode_resize.cc.
References B_UNIT_NONE, BLI_assert, TransInfo::center2d, copy_m3_m4(), copy_v3_fl(), NumInput::flag, TransInfo::flag, wmOperator::idname, NumInput::idx_max, TransInfo::idx_max, initMouseInputMode(), INPUT_CUSTOM_RATIO, INPUT_SPRING_FLIP, is_zero_v2(), is_zero_v3(), TransInfo::mouse, mul_v3_m3v3(), TransInfo::mval, normalize_v2(), TransInfo::num, NUM_AFFECT_ALL, NUM_NO_ZERO, NUM_NULL_ONE, project_v2_v2v2(), wmOperator::ptr, RNA_property_float_get_array(), RNA_struct_find_property(), TransInfo::scene, setCustomPoints(), TransInfo::snap, STREQ, UnitSettings::system, T_EDIT, transform_mode_default_modal_orientation_set(), Scene::unit, NumInput::unit_sys, NumInput::unit_type, V3D_ORIENT_GLOBAL, NumInput::val_flag, NumInput::val_inc, TransInfo::viewmat, and zero_v3().
Definition at line 289 of file transform_mode_resize.cc.
References TransInfo::center_global, copy_m4_m3(), TransInfo::mat, mat4, mul_m4_m4m4(), and transform_pivot_set_m4().
Definition at line 62 of file transform_mode_resize.cc.
References TransCon::applyRot, TransInfo::center_global, TransInfo::con, CON_APPLY, len_v3(), TransCon::mode, mul_m3_v3(), TransCon::pmtx, project_v3_v3v3(), sub_v3_v3v3(), and TRANSFORM_DIST_INVALID.
Referenced by ApplySnapResize().
| TransModeInfo TransMode_resize |
Definition at line 374 of file transform_mode_resize.cc.
Referenced by mode_info_get().