10#define DNA_DEPRECATED_ALLOW
78#include "RNA_prototypes.hh"
103#define VALID_CONS_TARGET(ct) ((ct) && (ct->tar))
148 cob->
type = datatype;
177 cob->
type = datatype;
209 float delta[4][4], imat[4][4];
212 if (cob ==
nullptr) {
262 const bool keep_scale)
264 float diff_mat[4][4];
268 if (ob ==
nullptr || mat ==
nullptr) {
334 mul_m4_m4m4(mat, ob->object_to_world().ptr(), mat);
529 float imat[3][3], tmat[3][3];
536 if (defgroup == -1) {
540 float vec[3] = {0.0f, 0.0f, 0.0f};
541 float normal[3] = {0.0f, 0.0f, 0.0f};
542 float weightsum = 0.0f;
553 if (dw && dw->
weight > 0.0f) {
561 else if (mesh_eval) {
572 if (dw && dw->
weight > 0.0f) {
596 copy_m3_m4(imat, ob->object_to_world().ptr());
617 mul_v3_m4v3(mat[3], ob->object_to_world().ptr(), vec);
628 const float *co = dl ? dl->
verts :
nullptr;
633 float vec[3] = {0.0f, 0.0f, 0.0f}, tvec[3];
642 if (defgroup == -1) {
652 for (
i = 0;
i < tot_verts;
i++, dv++) {
655 if (dw && dw->
weight > 0.0f) {
657 memcpy(tvec, co ? co : bp->
vec,
sizeof(
float[3]));
678 mul_v3_m4v3(tvec, ob->object_to_world().ptr(), vec);
687 const char *substring,
696 if (substring[0] ==
'\0') {
730 if (headtail < 0.000001f && !(is_bbone && full_bbone)) {
746 interp_m4_m4m4(tempmat, bbone[index].mat, bbone[index + 1].mat, fac);
752 interp_v3_v3v3(loc, bbone[index].mat[3], bbone[index + 1].mat[3], fac);
758 mul_m4_m4m4(mat, ob->object_to_world().ptr(), tempmat);
761 float tempmat[4][4], loc[3];
770 mul_m4_m4m4(mat, ob->object_to_world().ptr(), tempmat);
801 CONSTRAINT_TYPE_CONSTRNAME,
802 sizeof(bConstrNameConstraint),
804 "bConstrNameConstraint",
806 constrname_id_looper,
810 constrname_flush_tars,
811 constrname_get_tarmat,
880#define SINGLETARGET_GET_TARS(con, datatar, datasubtarget, ct, list) \
882 ct = MEM_callocN<bConstraintTarget>("tempConstraintTarget"); \
885 STRNCPY_UTF8(ct->subtarget, datasubtarget); \
886 ct->space = con->tarspace; \
887 ct->flag = CONSTRAINT_TAR_TEMP; \
890 if ((ct->tar->type == OB_ARMATURE) && (ct->subtarget[0])) { \
891 bPoseChannel *pchan = BKE_pose_channel_find_name(ct->tar->pose, ct->subtarget); \
892 ct->type = CONSTRAINT_OBTYPE_BONE; \
893 ct->rotOrder = (pchan) ? (pchan->rotmode) : int(EULER_ORDER_DEFAULT); \
895 else if (OB_TYPE_SUPPORT_VGROUP(ct->tar->type) && (ct->subtarget[0])) { \
896 ct->type = CONSTRAINT_OBTYPE_VERT; \
897 ct->rotOrder = EULER_ORDER_DEFAULT; \
900 ct->type = CONSTRAINT_OBTYPE_OBJECT; \
901 ct->rotOrder = ct->tar->rotmode; \
905 BLI_addtail(list, ct); \
915#define SINGLETARGETNS_GET_TARS(con, datatar, ct, list) \
917 ct = MEM_callocN<bConstraintTarget>("tempConstraintTarget"); \
920 ct->space = con->tarspace; \
921 ct->flag = CONSTRAINT_TAR_TEMP; \
924 ct->type = CONSTRAINT_OBTYPE_OBJECT; \
926 BLI_addtail(list, ct); \
936#define SINGLETARGET_FLUSH_TARS(con, datatar, datasubtarget, ct, list, no_copy) \
939 bConstraintTarget *ctn = ct->next; \
940 if (no_copy == 0) { \
942 STRNCPY_UTF8(datasubtarget, ct->subtarget); \
943 con->tarspace = char(ct->space); \
946 BLI_freelinkN(list, ct); \
958#define SINGLETARGETNS_FLUSH_TARS(con, datatar, ct, list, no_copy) \
961 bConstraintTarget *ctn = ct->next; \
962 if (no_copy == 0) { \
964 con->tarspace = char(ct->space); \
967 BLI_freelinkN(list, ct); \
995 func(con, (
ID **)&
data->tar,
false, userdata);
1046 float inverse_matrix[4][4];
1054 float loc[3], eul[3],
size[3];
1055 float loco[3], eulo[3], sizeo[3];
1068 loc[0] = loco[0] = 0.0f;
1071 loc[1] = loco[1] = 0.0f;
1074 loc[2] = loco[2] = 0.0f;
1077 eul[0] = eulo[0] = 0.0f;
1080 eul[1] = eulo[1] = 0.0f;
1083 eul[2] = eulo[2] = 0.0f;
1086 size[0] = sizeo[0] = 1.0f;
1089 size[1] = sizeo[1] = 1.0f;
1092 size[2] = sizeo[2] = 1.0f;
1103 if (cob->
pchan !=
nullptr) {
1114 if (orig_con !=
nullptr) {
1125 float orig_cob_matrix[4][4];
1133 cob->
matrix[3][0] = orig_cob_matrix[3][0];
1136 cob->
matrix[3][1] = orig_cob_matrix[3][1];
1139 cob->
matrix[3][2] = orig_cob_matrix[3][2];
1149 "bChildOfConstraint",
1175 func(con, (
ID **)&
data->tar,
false, userdata);
1221 const float target_up[3],
1276 if (axis != upflag) {
1277 right_index = 3 - axis - upflag;
1281 m[right_index][0] = neg * right[0];
1282 m[right_index][1] = neg * right[1];
1283 m[right_index][2] = neg * right[2];
1301 float size[3], vec[3];
1324 std::clamp<short>(
data->reserved1, 0, 5),
1325 std::clamp<short>(
data->reserved2, 0, 2),
1337 "bTrackToConstraint",
1354 data->weight = 1.0f;
1355 data->orientweight = 1.0f;
1356 data->iterations = 500;
1366 func(con, (
ID **)&
data->tar,
false, userdata);
1369 func(con, (
ID **)&
data->poletar,
false, userdata);
1429 if (ob ==
nullptr) {
1447 "bKinematicConstraint",
1467 data->followflag = 0;
1475 func(con, (
ID **)&
data->tar,
false, userdata);
1518 float vec[4], radius;
1527 if (ct->
tar->
runtime->curve_cache ==
nullptr ||
1528 ct->
tar->
runtime->curve_cache->anim_path_accum_length ==
nullptr)
1536 curvetime =
data->offset_fac;
1553 CLAMP(curvetime, 0.0f, 1.0f);
1573 quat, std::clamp<short>(
data->trackflag, 0, 5), std::clamp<short>(
data->upflag, 0, 2));
1578 float tmat[4][4], rmat[4][4];
1634 "bFollowPathConstraint",
1674 N_(
"Limit Location"),
1675 "bLocLimitConstraint",
1694 return ((
b - std::floor(
b)) - 0.5) * (2.0 *
M_PI);
1729 if (min_wrapped < max_wrapped) {
1730 return angle + std::clamp(0.0f, min_wrapped, max_wrapped);
1735 if (max_wrapped >= 0.0 || min_wrapped <= 0.0) {
1740 if (std::fabs(max_wrapped) < std::fabs(min_wrapped)) {
1741 return angle + max_wrapped;
1743 return angle + min_wrapped;
1767 rot_order =
data->euler_order;
1821 N_(
"Limit Rotation"),
1822 "bRotLimitConstraint",
1838 float obsize[3],
size[3];
1878 "bSizeLimitConstraint",
1903 func(con, (
ID **)&
data->tar,
false, userdata);
1938 float offset[3] = {0.0f, 0.0f, 0.0f};
1950 cob->
matrix[3][0] += offset[0];
1958 cob->
matrix[3][1] += offset[1];
1966 cob->
matrix[3][2] += offset[2];
1974 N_(
"Copy Location"),
1975 "bLocateLikeConstraint",
2000 func(con, (
ID **)&
data->tar,
false, userdata);
2035 float loc[3],
size[3], oldrot[3][3], newrot[3][3];
2036 float eul[3], obeul[3], defeul[3];
2044 rot_order =
data->euler_order;
2060 bool legacy_offset =
false;
2062 switch (
data->mix_mode) {
2064 legacy_offset =
true;
2080 if (legacy_offset) {
2093 if (legacy_offset) {
2106 if (legacy_offset) {
2126 switch (
data->mix_mode) {
2151 N_(
"Copy Rotation"),
2152 "bRotateLikeConstraint",
2178 func(con, (
ID **)&
data->tar,
false, userdata);
2213 float obsize[3],
size[3];
2223 if ((
data->flag & all_axes) == all_axes) {
2248 for (
int i = 0;
i < 3;
i++) {
2282 "bSizeLikeConstraint",
2300 func(con, (
ID **)&
data->tar,
false, userdata);
2335 float target_mat[4][4];
2346 switch (
data->mix_mode) {
2387 N_(
"Copy Transforms"),
2388 "bTransLikeConstraint",
2406 data->volume = 1.0f;
2413 float volume =
data->volume;
2414 float fac = 1.0f, total_scale = 1.0f;
2420 switch (
data->mode) {
2422 total_scale = obsize[0] * obsize[1] * obsize[2];
2425 total_scale =
pow3f(obsize[
data->free_axis]);
2428 total_scale = obsize[
data->free_axis];
2432 if (total_scale != 0) {
2433 fac =
sqrtf(volume / total_scale);
2437 switch (
data->free_axis) {
2456 N_(
"Maintain Volume"),
2457 "bSameVolumeConstraint",
2491 *list =
data->targets;
2505 func(con, (
ID **)&ct->tar,
false, userdata);
2522 if (pchan ==
nullptr) {
2532 const float iobmat[4][4],
2533 const float basemat[4][4],
2534 const float bonemat[4][4],
2535 const float pivot[3],
2537 float r_sum_mat[4][4],
2540 if (weight == 0.0f) {
2549 if (r_sum_dq !=
nullptr) {
2550 float basemat_world[4][4];
2569 const bool force_envelope,
2571 float r_sum_mat[4][4],
2574 float iobmat[4][4], co[3];
2576 float weight = ct->
weight;
2592 float basemat[4][4];
2599 if (r_sum_dq !=
nullptr) {
2607 b_bone_mats[index + 1].
mat,
2609 weight * (1.0f -
blend),
2613 if (r_sum_dq !=
nullptr) {
2621 b_bone_mats[index + 2].
mat,
2640 *r_totweight += weight;
2648 float sum_mat[4][4] = {};
2650 float weight = 0.0f;
2660 mul_m4_v3(cob->
ob->object_to_world().ptr(), input_co);
2669 if (ct->weight <= 0.0f) {
2680 if (pchan ==
nullptr || pchan->
bone ==
nullptr) {
2688 if (weight > 0.0f) {
2689 if (pdq !=
nullptr) {
2706 "bArmatureConstraint",
2735 func(con, (
ID **)&
data->tar,
false, userdata);
2738 func(con, (
ID **)&
data->act,
true, userdata);
2789 float tempmat[4][4], vec[3];
2794 if (use_eval_time) {
2795 s =
data->eval_time;
2814 if (
data->type < 10) {
2820 else if (
data->type < 20) {
2823 axis =
data->type - 10;
2828 axis =
data->type - 20;
2837 const float range =
data->max -
data->min;
2838 if ((range == 0.0f) || (
ushort(axis) > 2)) {
2842 s = (vec[axis] -
data->min) / range;
2851 printf(
"do Action Constraint %s - Ob %s Pchan %s\n",
2867 data->action_slot_handle,
2869 &anim_eval_context);
2874 bPose pose = {{
nullptr}};
2890 data->action_slot_handle,
2892 &anim_eval_context);
2903 puts(
"Error: unknown owner type for Action Constraint");
2916 switch (
data->mix_mode) {
2959 "bActionConstraint",
2985 func(con, (
ID **)&
data->tar,
false, userdata);
3020 float vec[3], vec2[3];
3028 switch (
data->lockflag) {
3031 switch (
data->trackflag) {
3099 switch (
data->trackflag) {
3167 switch (
data->trackflag) {
3243 totmat[0][0] = tmpmat[0][0];
3244 totmat[0][1] = tmpmat[0][1];
3245 totmat[0][2] = tmpmat[0][2];
3246 totmat[1][0] = tmpmat[1][0];
3247 totmat[1][1] = tmpmat[1][1];
3248 totmat[1][2] = tmpmat[1][2];
3249 totmat[2][0] = tmpmat[2][0];
3250 totmat[2][1] = tmpmat[2][1];
3251 totmat[2][2] = tmpmat[2][2];
3275 "bLockTrackConstraint",
3300 func(con, (
ID **)&
data->tar,
false, userdata);
3336 float dvec[3], dist, sfac = 1.0f;
3337 short clamp_surf = 0;
3343 if (
data->dist == 0) {
3349 if (orig_con !=
nullptr) {
3359 if (dist <= data->dist) {
3362 sfac =
data->dist / dist;
3367 if (dist <= (
data->dist +
data->soft)) {
3374 if (dist >=
data->dist) {
3377 sfac =
data->dist / dist;
3383 if (dist >= (
data->dist -
data->soft)) {
3397 sfac =
data->dist / dist;
3416 N_(
"Limit Distance"),
3417 "bDistLimitConstraint",
3436 data->orglength = 0.0;
3438 data->bulge_max = 1.0f;
3439 data->bulge_min = 1.0f;
3447 func(con, (
ID **)&
data->tar,
false, userdata);
3483 float size[3], scale[3], vec[3], xx[3], zz[3],
orth[3];
3511 if (
data->orglength == 0) {
3512 data->orglength = dist;
3517 if (orig_con !=
nullptr) {
3524 scale[1] = dist /
data->orglength;
3530 float bulge_max =
max_ff(
data->bulge_max, 1.0f);
3531 float hard =
min_ff(bulge, bulge_max);
3533 float range = bulge_max - 1.0f;
3534 float scale_fac = (range > 0.0f) ? 1.0f / range : 0.0f;
3535 float soft = 1.0f + range *
atanf((bulge - 1.0f) * scale_fac) /
float(
M_PI_2);
3542 float bulge_min = std::clamp(
data->bulge_min, 0.0f, 1.0f);
3543 float hard =
max_ff(bulge, bulge_min);
3545 float range = 1.0f - bulge_min;
3546 float scale_fac = (range > 0.0f) ? 1.0f / range : 0.0f;
3547 float soft = 1.0f - range *
atanf((1.0f - bulge) * scale_fac) /
float(
M_PI_2);
3553 switch (
data->volmode) {
3556 scale[0] =
sqrtf(bulge);
3557 scale[2] = scale[0];
3579 switch (
data->plane) {
3626 "bStretchToConstraint",
3644 data->offset = 0.0f;
3653 func(con, (
ID **)&
data->tar,
false, userdata);
3689 float obmat[4][4], imat[4][4], tarmat[4][4], tmat[4][4];
3704 switch (
data->minmaxflag) {
3706 val1 = tarmat[3][2];
3707 val2 = obmat[3][2] -
data->offset;
3711 val1 = tarmat[3][1];
3712 val2 = obmat[3][1] -
data->offset;
3716 val1 = tarmat[3][0];
3717 val2 = obmat[3][0] -
data->offset;
3721 val2 = tarmat[3][2];
3722 val1 = obmat[3][2] -
data->offset;
3726 val2 = tarmat[3][1];
3727 val1 = obmat[3][1] -
data->offset;
3731 val2 = tarmat[3][0];
3732 val1 = obmat[3][0] -
data->offset;
3740 obmat[3][index] = tarmat[3][index] +
data->offset;
3757 "bMinMaxConstraint",
3775 func(con, (
ID **)&
data->tar,
false, userdata);
3825 float obmat[4][4], ownLoc[3];
3826 float curveMin[3], curveMax[3];
3827 float targetMatrix[4][4];
3840 if (
data->tar->runtime->curve_cache &&
data->tar->runtime->curve_cache->anim_path_accum_length)
3842 float vec[4], totmat[4][4];
3867 clamp_axis =
data->flag - 1;
3873 float len = (curveMax[clamp_axis] - curveMin[clamp_axis]);
3879 if (ownLoc[clamp_axis] < curveMin[clamp_axis]) {
3881 offset = curveMin[clamp_axis] -
3882 ceilf((curveMin[clamp_axis] - ownLoc[clamp_axis]) /
len) *
len;
3886 curvetime = (ownLoc[clamp_axis] - offset) / (
len);
3888 else if (ownLoc[clamp_axis] > curveMax[clamp_axis]) {
3890 offset = curveMax[clamp_axis] +
3891 int((ownLoc[clamp_axis] - curveMax[clamp_axis]) /
len) *
len;
3895 curvetime = (ownLoc[clamp_axis] - offset) / (
len);
3899 curvetime = (ownLoc[clamp_axis] - curveMin[clamp_axis]) / (
len);
3909 if (ownLoc[clamp_axis] <= curveMin[clamp_axis]) {
3912 else if (ownLoc[clamp_axis] >= curveMax[clamp_axis]) {
3915 else if (
IS_EQF((curveMax[clamp_axis] - curveMin[clamp_axis]), 0.0f) ==
false) {
3916 curvetime = (ownLoc[clamp_axis] - curveMin[clamp_axis]) /
3917 (curveMax[clamp_axis] - curveMin[clamp_axis]);
3929 mul_m4_m4m4(targetMatrix, ct->
tar->object_to_world().ptr(), totmat);
3942 "bClampToConstraint",
3963 for (
int i = 0;
i < 3;
i++) {
3964 data->from_min_scale[
i] =
data->from_max_scale[
i] = 1.0f;
3965 data->to_min_scale[
i] =
data->to_max_scale[
i] = 1.0f;
3974 func(con, (
ID **)&
data->tar,
false, userdata);
4010 float *from_min, *from_max, *to_min, *to_max;
4011 float loc[3],
rot[3][3], oldeul[3],
size[3];
4012 float newloc[3], newrot[3][3], neweul[3], newsize[3];
4013 float dbuf[4], sval[3];
4014 float *
const dvec = dbuf + 1;
4017 switch (
data->from) {
4028 from_min =
data->from_min_scale;
4029 from_max =
data->from_max_scale;
4034 from_min =
data->from_min_rot;
4035 from_max =
data->from_max_rot;
4040 from_min =
data->from_min;
4041 from_max =
data->from_max;
4049 rot_order =
data->to_euler_order;
4057 for (
int i = 0;
i < 3;
i++) {
4058 if (from_max[
i] - from_min[
i]) {
4059 sval[
i] = (dvec[
i] - from_min[
i]) / (from_max[
i] - from_min[
i]);
4068 for (
int i = 0;
i < 3;
i++) {
4069 CLAMP(dvec[
i], from_min[
i], from_max[
i]);
4070 if (from_max[
i] - from_min[
i]) {
4071 sval[
i] = (dvec[
i] - from_min[
i]) / (from_max[
i] - from_min[
i]);
4082 to_min =
data->to_min_scale;
4083 to_max =
data->to_max_scale;
4084 for (
int i = 0;
i < 3;
i++) {
4085 newsize[
i] = to_min[
i] + (sval[int(
data->map[
i])] * (to_max[
i] - to_min[
i]));
4087 switch (
data->mix_mode_scale) {
4098 to_min =
data->to_min_rot;
4099 to_max =
data->to_max_rot;
4100 for (
int i = 0;
i < 3;
i++) {
4101 neweul[
i] = to_min[
i] + (sval[int(
data->map[
i])] * (to_max[
i] - to_min[
i]));
4103 switch (
data->mix_mode_rot) {
4125 to_min =
data->to_min;
4126 to_max =
data->to_max;
4127 for (
int i = 0;
i < 3;
i++) {
4128 newloc[
i] = (to_min[
i] + (sval[int(
data->map[
i])] * (to_max[
i] - to_min[
i])));
4130 switch (
data->mix_mode_loc) {
4150 N_(
"Transformation"),
4151 "bTransformConstraint",
4169 func(con, (
ID **)&
data->target,
false, userdata);
4217 float co[3] = {0.0f, 0.0f, 0.0f};
4218 bool track_normal =
false;
4219 float track_no[3] = {0.0f, 0.0f, 0.0f};
4250 if (nearest.
index < 0) {
4256 if (do_track_normal) {
4257 track_normal =
true;
4259 &
tree,
nullptr, nearest.
index, nearest.
co, nearest.
no, track_no);
4278 co, co, nearest.
co, (dist - scon->
dist) / dist);
4289 float no[3] = {0.0f, 0.0f, 0.0f};
4338 if (hit.
index < 0) {
4343 if (do_track_normal) {
4344 track_normal =
true;
4388 "bShrinkwrapConstraint",
4413 func(con, (
ID **)&
data->tar,
false, userdata);
4477 float rmat[3][3], tmat[4][4];
4512 if (
norm < FLT_EPSILON) {
4533 else if (
norm < 0.1f) {
4555 "bDampTrackConstraint",
4591 data->bulge_max = 1.0f;
4592 data->bulge_min = 1.0f;
4603 func(con, (
ID **)&
data->tar,
false, userdata);
4649 "bSplineIKConstraint",
4667 func(con, (
ID **)&
data->tar,
false, userdata);
4701 float pivot[3], vec[3];
4705 float axis[3],
angle;
4707 const int rot_axis = std::clamp(
4721 if (
rot[rot_axis] > 0.0f) {
4795 data->clip =
nullptr;
4803 func(con, (
ID **)&
data->clip,
true, userdata);
4804 func(con, (
ID **)&
data->camera,
false, userdata);
4805 func(con, (
ID **)&
data->depth_ob,
false, userdata);
4826 if (
data->object[0]) {
4836 if (
data->camera ==
nullptr) {
4841 return data->camera;
4869 context->flag =
data->flag;
4870 context->frame_method =
data->frame_method;
4873 context->scene = cob->
scene;
4877 if (context->clip ==
nullptr || context->camera_object ==
nullptr) {
4880 context->depth_object =
data->depth_ob;
4882 context->tracking = &context->clip->tracking;
4884 if (context->tracking_object ==
nullptr) {
4889 if (context->track ==
nullptr) {
4893 context->depsgraph_time =
DEG_get_ctime(context->depsgraph);
4895 context->depsgraph_time);
4903 Object *camera_object = context->camera_object;
4913 float camera_obmat[4][4];
4914 copy_m4_m4(camera_obmat, camera_object->object_to_world().ptr());
4917 float reconstructed_camera_mat[4][4];
4919 tracking, tracking_object, context->clip_frame, reconstructed_camera_mat);
4920 float reconstructed_camera_mat_inv[4][4];
4921 invert_m4_m4(reconstructed_camera_mat_inv, reconstructed_camera_mat);
4930 Object *camera_object = context->camera_object;
4937 float reconstructed_camera_mat[4][4];
4961 const int clip_width,
4962 const int clip_height,
4963 float marker_position[2])
4970 marker_position[0] *= clip_width;
4971 marker_position[1] *= clip_height;
4974 context->tracking, clip_width, clip_height, marker_position, marker_position);
4977 marker_position[0] /= clip_width;
4978 marker_position[1] /= clip_height;
4983 const int clip_width,
4984 const int clip_height,
4985 float marker_position[2])
4991 Scene *scene = context->scene;
4995 const float w_src = clip_width * clip->
aspx;
4996 const float h_src = clip_height * clip->
aspy;
4998 const float w_dst = scene->
r.
xsch * scene->
r.
xasp;
4999 const float h_dst = scene->
r.
ysch * scene->
r.
yasp;
5001 const float asp_src = w_src / h_src;
5002 const float asp_dst = w_dst / h_dst;
5004 if (
fabsf(asp_src - asp_dst) < FLT_EPSILON) {
5010 float div = asp_src / asp_dst;
5011 float cent =
float(clip_width) / 2.0f;
5013 marker_position[0] = (((marker_position[0] * clip_width - cent) * div) + cent) / clip_width;
5017 float div = asp_dst / asp_src;
5018 float cent =
float(clip_height) / 2.0f;
5020 marker_position[1] = (((marker_position[1] * clip_height - cent) * div) + cent) / clip_height;
5029 Object *camera_object = context->camera_object;
5031 float camera_matrix[4][4];
5034 const float z_axis[3] = {0.0f, 0.0f, 1.0f};
5037 float camera_axis[3];
5045 float projection[3];
5048 return len_v3(projection);
5055 if (context->depth_object ==
nullptr) {
5059 Object *depth_object = context->depth_object;
5061 if (depth_mesh ==
nullptr) {
5065 float depth_object_mat_inv[4][4];
5066 invert_m4_m4(depth_object_mat_inv, depth_object->object_to_world().ptr());
5068 float ray_start[3], ray_end[3];
5070 ray_start, depth_object_mat_inv, context->camera_object->object_to_world().location());
5073 float ray_direction[3];
5098 Scene *scene = context->scene;
5101 Object *camera_object = context->camera_object;
5102 const float clip_frame = context->clip_frame;
5106 if (object_depth < FLT_EPSILON) {
5110 int clip_width, clip_height;
5113 float marker_position[2];
5126 vec[0] =
params.ortho_scale * (marker_position[0] - 0.5f +
params.shiftx);
5127 vec[1] =
params.ortho_scale * (marker_position[1] - 0.5f +
params.shifty);
5128 vec[2] = -object_depth;
5130 if (aspect > 1.0f) {
5138 mul_v3_m4v3(disp, camera_object->object_to_world().ptr(), vec);
5140 copy_m4_m4(rmat, camera_object->object_to_world().ptr());
5147 const float d = (object_depth *
params.sensor_x) / (2.0f *
params.lens);
5150 vec[0] = d * (2.0f * (marker_position[0] +
params.shiftx) - 1.0f);
5151 vec[1] = d * (2.0f * (marker_position[1] +
params.shifty) - 1.0f);
5152 vec[2] = -object_depth;
5154 if (aspect > 1.0f) {
5162 mul_v3_m4v3(disp, camera_object->object_to_world().ptr(), vec);
5165 copy_m4_m4(rmat, camera_object->object_to_world().ptr());
5195 "bFollowTrackConstraint",
5212 data->clip =
nullptr;
5220 func(con, (
ID **)&
data->clip,
true, userdata);
5235 float mat[4][4], obmat[4][4];
5252 N_(
"Camera Solver"),
5253 "bCameraSolverConstraint",
5270 data->clip =
nullptr;
5279 func(con, (
ID **)&
data->clip,
false, userdata);
5280 func(con, (
ID **)&
data->camera,
false, userdata);
5294 if (!camob || !clip) {
5300 if (!tracking_object) {
5304 float mat[4][4], obmat[4][4], imat[4][4], parmat[4][4];
5311 mul_m4_m4m4(parmat, camob->object_to_world().ptr(), imat);
5324 if (orig_con !=
nullptr) {
5338 N_(
"Object Solver"),
5339 "bObjectSolverConstraint",
5355 func(con, (
ID **)&
data->cache_file,
true, userdata);
5360#if defined(WITH_ALEMBIC) || defined(WITH_USD)
5372 cache_file,
double(frame), scene->frames_per_second());
5379 switch (cache_file->
type) {
5388 data->reader, cob->
matrix, time * scene->frames_per_second(), cache_file->
scale);
5418 data->reader_object_path[0] =
'\0';
5426 data->cache_file =
nullptr;
5432 N_(
"Transform Cache"),
5433 "bTransformCacheConstraint",
5468 switch (data_type) {
5484 switch (data_type) {
5503 return component->attribute_domain_size(domain) != 0;
5521 return geometry.get_component(src_type);
5537 func(con, (
ID **)&
data->target,
false, userdata);
5556 if (!con || !list) {
5569 if (!con || !list) {
5601 if (component ==
nullptr) {
5605 const std::optional<bke::AttributeAccessor> optional_attributes = component->
attributes();
5606 if (!optional_attributes.has_value()) {
5617 const int index = std::clamp<int>(acon->
sample_index, 0, attribute.
size() - 1);
5642 float target_mat[4][4];
5650 float prev_location[3];
5651 float prev_rotation[3][3];
5655 float next_location[3];
5656 float next_rotation[3][3];
5660 switch (
data->data_type) {
5687 switch (
data->mix_mode) {
5707 if (
data->apply_target_transform) {
5715 N_(
"Geometry Attribute"),
5716 "bGeometryAttributeConstraint",
5787 CLOG_WARN(&
LOG,
"No valid constraint type-info data available. Type = %i", type);
5817 if (*idpoin && is_reference) {
5899 const short type = con->
type;
5929 ListBase single_con = {new_con, new_con};
5983 single_con.
first = new_con;
5984 single_con.
last = new_con;
6040 const char *newName;
6156 if (pchan ==
nullptr) {
6207 if ((*idpoin) && (is_reference)) {
6216 const bool do_extern)
6253 if (pchan ==
nullptr) {
6279 srccon = srccon->
next, con = con->
next)
6321 if (con_iter == con) {
6352 if (r_pchan !=
nullptr) {
6362 if (ob->
pose !=
nullptr) {
6367 if (r_pchan !=
nullptr) {
6387 if (
ELEM(orig_ob,
nullptr, ob)) {
6394 if (pchan !=
nullptr) {
6397 if (orig_pchan ==
nullptr) {
6417 if (r_orig_ob !=
nullptr) {
6418 *r_orig_ob = orig_ob;
6435 Object *orig_ob =
nullptr;
6438 if (orig_con !=
nullptr) {
6520 ListBase targets = {
nullptr,
nullptr};
6527 cob->
type = ownertype;
6530 switch (ownertype) {
6534 cob->
pchan =
nullptr;
6652 if (cob ==
nullptr) {
6659 ListBase targets = {
nullptr,
nullptr};
6662 if (cti ==
nullptr) {
6673 if (con->enforce == 0.0f) {
6720 float solution[4][4];
6733 if (cti && con->data) {
6738 switch (con->type) {
6782 con->data =
nullptr;
6787 if (con->data ==
nullptr) {
6796 switch (con->type) {
6813 con->lin_error = 0.0f;
6814 con->rot_error = 0.0f;
6822 data->reader =
nullptr;
6823 data->reader_object_path[0] =
'\0';
void ABC_get_transform(struct CacheReader *reader, float r_mat_world[4][4], double time, float scale)
void BIK_clear_data(struct bPose *pose)
Blender kernel action and pose functionality.
void BKE_pose_free_data(bPose *pose) ATTR_NONNULL(1)
void what_does_obaction(Object *ob, Object *workob, bPose *pose, bAction *act, int32_t action_slot_handle, char groupname[], const AnimationEvalContext *anim_eval_context) ATTR_NONNULL(1
bPoseChannel * BKE_pose_channel_find_name(const bPose *pose, const char *name)
bPoseChannel * BKE_pose_channel_ensure(bPose *pose, const char *name) ATTR_NONNULL(2)
bool BKE_where_on_path(const struct Object *ob, float ctime, float r_vec[4], float r_dir[3], float r_quat[4], float *r_radius, float *r_weight)
AnimationEvalContext BKE_animsys_eval_context_construct(struct Depsgraph *depsgraph, float eval_time) ATTR_WARN_UNUSED_RESULT
bool BKE_animdata_drivers_remove_for_rna_struct(struct ID &owner_id, struct StructRNA &type, void *data)
void BKE_pchan_bbone_deform_segment_index(const bPoseChannel *pchan, const float *co, int *r_index, float *r_blend_next)
float distfactor_to_bone(const blender::float3 &position, const blender::float3 &head, const blender::float3 &tail, float radius_head, float radius_tail, float falloff_distance)
void BKE_pchan_calc_mat(bPoseChannel *pchan)
void BKE_pchan_apply_mat4(bPoseChannel *pchan, const float mat[4][4], bool use_compat)
void BKE_armature_mat_bone_to_pose(const bPoseChannel *pchan, const float inmat[4][4], float outmat[4][4])
void BKE_armature_mat_pose_to_bone(const bPoseChannel *pchan, const float inmat[4][4], float outmat[4][4])
void BKE_pchan_bbone_deform_clamp_segment_index(const bPoseChannel *pchan, float head_tail, int *r_index, float *r_blend_next)
void BKE_cachefile_reader_free(CacheFile *cache_file, CacheReader **reader)
double BKE_cachefile_time_offset(const CacheFile *cache_file, double time, double fps)
void BKE_cachefile_reader_open(CacheFile *cache_file, CacheReader **reader, Object *object, const char *object_path)
Camera data-block and utility functions.
void BKE_camera_params_init(CameraParams *params)
void BKE_camera_params_from_object(CameraParams *params, const struct Object *cam_ob)
void(* ConstraintIDFunc)(struct bConstraint *con, struct ID **idpoin, bool is_reference, void *userdata)
void * CustomData_bmesh_get(const CustomData *data, void *block, eCustomDataType type)
bool CustomData_has_layer(const CustomData *data, eCustomDataType type)
display list (or rather multi purpose list) stuff.
DispList * BKE_displist_find(struct ListBase *lb, int type)
BMEditMesh * BKE_editmesh_from_object(Object *ob)
Return the BMEditMesh for a given object.
void BKE_driver_target_matrix_to_rot_channels(float mat[4][4], int auto_order, int rotation_mode, int channel, bool angles, float r_buf[4])
void id_lib_extern(ID *id)
@ LIB_ID_COPY_NO_LIB_OVERRIDE_LOCAL_DATA_FLAG
@ LIB_ID_CREATE_NO_USER_REFCOUNT
float BKE_movieclip_remap_scene_to_clip_frame(const struct MovieClip *clip, float framenr)
void BKE_movieclip_get_size(struct MovieClip *clip, const struct MovieClipUser *user, int *r_width, int *r_height)
General operations, lookup, etc. for blender objects.
void BKE_object_where_is_calc_mat4(const Object *ob, float r_obmat[4][4])
void BKE_object_apply_mat4(Object *ob, const float mat[4][4], bool use_compat, bool use_parent)
Mesh * BKE_object_get_evaluated_mesh(const Object *object_eval)
std::optional< blender::Bounds< blender::float3 > > BKE_object_boundbox_get(const Object *ob)
void BKE_object_to_mat4(const Object *ob, float r_mat[4][4])
float BKE_scene_frame_get(const Scene *scene)
bool BKE_shrinkwrap_project_normal(char options, const float vert[3], const float dir[3], float ray_radius, const SpaceTransform *transf, ShrinkwrapTreeData *tree, BVHTreeRayHit *hit)
void BKE_shrinkwrap_free_tree(ShrinkwrapTreeData *data)
void BKE_shrinkwrap_snap_point_to_surface(const ShrinkwrapTreeData *tree, const SpaceTransform *transform, int mode, int hit_idx, const float hit_co[3], const float hit_no[3], float goal_dist, const float point_co[3], float r_point_co[3])
void BKE_shrinkwrap_compute_smooth_normal(const ShrinkwrapTreeData *tree, const SpaceTransform *transform, int tri_idx, const float hit_co[3], const float hit_no[3], float r_no[3])
bool BKE_shrinkwrap_init_tree(ShrinkwrapTreeData *data, Mesh *mesh, int shrinkType, int shrinkMode, bool force_normals)
void BKE_shrinkwrap_find_nearest_surface(ShrinkwrapTreeData *tree, BVHTreeNearest *nearest, float co[3], int type)
struct MovieTrackingObject * BKE_tracking_object_get_camera(const struct MovieTracking *tracking)
void BKE_tracking_get_camera_object_matrix(const struct Object *camera_object, float mat[4][4])
struct MovieTrackingObject * BKE_tracking_object_get_named(struct MovieTracking *tracking, const char *name)
struct MovieTrackingTrack * BKE_tracking_object_find_track_with_name(struct MovieTrackingObject *tracking_object, const char *name)
void BKE_tracking_marker_get_subframe_position(struct MovieTrackingTrack *track, float framenr, float pos[2])
void BKE_tracking_undistort_v2(struct MovieTracking *tracking, int image_width, int image_height, const float co[2], float r_co[2])
void BKE_tracking_camera_get_reconstructed_interpolate(struct MovieTracking *tracking, struct MovieTrackingObject *tracking_object, float framenr, float mat[4][4])
#define BLI_assert_unreachable()
#define BLI_assert_msg(a, msg)
#define BUFFER_FOR_CPP_TYPE_VALUE(type, variable_name)
#define BVH_RAYCAST_DIST_MAX
int BLI_bvhtree_ray_cast(const BVHTree *tree, const float co[3], const float dir[3], float radius, BVHTreeRayHit *hit, BVHTree_RayCastCallback callback, void *userdata)
int BLI_findindex(const ListBase *listbase, const void *vlink) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
void * BLI_findlink(const ListBase *listbase, int number) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
#define LISTBASE_FOREACH(type, var, list)
BLI_INLINE void BLI_listbase_clear(ListBase *lb)
void * BLI_findstring(const ListBase *listbase, const char *id, int offset) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
void BLI_freelinkN(ListBase *listbase, void *vlink) ATTR_NONNULL(1)
void void BLI_freelistN(ListBase *listbase) ATTR_NONNULL(1)
void BLI_addtail(ListBase *listbase, void *vlink) ATTR_NONNULL(1)
int BLI_listbase_count(const ListBase *listbase) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
void void void void void void BLI_duplicatelist(ListBase *dst, const ListBase *src) ATTR_NONNULL(1
MINLINE float max_ff(float a, float b)
MINLINE float clamp_f(float value, float min, float max)
MINLINE float min_ff(float a, float b)
MINLINE float square_f(float a)
MINLINE float pow3f(float x)
MINLINE float interpf(float target, float origin, float t)
float mat4_to_volume_scale(const float mat[4][4])
void BLI_space_transform_from_matrices(struct SpaceTransform *data, const float local[4][4], const float target[4][4])
void interp_m4_m4m4(float R[4][4], const float A[4][4], const float B[4][4], float t)
void mul_m3_v3(const float M[3][3], float r[3])
void madd_m4_m4m4fl(float R[4][4], const float A[4][4], const float B[4][4], float f)
void mul_m4_fl(float R[4][4], float f)
void mul_m4_m4m4(float R[4][4], const float A[4][4], const float B[4][4])
void BLI_space_transform_apply(const struct SpaceTransform *data, float co[3])
void copy_m3_m3(float m1[3][3], const float m2[3][3])
void unit_m3(float m[3][3])
void copy_m3_m4(float m1[3][3], const float m2[4][4])
bool invert_m3_m3(float inverse[3][3], const float mat[3][3])
void loc_rot_size_to_mat4(float R[4][4], const float loc[3], const float rot[3][3], const float size[3])
void mat4_to_loc_rot_size(float loc[3], float rot[3][3], float size[3], const float wmat[4][4])
void translate_m4(float mat[4][4], float Tx, float Ty, float Tz)
void normalize_m3(float R[3][3]) ATTR_NONNULL()
void rescale_m4(float mat[4][4], const float scale[3])
void loc_eulO_size_to_mat4(float R[4][4], const float loc[3], const float eul[3], const float size[3], short order)
void mul_m4_v3(const float M[4][4], float r[3])
void invert_m4_m4_safe(float inverse[4][4], const float mat[4][4])
void orthogonalize_m4_stable(float R[4][4], int axis, bool normalize)
#define mul_m4_series(...)
void scale_m4_fl(float R[4][4], float scale)
void mul_m4_m4m4_split_channels(float R[4][4], const float A[4][4], const float B[4][4])
void normalize_m4_ex(float R[4][4], float r_scale[3]) ATTR_NONNULL()
void copy_m4_m4(float m1[4][4], const float m2[4][4])
void mul_v3_m4v3(float r[3], const float mat[4][4], const float vec[3])
bool is_negative_m4(const float mat[4][4])
bool invert_m4_m4(float inverse[4][4], const float mat[4][4])
void mul_m4_m4m4_aligned_scale(float R[4][4], const float A[4][4], const float B[4][4])
bool invert_m4(float mat[4][4])
void BLI_space_transform_invert_normal(const struct SpaceTransform *data, float no[3])
void mat4_to_size(float size[3], const float M[4][4])
void transpose_m3(float R[3][3])
void BLI_space_transform_invert(const struct SpaceTransform *data, float co[3])
float determinant_m3(float a1, float a2, float a3, float b1, float b2, float b3, float c1, float c2, float c3)
void mul_m3_m3m3(float R[3][3], const float A[3][3], const float B[3][3])
void mul_m4_m3m4(float R[4][4], const float A[3][3], const float B[4][4])
void mul_v3_mat3_m4v3(float r[3], const float mat[4][4], const float vec[3])
void mul_mat3_m4_v3(const float mat[4][4], float r[3])
void normalize_m4(float R[4][4]) ATTR_NONNULL()
void unit_m4(float m[4][4])
void rotate_eulO(float beul[3], short order, char axis, float angle)
void axis_angle_normalized_to_mat3(float R[3][3], const float axis[3], float angle)
void mat4_to_eul(float eul[3], const float mat[4][4])
void quat_to_mat4(float m[4][4], const float q[4])
void dquat_to_mat4(float R[4][4], const DualQuat *dq)
void mat4_to_eulO(float eul[3], short order, const float m[4][4])
void mat4_to_dquat(DualQuat *dq, const float basemat[4][4], const float mat[4][4])
void compatible_eul(float eul[3], const float oldrot[3])
void quat_apply_track(float quat[4], short axis, short upflag)
void eulO_to_mat3(float M[3][3], const float e[3], short order)
void add_weighted_dq_dq_pivot(DualQuat *dq_sum, const DualQuat *dq, const float pivot[3], float weight, bool compute_scale_matrix)
void normalize_dq(DualQuat *dq, float totweight)
void mat3_to_eulO(float eul[3], short order, const float m[3][3])
void mat3_normalized_to_axis_angle(float axis[3], float *angle, const float mat[3][3])
void mat4_to_compatible_eulO(float eul[3], const float oldrot[3], short order, const float mat[4][4])
MINLINE float len_squared_v3(const float v[3]) ATTR_WARN_UNUSED_RESULT
MINLINE float len_v3v3(const float a[3], const float b[3]) ATTR_WARN_UNUSED_RESULT
MINLINE void madd_v3_v3fl(float r[3], const float a[3], float f)
MINLINE void add_v3_fl(float r[3], float f)
MINLINE void mul_v3_v3(float r[3], const float a[3])
MINLINE void sub_v3_v3(float r[3], const float a[3])
MINLINE void sub_v3_v3v3(float r[3], const float a[3], const float b[3])
MINLINE void mul_v3_fl(float r[3], float f)
MINLINE void copy_v3_v3(float r[3], const float a[3])
MINLINE void negate_v3_v3(float r[3], const float a[3])
void project_v3_v3v3(float out[3], const float p[3], const float v_proj[3])
MINLINE float dot_v3v3(const float a[3], const float b[3]) ATTR_WARN_UNUSED_RESULT
void interp_v3_v3v3(float r[3], const float a[3], const float b[3], float t)
MINLINE void add_v3_v3v3(float r[3], const float a[3], const float b[3])
MINLINE void cross_v3_v3v3(float r[3], const float a[3], const float b[3])
MINLINE void negate_v3(float r[3])
MINLINE float normalize_v3_v3(float r[3], const float a[3])
MINLINE void copy_v3_fl(float r[3], float f)
MINLINE void zero_v3(float r[3])
MINLINE void add_v3_v3(float r[3], const float a[3])
MINLINE float normalize_v3(float n[3])
MINLINE float len_v3(const float a[3]) ATTR_WARN_UNUSED_RESULT
char * BLI_strdup(const char *str) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1) ATTR_MALLOC
char * BLI_strdup_null(const char *str) ATTR_WARN_UNUSED_RESULT ATTR_MALLOC
char * STRNCPY(char(&dst)[N], const char *src)
#define STRNCPY_UTF8(dst, src)
void BLI_uniquename(const struct ListBase *list, void *vlink, const char *defname, char delim, int name_offset, size_t name_maxncpy) ATTR_NONNULL(1
#define INIT_MINMAX(min, max)
void BLO_write_float_array(BlendWriter *writer, int64_t num, const float *data_ptr)
void BLO_write_struct_by_name(BlendWriter *writer, const char *struct_name, const void *data_ptr)
void BLO_read_float_array(BlendDataReader *reader, int64_t array_size, float **ptr_p)
#define BLO_write_struct(writer, struct_name, data_ptr)
void * BLO_read_struct_by_name_array(BlendDataReader *reader, const char *struct_name, int64_t items_num, const void *old_address)
void BLO_read_string(BlendDataReader *reader, char **ptr_p)
void BLO_write_string(BlendWriter *writer, const char *data_ptr)
#define BLO_read_struct_list(reader, struct_name, list)
#define CLOG_WARN(clg_ref,...)
void DEG_id_tag_update(ID *id, unsigned int flags)
bool DEG_is_active(const Depsgraph *depsgraph)
float DEG_get_ctime(const Depsgraph *graph)
Scene * DEG_get_evaluated_scene(const Depsgraph *graph)
T * DEG_get_original(T *id)
T * DEG_get_evaluated(const Depsgraph *depsgraph, T *id)
#define ID_IS_LINKED(_id)
#define ID_IS_EDITABLE(_id)
#define ID_IS_OVERRIDE_LIBRARY(_id)
@ CACHE_FILE_TYPE_INVALID
@ CONSTRAINT_OVERRIDE_LIBRARY_LOCAL
@ CONSTRAINT_BBONE_SHAPE_FULL
@ CONSTRAINT_TAR_CUSTOM_SPACE
@ CONSTRAINT_TYPE_TRACKTO
@ CONSTRAINT_TYPE_CHILDOF
@ CONSTRAINT_TYPE_TRANSFORM
@ CONSTRAINT_TYPE_FOLLOWTRACK
@ CONSTRAINT_TYPE_OBJECTSOLVER
@ CONSTRAINT_TYPE_ARMATURE
@ CONSTRAINT_TYPE_LOCLIKE
@ CONSTRAINT_TYPE_SHRINKWRAP
@ CONSTRAINT_TYPE_ROTLIMIT
@ CONSTRAINT_TYPE_CAMERASOLVER
@ CONSTRAINT_TYPE_GEOMETRY_ATTRIBUTE
@ CONSTRAINT_TYPE_ROTLIKE
@ CONSTRAINT_TYPE_SPLINEIK
@ CONSTRAINT_TYPE_KINEMATIC
@ CONSTRAINT_TYPE_DISTLIMIT
@ CONSTRAINT_TYPE_TRANSLIKE
@ CONSTRAINT_TYPE_LOCLIMIT
@ CONSTRAINT_TYPE_CLAMPTO
@ CONSTRAINT_TYPE_LOCKTRACK
@ CONSTRAINT_TYPE_SIZELIMIT
@ CONSTRAINT_TYPE_FOLLOWPATH
@ CONSTRAINT_TYPE_STRETCHTO
@ CONSTRAINT_TYPE_SIZELIKE
@ CONSTRAINT_TYPE_SAMEVOL
@ CONSTRAINT_TYPE_DAMPTRACK
@ CONSTRAINT_TYPE_TRANSFORM_CACHE
@ CONSTRAINT_OBTYPE_OBJECT
@ CON_ATTRIBUTE_QUATERNION
@ CON_ATTRIBUTE_4X4MATRIX
@ CONSTRAINT_ARMATURE_QUATERNION
@ CONSTRAINT_ARMATURE_ENVELOPE
@ CONSTRAINT_ARMATURE_CUR_LOCATION
@ CAMERASOLVER_ACTIVECLIP
@ FOLLOWTRACK_USE_UNDISTORTION
@ FOLLOWTRACK_USE_3D_POSITION
@ ACTCON_BONE_USE_OBJECT_ACTION
@ LIMIT_ROT_LEGACY_BEHAVIOR
#define CON_SHRINKWRAP_PROJECT_CULL_MASK
@ TRANS_MIXSCALE_MULTIPLY
@ CONSTRAINT_SPLINEIK_YS_FIT_CURVE
@ CONSTRAINT_SPACE_CUSTOM
@ CONSTRAINT_SPACE_OWNLOCAL
@ CONSTRAINT_SPACE_PARLOCAL
@ CON_ATTRIBUTE_DOMAIN_EDGE
@ CON_ATTRIBUTE_DOMAIN_POINT
@ CON_ATTRIBUTE_DOMAIN_CURVE
@ CON_ATTRIBUTE_DOMAIN_FACE_CORNER
@ CON_ATTRIBUTE_DOMAIN_FACE
@ CON_ATTRIBUTE_DOMAIN_INSTANCE
@ ACTCON_MIX_BEFORE_SPLIT
@ CON_ATTRIBUTE_MIX_AFTER_FULL
@ CON_ATTRIBUTE_MIX_AFTER_SPLIT
@ CON_ATTRIBUTE_MIX_BEFORE_SPLIT
@ CON_ATTRIBUTE_MIX_BEFORE_FULL
@ CON_ATTRIBUTE_MIX_REPLACE
@ CONSTRAINT_SPLINEIK_USE_ORIGINAL_SCALE
@ TRANSLIKE_MIX_AFTER_FULL
@ TRANSLIKE_MIX_BEFORE_SPLIT
@ TRANSLIKE_MIX_BEFORE_FULL
@ TRANSLIKE_MIX_AFTER_SPLIT
@ OBJECTSOLVER_ACTIVECLIP
@ OBJECTSOLVER_SET_INVERSE
@ CON_SHRINKWRAP_PROJECT_INVERT_CULL
@ CON_SHRINKWRAP_PROJECT_OPPOSITE
@ CON_SHRINKWRAP_TRACK_NORMAL
@ PIVOTCON_FLAG_OFFSET_ABS
@ TRANSLIKE_REMOVE_TARGET_SHEAR
@ STRETCHTOCON_USE_BULGE_MAX
@ STRETCHTOCON_USE_BULGE_MIN
@ FOLLOWTRACK_FRAME_STRETCH
@ MOD_SHRINKWRAP_TARGET_PROJECT
@ MOD_SHRINKWRAP_NEAREST_VERTEX
@ MOD_SHRINKWRAP_NEAREST_SURFACE
Object is a sort of wrapper for general info.
@ UI_PANEL_DATA_EXPAND_ROOT
@ UI_SUBPANEL_DATA_EXPAND_2
@ UI_SUBPANEL_DATA_EXPAND_1
static double angle(const Eigen::Vector3d &v1, const Eigen::Vector3d &v2)
Read Guarded memory(de)allocation.
#define BM_ITER_MESH(ele, iter, bm, itype)
BMesh const char void * data
ATTR_WARN_UNUSED_RESULT const BMVert * v
BPy_StructRNA * depsgraph
SIMD_FORCE_INLINE btVector3 transform(const btVector3 &point) const
btVector3 orth(const btVector3 &v)
static DBVT_INLINE btScalar size(const btDbvtVolume &a)
static btDbvtVolume bounds(btDbvtNode **leaves, int count)
btSequentialImpulseConstraintSolverMt int btPersistentManifold int btTypedConstraint ** constraints
SIMD_FORCE_INLINE btScalar norm() const
Return the norm (length) of the vector.
void destruct(void *ptr) const
const CPPType & type() const
void get_to_uninitialized(int64_t index, void *r_value) const
constexpr IndexRange index_range() const
constexpr bool is_empty() const
GAttributeReader lookup(const StringRef attribute_id) const
virtual std::optional< AttributeAccessor > attributes() const
static void add_new_constraint_to_list(Object *ob, bPoseChannel *pchan, bConstraint *con)
static void minmax_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targets)
static void minmax_new_data(void *cdata)
static bConstraint * constraint_find_original_for_update(bConstraintOb *cob, bConstraint *con)
static void stretchto_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static blender::bke::AttrType type_value_to_attribute(const Attribute_Data_Type data_type)
static void minmax_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static void followtrack_fit_frame(FollowTrackContext *context, const int clip_width, const int clip_height, float marker_position[2])
static void samevolume_new_data(void *cdata)
bool BKE_constraint_apply_and_remove_for_pose(Depsgraph *depsgraph, Scene *scene, ListBase *constraints, Object *ob, bConstraint *con, bPoseChannel *pchan)
static float followtrack_distance_from_viewplane_get(FollowTrackContext *context, bConstraintOb *cob)
void BKE_constraint_targets_for_solving_get(Depsgraph *depsgraph, bConstraint *con, bConstraintOb *cob, ListBase *targets, float ctime)
static void damptrack_do_transform(float matrix[4][4], const float tarvec[3], int track_axis)
static int kinematic_get_tars(bConstraint *con, ListBase *list)
static bConstraintTypeInfo CTI_TRANSFORM_CACHE
static bool splineik_get_tarmat(Depsgraph *, bConstraint *, bConstraintOb *, bConstraintTarget *ct, float)
static void camerasolver_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *)
static void stretchto_new_data(void *cdata)
bool BKE_constraint_is_nonlocal_in_liboverride(const Object *ob, const bConstraint *con)
static bool default_get_tarmat(Depsgraph *, bConstraint *con, bConstraintOb *cob, bConstraintTarget *ct, float)
void BKE_constraints_copy(ListBase *dst, const ListBase *src, bool do_extern)
static bConstraintTypeInfo CTI_ROTLIKE
bool BKE_constraint_target_uses_bbone(bConstraint *con, bConstraintTarget *ct)
static void locktrack_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targets)
static void sizelike_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static void transformcache_new_data(void *cdata)
static int followpath_get_tars(bConstraint *con, ListBase *list)
static void kinematic_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static void loclike_flush_tars(bConstraint *con, ListBase *list, bool no_copy)
static void followtrack_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *)
static bConstraintTypeInfo CTI_ROTLIMIT
static void followtrack_evaluate_using_3d_position_object(FollowTrackContext *context, bConstraintOb *cob)
static void sizelike_flush_tars(bConstraint *con, ListBase *list, bool no_copy)
static int loclike_get_tars(bConstraint *con, ListBase *list)
static void transform_new_data(void *cdata)
static void armdef_accumulate_bone(const bConstraintTarget *ct, const bPoseChannel *pchan, const float wco[3], const bool force_envelope, float *r_totweight, float r_sum_mat[4][4], DualQuat *r_sum_dq)
static void transformcache_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static const blender::bke::GeometryComponent * find_source_component(const blender::bke::GeometrySet &geometry, const blender::bke::AttrDomain domain)
static void rotlike_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targets)
static void translike_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static void transformcache_copy(bConstraint *con, bConstraint *srccon)
bConstraint * BKE_constraint_copy_for_object(Object *ob, bConstraint *src)
static int minmax_get_tars(bConstraint *con, ListBase *list)
static void followpath_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targets)
static bool actcon_get_tarmat(Depsgraph *depsgraph, bConstraint *con, bConstraintOb *cob, bConstraintTarget *ct, float)
static void followtrack_evaluate_using_3d_position_camera(FollowTrackContext *context, bConstraintOb *cob)
static bConstraintTypeInfo CTI_STRETCHTO
bConstraint * BKE_constraint_copy_for_pose(Object *ob, bPoseChannel *pchan, bConstraint *src)
static bConstraint * constraint_list_find_from_target(ListBase *constraints, bConstraintTarget *tgt)
static void objectsolver_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *)
static bConstraintTypeInfo CTI_TRANSFORM
static bool armdef_get_tarmat(Depsgraph *, bConstraint *, bConstraintOb *, bConstraintTarget *ct, float)
static void vectomat(const float vec[3], const float target_up[3], short axis, short upflag, short flags, float m[3][3])
static bConstraintTypeInfo CTI_DAMPTRACK
static int stretchto_get_tars(bConstraint *con, ListBase *list)
static void rotlike_new_data(void *cdata)
static void followtrack_evaluate_using_3d_position(FollowTrackContext *context, bConstraintOb *cob)
static void childof_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targets)
static void followpath_flush_tars(bConstraint *con, ListBase *list, bool no_copy)
static void con_extern_cb(bConstraint *, ID **idpoin, bool, void *)
static void geometry_attribute_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targets)
static bool is_custom_space_needed(bConstraint *con)
static bConstraintTypeInfo CTI_CLAMPTO
static bool kinematic_get_tarmat(Depsgraph *, bConstraint *con, bConstraintOb *cob, bConstraintTarget *ct, float)
static void geometry_attribute_flush_tars(bConstraint *con, ListBase *list, const bool no_copy)
static void pivotcon_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targets)
static bConstraintTypeInfo CTI_SAMEVOL
static void sizelimit_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *)
static void splineik_copy(bConstraint *con, bConstraint *srccon)
static int damptrack_get_tars(bConstraint *con, ListBase *list)
static void clampto_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targets)
static int basis_cross(int n, int m)
static bConstraintTypeInfo CTI_TRACKTO
static void childof_new_data(void *cdata)
void BKE_constraint_free_data_ex(bConstraint *con, bool do_id_user)
static bConstraintTypeInfo CTI_KINEMATIC
static int splineik_get_tars(bConstraint *con, ListBase *list)
static void samevolume_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *)
static void actcon_flush_tars(bConstraint *con, ListBase *list, bool no_copy)
static void distlimit_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targets)
void BKE_constraint_unique_name(bConstraint *con, ListBase *list)
static bConstraintTypeInfo CTI_TRANSLIKE
static bConstraintTypeInfo CTI_FOLLOWPATH
static void shrinkwrap_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static void loclimit_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *)
void BKE_constraints_active_set(ListBase *list, bConstraint *con)
static bConstraintTypeInfo CTI_SIZELIKE
static bool clampto_get_tarmat(Depsgraph *, bConstraint *, bConstraintOb *, bConstraintTarget *ct, float)
static void geometry_attribute_new_data(void *cdata)
bool BKE_constraint_apply_and_remove_for_object(Depsgraph *depsgraph, Scene *scene, ListBase *constraints, Object *ob, bConstraint *con)
static void actcon_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static void splineik_new_data(void *cdata)
void BKE_constraints_clear_evalob(bConstraintOb *cob)
static MovieClip * followtrack_tracking_clip_get(bConstraint *con, bConstraintOb *cob)
static void locktrack_flush_tars(bConstraint *con, ListBase *list, bool no_copy)
static void transform_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targets)
static bConstraintTypeInfo CTI_CHILDOF
static void armdef_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targets)
static void actcon_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targets)
static void followpath_new_data(void *cdata)
static void transform_flush_tars(bConstraint *con, ListBase *list, bool no_copy)
static void camerasolver_new_data(void *cdata)
static int translike_get_tars(bConstraint *con, ListBase *list)
static bConstraintTypeInfo CTI_SIZELIMIT
static void armdef_accumulate_matrix(const float obmat[4][4], const float iobmat[4][4], const float basemat[4][4], const float bonemat[4][4], const float pivot[3], const float weight, float r_sum_mat[4][4], DualQuat *r_sum_dq)
void BKE_constraint_target_matrix_get(Depsgraph *depsgraph, Scene *scene, bConstraint *con, int index, short ownertype, void *ownerdata, float mat[4][4], float ctime)
static void clampto_flush_tars(bConstraint *con, ListBase *list, bool no_copy)
static bool default_get_tarmat_full_bbone(Depsgraph *, bConstraint *con, bConstraintOb *cob, bConstraintTarget *ct, float)
static bConstraintTypeInfo CTI_DISTLIMIT
static bConstraint * add_new_constraint(Object *ob, bPoseChannel *pchan, const char *name, short type)
static bConstraintTypeInfo CTI_CAMERASOLVER
static bConstraintTypeInfo CTI_LOCLIKE
static void stretchto_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targets)
static void trackto_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static void objectsolver_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static bConstraintTypeInfo CTI_LOCLIMIT
void BKE_constraints_solve(Depsgraph *depsgraph, ListBase *conlist, bConstraintOb *cob, float ctime)
static void trackto_flush_tars(bConstraint *con, ListBase *list, bool no_copy)
static void geometry_attribute_copy_data(bConstraint *con, bConstraint *srccon)
static void camerasolver_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static void armdef_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
bConstraint * BKE_constraints_find_name(ListBase *list, const char *name)
static void followtrack_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static bConstraint * add_new_constraint_internal(const char *name, short type)
static void loclike_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static void constraint_copy_data_ex(bConstraint *dst, bConstraint *src, const int flag, const bool do_extern)
static bool followtrack_context_init(FollowTrackContext *context, bConstraint *con, bConstraintOb *cob)
void BKE_constraint_mat_convertspace(Object *ob, bPoseChannel *pchan, bConstraintOb *cob, float mat[4][4], short from, short to, const bool keep_scale)
bConstraint * BKE_constraint_duplicate_ex(bConstraint *src, const int flag, const bool do_extern)
static void con_unlink_refs_cb(bConstraint *, ID **idpoin, bool is_reference, void *)
static void loclike_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targets)
static int childof_get_tars(bConstraint *con, ListBase *list)
void BKE_constraint_panel_expand(bConstraint *con)
static int actcon_get_tars(bConstraint *con, ListBase *list)
static void shrinkwrap_new_data(void *cdata)
static void objectsolver_new_data(void *cdata)
static void con_fix_copied_refs_cb(bConstraint *, ID **idpoin, bool is_reference, void *)
static void contarget_get_mesh_mat(Object *ob, const char *substring, float mat[4][4])
static void splineik_flush_tars(bConstraint *con, ListBase *list, bool no_copy)
static void distlimit_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static void rotlike_flush_tars(bConstraint *con, ListBase *list, bool no_copy)
static bConstraintTypeInfo CTI_FOLLOWTRACK
static void armdef_copy(bConstraint *con, bConstraint *srccon)
static bConstraintTypeInfo CTI_SHRINKWRAP
static void kinematic_new_data(void *cdata)
static bConstraintTypeInfo CTI_ARMATURE
static void sizelike_new_data(void *cdata)
void BKE_constraints_copy_ex(ListBase *dst, const ListBase *src, const int flag, bool do_extern)
static void childof_flush_tars(bConstraint *con, ListBase *list, bool no_copy)
bool BKE_constraint_apply_for_pose(Depsgraph *depsgraph, Scene *scene, Object *ob, bPoseChannel *pchan, bConstraint *con)
static int sizelike_get_tars(bConstraint *con, ListBase *list)
static void stretchto_flush_tars(bConstraint *con, ListBase *list, bool no_copy)
bConstraint * BKE_constraint_add_for_pose(Object *ob, bPoseChannel *pchan, const char *name, short type)
void BKE_constraints_free_ex(ListBase *list, bool do_id_user)
static bool component_is_available(const blender::bke::GeometrySet &geometry, const blender::bke::GeometryComponent::Type type, const blender::bke::AttrDomain domain)
static int rotlike_get_tars(bConstraint *con, ListBase *list)
static void translike_flush_tars(bConstraint *con, ListBase *list, bool no_copy)
static bool constraint_remove(ListBase *list, bConstraint *con)
const bConstraintTypeInfo * BKE_constraint_typeinfo_get(bConstraint *con)
static void constraints_init_typeinfo()
static bool geometry_attribute_get_tarmat(Depsgraph *, bConstraint *con, bConstraintOb *, bConstraintTarget *ct, float)
static void translike_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targets)
static bool followpath_get_tarmat(Depsgraph *, bConstraint *con, bConstraintOb *, bConstraintTarget *ct, float)
static void rotlike_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static void followpath_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static void transformcache_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targets)
static void locktrack_new_data(void *cdata)
static int locktrack_get_tars(bConstraint *con, ListBase *list)
static void shrinkwrap_evaluate(bConstraint *, bConstraintOb *cob, ListBase *targets)
static void shrinkwrap_flush_tars(bConstraint *con, ListBase *list, bool no_copy)
#define SINGLETARGETNS_GET_TARS(con, datatar, ct, list)
static float clamp_angle(const float angle, const float min, const float max)
void BKE_constraint_custom_object_space_init(bConstraintOb *cob, bConstraint *con)
static int distlimit_get_tars(bConstraint *con, ListBase *list)
static void unit_ct_matrix_nullsafe(bConstraintTarget *ct)
static bConstraintTypeInfo CTI_SPLINEIK
static void splineik_free(bConstraint *con)
static int pivotcon_get_tars(bConstraint *con, ListBase *list)
static void trackto_new_data(void *cdata)
void BKE_constraints_id_loop(ListBase *conlist, ConstraintIDFunc func, const int flag, void *userdata)
static void followtrack_undistort_if_needed(FollowTrackContext *context, const int clip_width, const int clip_height, float marker_position[2])
bool BKE_constraint_remove_ex(ListBase *list, Object *ob, bConstraint *con)
static void value_attribute_to_matrix(float r_matrix[4][4], const blender::GPointer value, const Attribute_Data_Type data_type)
bConstraint * BKE_constraints_active_get(ListBase *list)
void BKE_constraint_targets_flush(bConstraint *con, ListBase *targets, bool no_copy)
static float wrap_rad_angle(const float angle)
static bool shrinkwrap_get_tarmat(Depsgraph *, bConstraint *con, bConstraintOb *cob, bConstraintTarget *ct, float)
static void damptrack_new_data(void *cdata)
static void damptrack_flush_tars(bConstraint *con, ListBase *list, bool no_copy)
bConstraintOb * BKE_constraints_make_evalob(Depsgraph *depsgraph, Scene *scene, Object *ob, void *subdata, short datatype)
static Object * followtrack_camera_object_get(bConstraint *con, bConstraintOb *cob)
static void trackto_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targets)
static void damptrack_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targets)
static void followtrack_evaluate_using_2d_position(FollowTrackContext *context, bConstraintOb *cob)
static bConstraintTypeInfo CTI_ATTRIBUTE
static void constraint_target_to_mat4(Object *ob, const char *substring, bConstraintOb *cob, float mat[4][4], short from, short to, short flag, float headtail)
static void contarget_get_lattice_mat(Object *ob, const char *substring, float mat[4][4])
static bConstraintTypeInfo CTI_MINMAX
static int shrinkwrap_get_tars(bConstraint *con, ListBase *list)
void BKE_constraints_free(ListBase *list)
static void pivotcon_flush_tars(bConstraint *con, ListBase *list, bool no_copy)
static blender::bke::AttrDomain domain_value_to_attribute(const Attribute_Domain domain)
static bConstraint * constraint_find_original(Object *ob, bPoseChannel *pchan, bConstraint *con, Object **r_orig_ob)
static bConstraintTypeInfo * constraintsTypeInfo[NUM_CONSTRAINT_TYPES]
static void sizelike_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *targets)
static int armdef_get_tars(bConstraint *con, ListBase *list)
static void followtrack_project_to_depth_object_if_needed(FollowTrackContext *context, bConstraintOb *cob)
static void transformcache_free(bConstraint *con)
static void pivotcon_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static MovieTrackingObject * followtrack_tracking_object_get(bConstraint *con, bConstraintOb *cob)
static const float track_dir_vecs[6][3]
static int trackto_get_tars(bConstraint *con, ListBase *list)
#define SINGLETARGETNS_FLUSH_TARS(con, datatar, ct, list, no_copy)
static void locktrack_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
int BKE_constraint_targets_get(bConstraint *con, ListBase *r_targets)
static void splineik_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static void minmax_flush_tars(bConstraint *con, ListBase *list, bool no_copy)
void BKE_constraint_free_data(bConstraint *con)
const bConstraintTypeInfo * BKE_constraint_typeinfo_from_type(int type)
bConstraint * BKE_constraint_find_from_target(Object *ob, bConstraintTarget *tgt, bPoseChannel **r_pchan)
#define VALID_CONS_TARGET(ct)
static void actcon_new_data(void *cdata)
static void loclike_new_data(void *cdata)
bConstraint * BKE_constraint_add_for_object(Object *ob, const char *name, short type)
static void armdef_free(bConstraint *con)
static void damptrack_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
#define SINGLETARGET_GET_TARS(con, datatar, datasubtarget, ct, list)
static bConstraintTypeInfo CTI_LOCKTRACK
void BKE_constraint_blend_write(BlendWriter *writer, ListBase *conlist)
static void geometry_attribute_free_data(bConstraint *con)
static int transform_get_tars(bConstraint *con, ListBase *list)
void BKE_constraint_blend_read_data(BlendDataReader *reader, ID *id_owner, ListBase *lb)
static int geometry_attribute_get_tars(bConstraint *con, ListBase *list)
static bConstraintTypeInfo CTI_OBJECTSOLVER
static bConstraintTypeInfo CTI_PIVOT
bool BKE_constraint_apply_for_object(Depsgraph *depsgraph, Scene *scene, Object *ob, bConstraint *con)
static void con_invoke_id_looper(const bConstraintTypeInfo *cti, bConstraint *con, ConstraintIDFunc func, const int, void *userdata)
static void geometry_attribute_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static bConstraintTypeInfo CTI_ACTION
static int clampto_get_tars(bConstraint *con, ListBase *list)
static void rotlimit_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *)
static void kinematic_flush_tars(bConstraint *con, ListBase *list, bool no_copy)
static void distlimit_flush_tars(bConstraint *con, ListBase *list, bool no_copy)
static void clampto_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static void followtrack_new_data(void *cdata)
#define SINGLETARGET_FLUSH_TARS(con, datatar, datasubtarget, ct, list, no_copy)
static void childof_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
static void distlimit_new_data(void *cdata)
static void transform_id_looper(bConstraint *con, ConstraintIDFunc func, void *userdata)
void * MEM_callocN(size_t len, const char *str)
void * MEM_dupallocN(const void *vmemh)
void MEM_freeN(void *vmemh)
GeometrySet object_get_evaluated_geometry_set(const Object &object, bool apply_subdiv=true)
void USD_get_transform(CacheReader *reader, float r_mat_world[4][4], float time, float scale)
T safe_divide(const T &a, const T &b)
VecBase< float, 3 > cross_high_precision(const VecBase< float, 3 > &a, const VecBase< float, 3 > &b)
MatBase< float, 4, 4 > float4x4
VecBase< float, 4 > float4
VecBase< float, 3 > float3
MovieTrackingObject * tracking_object
MovieTrackingTrack * track
struct MDeformVert * dvert
struct MovieTracking tracking
ObjectRuntimeHandle * runtime
int32_t action_slot_handle
char last_slot_identifier[258]
float space_obj_world_matrix[4][4]
struct bPoseChannel * pchan
struct Depsgraph * depsgraph
void(* id_looper)(struct bConstraint *con, ConstraintIDFunc func, void *userdata)
int(* get_constraint_targets)(struct bConstraint *con, struct ListBase *list)
void(* evaluate_constraint)(struct bConstraint *con, struct bConstraintOb *cob, struct ListBase *targets)
void(* flush_constraint_targets)(struct bConstraint *con, struct ListBase *list, bool no_copy)
bool(* get_target_matrix)(struct Depsgraph *depsgraph, struct bConstraint *con, struct bConstraintOb *cob, struct bConstraintTarget *ct, float ctime)
void(* copy_data)(struct bConstraint *con, struct bConstraint *src)
void(* free_data)(struct bConstraint *con)
void(* new_data)(void *cdata)
struct Object * space_object
struct bConstraint * prev
struct bConstraint * next
struct Mat4 * bbone_deform_mats
struct Mat4 * bbone_pose_mats
struct Mat4 * bbone_rest_mats
struct bPoseChannel_Runtime runtime
struct bPoseChannel * orig_pchan
BVHTree_RayCastCallback raycast_callback
static int blend(const Tex *tex, const float texvec[3], TexResult *texres)