51 if ((
flag != ((1 << 0) | (1 << 1) | (1 << 2))) && (
flag & (1 << 1))) {
53 flag = (1 << 0) | (1 << 1) | (1 << 2);
63#define SEL_F1 (1 << 0)
64#define SEL_F2 (1 << 1)
65#define SEL_F3 (1 << 2)
71 int data_len_all_pt = 0;
82 Curve *cu =
static_cast<Curve *
>(tc->obedit->data);
87 int count = 0, countsel = 0;
88 int count_pt = 0, countsel_pt = 0;
101 for (a = 0, bezt = nu->bezt; a < nu->pntsu; a++, bezt++) {
102 if (bezt->
hide == 0) {
124 for (a = nu->pntsu * nu->pntsv, bp = nu->bp; a > 0; a--, bp++) {
141 if (((is_prop_edit && !is_prop_connected) ?
count : countsel) == 0) {
149 tc->data_len =
count;
150 data_len_pt = count_pt;
153 tc->data_len = countsel;
154 data_len_pt = countsel_pt;
160 data_len_all_pt += data_len_pt;
167 if (tc->data_len == 0) {
171 Curve *cu =
static_cast<Curve *
>(tc->obedit->data);
178 float mtx[3][3], smtx[3][3];
180 copy_m3_m4(mtx, tc->obedit->object_to_world().ptr());
188 bool has_any_selected =
false;
190 for (a = 0, bezt = nu->bezt; a < nu->pntsu; a++, bezt++) {
191 if (bezt->
hide == 0) {
196 float normal[3], plane[3];
213 has_any_selected |= bezt_tx != 0;
215 if (is_prop_edit || bezt_tx &
SEL_F1) {
217 td->loc = bezt->
vec[0];
255 if (is_prop_edit || bezt_tx &
SEL_F2) {
257 td->loc = bezt->
vec[1];
269 td->val = &(bezt->
radius);
273 td->val = &(bezt->
tilt);
274 td->ival = bezt->
tilt;
286 if ((bezt_tx &
SEL_F1) == 0 && (bezt_tx &
SEL_F3) == 0) {
288 if (hdata ==
nullptr) {
297 if (is_prop_edit || bezt_tx &
SEL_F3) {
299 td->loc = bezt->
vec[2];
324 if (hdata ==
nullptr) {
344 for (a = nu->pntsu * nu->pntsv, bp = nu->bp; a > 0; a--, bp++) {
346 if (is_prop_edit || (bp->
f1 &
SELECT)) {
352 has_any_selected |=
true;
364 td->val = &(bp->
tilt);
372 if (nu->pntsv == 1) {
373 float normal[3], plane[3];
395 if (is_prop_edit && head != tail) {
397 if (is_prop_connected && has_any_selected) {
402 for (td = head; td <= tail; td++) {
431 Curve *cu =
static_cast<Curve *
>(tc->obedit->data);
@ NURB_HANDLE_TEST_KNOT_OR_EACH
@ NURB_HANDLE_TEST_KNOT_ONLY
void BKE_nurb_handles_calc(Nurb *nu)
void BKE_nurb_bpoint_calc_plane(Nurb *nu, BPoint *bp, float r_plane[3])
short BKE_nurb_bezt_handle_test_calc_flag(const BezTriple *bezt, const eBezTriple_Flag__Alias sel_flag, const eNurbHandleTest_Mode handle_mode)
void BKE_nurb_handles_test(Nurb *nu, eNurbHandleTest_Mode handle_mode, bool use_around_local)
void BKE_curve_dimension_update(Curve *cu)
ListBase * BKE_curve_editNurbs_get(Curve *cu)
void BKE_nurb_bezt_calc_normal(Nurb *nu, BezTriple *bezt, float r_normal[3])
void BKE_nurb_bpoint_calc_normal(Nurb *nu, BPoint *bp, float r_normal[3])
void BKE_nurb_bezt_calc_plane(Nurb *nu, BezTriple *bezt, float r_plane[3])
#define LISTBASE_FOREACH(type, var, list)
void axis_dominant_v3_to_m3(float r_mat[3][3], const float normal[3])
Normal to x,y matrix.
void pseudoinverse_m3_m3(float inverse[3][3], const float mat[3][3], float epsilon)
void copy_m3_m3(float m1[3][3], const float m2[3][3])
void copy_m3_m4(float m1[3][3], const float m2[4][4])
#define PSEUDOINVERSE_EPSILON
bool invert_m3(float mat[3][3])
MINLINE void copy_v3_v3(float r[3], const float a[3])
MINLINE float normalize_v3(float n[3])
void DEG_id_tag_update(ID *id, unsigned int flags)
@ V3D_AROUND_LOCAL_ORIGINS
Read Guarded memory(de)allocation.
void *(* MEM_callocN)(size_t len, const char *str)
bool shape_key_report_if_locked(const Object *obedit, ReportList *reports)