Blender
V3.3
|
#include <stdlib.h>
#include "BLI_math.h"
#include "BLI_task.h"
#include "BKE_context.h"
#include "BKE_report.h"
#include "BKE_unit.h"
#include "ED_screen.h"
#include "UI_interface.h"
#include "transform.h"
#include "transform_convert.h"
#include "transform_snap.h"
#include "transform_mode.h"
Go to the source code of this file.
Classes | |
struct | RotateMatrixCache |
struct | TransDataArgs_Rotate |
struct | TransDataArgs_RotateTLS |
Functions | |
Transform (Rotation) Matrix Cache | |
static void | rmat_cache_init (struct RotateMatrixCache *rmc, const float angle, const float axis[3]) |
static void | rmat_cache_reset (struct RotateMatrixCache *rmc) |
static void | rmat_cache_update (struct RotateMatrixCache *rmc, const float axis[3], const float angle) |
Transform (Rotation) Element | |
static void | transdata_elem_rotate (const TransInfo *t, const TransDataContainer *tc, TransData *td, const float axis[3], const float angle, const float angle_step, const bool is_large_rotation, struct RotateMatrixCache *rmc) |
static void | transdata_elem_rotate_fn (void *__restrict iter_data_v, const int iter, const TaskParallelTLS *__restrict tls) |
Transform (Rotation) | |
static float | RotationBetween (TransInfo *t, const float p1[3], const float p2[3]) |
static void | ApplySnapRotation (TransInfo *t, float *value) |
static float | large_rotation_limit (float angle) |
static void | applyRotationValue (TransInfo *t, float angle, const float axis[3], const bool is_large_rotation) |
static void | applyRotation (TransInfo *t, const int UNUSED(mval[2])) |
static void | applyRotationMatrix (TransInfo *t, float mat_xform[4][4]) |
void | initRotation (TransInfo *t) |
Definition at line 289 of file transform_mode_rotate.c.
References activeSnap(), applyNumInput(), applyRotationValue(), applySnappingAsGroup(), CON_APPLY, ED_area_status_text(), hasNumInput(), headerRotation(), large_rotation_limit(), negate_v3_v3(), NULL, recalcData(), str, t, transform_snap_increment(), UI_MAX_DRAW_STR, and validSnap().
Referenced by initRotation().
Definition at line 326 of file transform_mode_rotate.c.
References axis_angle_normalized_to_mat3(), CON_APPLY, copy_m4_m3(), mat4, mul_m4_m4m4(), negate_v3_v3(), NULL, t, and transform_pivot_set_m4().
Referenced by initRotation().
|
static |
Definition at line 238 of file transform_mode_rotate.c.
References angle(), TransDataArgs_Rotate::angle_step, TransDataArgs_Rotate::axis, BLI_parallel_range_settings_defaults(), BLI_task_parallel_range(), data, float(), FOREACH_TRANS_DATA_CONTAINER, TransDataArgs_Rotate::is_large_rotation, large_rotation_limit(), M_PI, rmat_cache_init(), TransDataArgs_RotateTLS::rmc, t, TransDataArgs_Rotate::tc, TD_SKIP, transdata_elem_rotate(), transdata_elem_rotate_fn(), TRANSDATA_THREAD_LIMIT, UNPACK3, TaskParallelSettings::userdata_chunk, and TaskParallelSettings::userdata_chunk_size.
Referenced by applyRotation().
Definition at line 217 of file transform_mode_rotate.c.
References getSnapPoint(), point, RotationBetween(), and t.
Referenced by initRotation().
Definition at line 345 of file transform_mode_rotate.c.
References applyRotation(), applyRotationMatrix(), ApplySnapRotation(), B_UNIT_ROTATION, BKE_report(), copy_v3_fl(), DEG2RAD, initMouseInputMode(), INPUT_ANGLE, RotationBetween(), RPT_ERROR, SPACE_ACTION, t, T_2D_EDIT, T_NO_CONSTRAINT, TFM_ROTATION, TRANS_CANCEL, transform_mode_default_modal_orientation_set(), USER_UNIT_ROT_RADIANS, and V3D_ORIENT_VIEW.
Referenced by transform_mode_init().
Definition at line 226 of file transform_mode_rotate.c.
References angle(), fabsf, float(), fmodf, and M_PI.
Referenced by applyRotation(), and applyRotationValue().
|
static |
Definition at line 41 of file transform_mode_rotate.c.
References angle(), axis_angle_normalized_to_mat3(), RotateMatrixCache::do_update_matrix, and RotateMatrixCache::mat.
Referenced by applyRotationValue().
|
static |
Definition at line 47 of file transform_mode_rotate.c.
References RotateMatrixCache::do_update_matrix.
Referenced by transdata_elem_rotate().
|
static |
Definition at line 52 of file transform_mode_rotate.c.
References angle(), axis_angle_normalized_to_mat3(), RotateMatrixCache::do_update_matrix, and RotateMatrixCache::mat.
Referenced by transdata_elem_rotate().
Definition at line 165 of file transform_mode_rotate.c.
References acosf, angle(), atan2f, CON_APPLY, copy_m3_m4(), cross_v3_v3v3(), dot_v3v3(), float(), M_PI, mul_m3_v3(), normalize_v3(), NULL, project_v3_v3v3(), sub_v3_v3v3(), and t.
Referenced by ApplySnapRotation(), and initRotation().
|
static |
Definition at line 84 of file transform_mode_rotate.c.
References angle(), axis_angle_normalized_to_mat3(), copy_v3_v3(), ElementRotation(), TransData::ext, fabsf, TransData::factor, TransDataExtension::irot, RotateMatrixCache::mat, NULL, rmat_cache_reset(), rmat_cache_update(), TransDataExtension::rot, ROT_MODE_EUL, TransDataExtension::rotOrder, t, and T_PROP_EDIT.
Referenced by applyRotationValue(), and transdata_elem_rotate_fn().
|
static |
Definition at line 138 of file transform_mode_rotate.c.
References data, TransDataArgs_RotateTLS::rmc, TD_SKIP, and transdata_elem_rotate().
Referenced by applyRotationValue().