Blender V2.61 - r43446
|
Go to the source code of this file.
Classes | |
struct | bConstraintOb |
struct | bConstraintTypeInfo |
Defines | |
#define | VALID_CONS_TARGET(ct) ((ct) && (ct->tar)) |
Typedefs | |
typedef struct bConstraintOb | bConstraintOb |
typedef void(* | ConstraintIDFunc )(struct bConstraint *con, struct ID **idpoin, void *userdata) |
typedef struct bConstraintTypeInfo | bConstraintTypeInfo |
Functions | |
bConstraintTypeInfo * | constraint_get_typeinfo (struct bConstraint *con) |
bConstraintTypeInfo * | get_constraint_typeinfo (int type) |
void | unique_constraint_name (struct bConstraint *con, struct ListBase *list) |
void | free_constraints (struct ListBase *list) |
void | copy_constraints (struct ListBase *dst, const struct ListBase *src, int do_extern) |
void | relink_constraints (struct ListBase *list) |
void | id_loop_constraints (struct ListBase *list, ConstraintIDFunc func, void *userdata) |
void | free_constraint_data (struct bConstraint *con) |
struct bConstraint * | constraints_get_active (struct ListBase *list) |
void | constraints_set_active (ListBase *list, struct bConstraint *con) |
struct bConstraint * | constraints_findByName (struct ListBase *list, const char *name) |
struct bConstraint * | add_ob_constraint (struct Object *ob, const char *name, short type) |
struct bConstraint * | add_pose_constraint (struct Object *ob, struct bPoseChannel *pchan, const char *name, short type) |
int | remove_constraint (ListBase *list, struct bConstraint *con) |
void | remove_constraints_type (ListBase *list, short type, short last_only) |
void | extract_proxylocal_constraints (struct ListBase *dst, struct ListBase *src) |
short | proxylocked_constraints_owner (struct Object *ob, struct bPoseChannel *pchan) |
struct bConstraintOb * | constraints_make_evalob (struct Scene *scene, struct Object *ob, void *subdata, short datatype) |
void | constraints_clear_evalob (struct bConstraintOb *cob) |
void | constraint_mat_convertspace (struct Object *ob, struct bPoseChannel *pchan, float mat[][4], short from, short to) |
void | get_constraint_target_matrix (struct Scene *scene, struct bConstraint *con, int n, short ownertype, void *ownerdata, float mat[][4], float ctime) |
void | get_constraint_targets_for_solving (struct bConstraint *con, struct bConstraintOb *ob, struct ListBase *targets, float ctime) |
void | solve_constraints (struct ListBase *conlist, struct bConstraintOb *cob, float ctime) |
Definition in file BKE_constraint.h.
#define VALID_CONS_TARGET | ( | ct | ) | ((ct) && (ct->tar)) |
Definition at line 120 of file BKE_constraint.h.
Referenced by actcon_evaluate(), actcon_get_tarmat(), childof_evaluate(), clampto_evaluate(), clampto_get_tarmat(), damptrack_evaluate(), default_get_tarmat(), distlimit_evaluate(), followpath_evaluate(), followpath_get_tarmat(), kinematic_get_tarmat(), locktrack_evaluate(), loclike_evaluate(), minmax_evaluate(), pivotcon_evaluate(), pycon_get_tarmat(), rotlike_evaluate(), shrinkwrap_evaluate(), shrinkwrap_get_tarmat(), sizelike_evaluate(), splineik_get_tarmat(), stretchto_evaluate(), trackto_evaluate(), transform_evaluate(), and translike_evaluate().
typedef struct bConstraintOb bConstraintOb |
typedef struct bConstraintTypeInfo bConstraintTypeInfo |
typedef void(* ConstraintIDFunc)(struct bConstraint *con, struct ID **idpoin, void *userdata) |
Definition at line 65 of file BKE_constraint.h.
struct bConstraint* add_ob_constraint | ( | struct Object * | ob, |
const char * | name, | ||
short | type | ||
) | [read] |
Definition at line 4507 of file constraint.c.
References add_new_constraint(), and NULL.
Referenced by constraint_add_exec(), do_version_old_trackto_to_constraints(), parent_set_exec(), and track_set_exec().
struct bConstraint* add_pose_constraint | ( | struct Object * | ob, |
struct bPoseChannel * | pchan, | ||
const char * | name, | ||
short | type | ||
) | [read] |
Definition at line 4498 of file constraint.c.
References add_new_constraint(), and NULL.
Referenced by constraint_add_exec(), and pose_grab_with_ik_add().
bConstraintTypeInfo* constraint_get_typeinfo | ( | struct bConstraint * | con | ) |
Definition at line 4329 of file constraint.c.
References get_constraint_typeinfo(), NULL, and bConstraint::type.
Referenced by armature_delete_selected_exec(), build_dag_object(), constraint_bone_name_fix(), copy_constraints(), copy_object_pose(), dag_id_flush_update(), dag_object_time_update_flags(), DAG_pose_sort(), do_versions(), draw_constraint(), draw_object(), free_constraint_data(), get_constraint_target_matrix(), get_constraint_targets_for_solving(), id_loop_constraints(), joined_armature_fix_links(), BL_ArmatureObject::LoadConstraints(), object_solver_camera(), object_solver_inverted_matrix(), pose_proxy_synchronize(), pose_select_constraint_target_exec(), relink_constraints(), RIG_reconnectControlBones(), separated_armature_fix_links(), set_constraint_nth_target(), solve_constraints(), subframe_updateObject(), test_constraints(), unlink_movieclip(), unlink_object(), updateDuplicateSubtargetObjects(), and write_constraints().
void constraint_mat_convertspace | ( | struct Object * | ob, |
struct bPoseChannel * | pchan, | ||
float | mat[][4], | ||
short | from, | ||
short | to | ||
) |
Definition at line 227 of file constraint.c.
References Bone::arm_mat, bPoseChannel::bone, BONE_HINGE, Bone::bone_mat, constraint_mat_convertspace(), CONSTRAINT_SPACE_LOCAL, CONSTRAINT_SPACE_PARLOCAL, CONSTRAINT_SPACE_POSE, CONSTRAINT_SPACE_WORLD, copy_m4_m3(), copy_m4_m4(), copy_v3_v3(), ELEM, Bone::flag, Bone::head, invert_m4_m4(), Bone::length, mul_m4_v3(), mult_m4_m4m4(), normalize_m4(), NULL, object_to_mat4(), Object::obmat, bPoseChannel::parent, Bone::parent, Object::parent, Object::parentinv, bPoseChannel::pose_mat, and zero_v3().
Referenced by constraint_mat_convertspace(), constraint_target_to_mat4(), dvar_eval_locDiff(), dvar_eval_transChan(), solve_constraints(), and visualkey_get_value().
void constraints_clear_evalob | ( | struct bConstraintOb * | cob | ) |
Definition at line 177 of file constraint.c.
References bPoseChannel::constinv, Object::constinv, CONSTRAINT_OBTYPE_BONE, CONSTRAINT_OBTYPE_OBJECT, copy_m4_m4(), Object::imat, invert_m4_m4(), bConstraintOb::matrix, MEM_freeN(), mult_m4_m4m4(), NULL, bConstraintOb::ob, Object::obmat, bConstraintOb::pchan, bPoseChannel::pose_mat, bConstraintOb::startmat, and bConstraintOb::type.
Referenced by draw_object(), where_is_object_simul(), where_is_object_time(), and where_is_pose_bone().
struct bConstraint* constraints_findByName | ( | struct ListBase * | list, |
const char * | name | ||
) | [read] |
Definition at line 4600 of file constraint.c.
References BLI_findstring().
Referenced by edit_constraint_property_get().
struct bConstraint* constraints_get_active | ( | struct ListBase * | list | ) | [read] |
Definition at line 4606 of file constraint.c.
References CONSTRAINT_ACTIVE, ListBase::first, bConstraint::flag, bConstraint::next, and NULL.
Referenced by get_active_constraint().
struct bConstraintOb* constraints_make_evalob | ( | struct Scene * | scene, |
struct Object * | ob, | ||
void * | subdata, | ||
short | datatype | ||
) | [read] |
Definition at line 113 of file constraint.c.
References CONSTRAINT_OBTYPE_BONE, CONSTRAINT_OBTYPE_OBJECT, copy_m4_m4(), EULER_ORDER_DEFAULT, bConstraintOb::matrix, MEM_callocN(), mult_m4_m4m4(), bConstraintOb::ob, Object::obmat, bConstraintOb::pchan, bPoseChannel::pose_mat, bPoseChannel::rotmode, bConstraintOb::rotOrder, bConstraintOb::scene, bConstraintOb::startmat, bConstraintOb::type, and unit_m4().
Referenced by draw_object(), where_is_object_simul(), where_is_object_time(), and where_is_pose_bone().
void constraints_set_active | ( | ListBase * | list, |
struct bConstraint * | con | ||
) |
Definition at line 4623 of file constraint.c.
References CONSTRAINT_ACTIVE, ListBase::first, bConstraint::flag, and bConstraint::next.
Referenced by add_new_constraint(), constraint_delete_exec(), and ED_object_constraint_set_active().
Definition at line 4640 of file constraint.c.
References BLI_addtail(), BLI_remlink(), CONSTRAINT_PROXY_LOCAL, ListBase::first, bConstraint::flag, bConstraint::next, and next.
Referenced by pose_proxy_synchronize().
void free_constraint_data | ( | struct bConstraint * | con | ) |
Definition at line 4348 of file constraint.c.
References constraint_get_typeinfo(), bConstraint::data, bConstraintTypeInfo::free_data, and MEM_freeN().
Referenced by free_constraints(), and remove_constraint().
void free_constraints | ( | struct ListBase * | list | ) |
Definition at line 4363 of file constraint.c.
References BLI_freelistN(), ListBase::first, free_constraint_data(), and bConstraint::next.
Referenced by free_object(), free_pose_channel(), object_constraints_clear_exec(), and pose_constraints_clear_exec().
void get_constraint_target_matrix | ( | struct Scene * | scene, |
struct bConstraint * | con, | ||
int | n, | ||
short | ownertype, | ||
void * | ownerdata, | ||
float | mat[][4], | ||
float | ctime | ||
) |
Definition at line 4686 of file constraint.c.
References constraint_get_typeinfo(), CONSTRAINT_OBTYPE_BONE, CONSTRAINT_OBTYPE_OBJECT, copy_m4_m4(), ListBase::first, bConstraintTypeInfo::flush_constraint_targets, bConstraintTypeInfo::get_constraint_targets, bConstraintTypeInfo::get_target_matrix, bConstraintTarget::matrix, bConstraintOb::matrix, MEM_callocN(), MEM_freeN(), bConstraintTarget::next, NULL, bConstraintOb::ob, Object::obmat, bConstraintOb::pchan, bPoseChannel::pose_mat, bConstraintOb::scene, bConstraintOb::startmat, bConstraintOb::type, and unit_m4().
Referenced by base_callback(), execute_posetree(), parent_set_exec(), and target_callback().
void get_constraint_targets_for_solving | ( | struct bConstraint * | con, |
struct bConstraintOb * | ob, | ||
struct ListBase * | targets, | ||
float | ctime | ||
) |
Definition at line 4755 of file constraint.c.
References constraint_get_typeinfo(), ListBase::first, bConstraintTypeInfo::get_constraint_targets, bConstraintTypeInfo::get_target_matrix, bConstraintTarget::matrix, bConstraintTarget::next, and unit_m4().
Referenced by constraintTransLim(), and solve_constraints().
bConstraintTypeInfo* get_constraint_typeinfo | ( | int | type | ) |
Definition at line 4304 of file constraint.c.
References CONSTRAINT_TYPE_NULL, constraints_init_typeinfo(), NULL, and NUM_CONSTRAINT_TYPES.
Referenced by add_new_constraint_internal(), constraint_get_typeinfo(), constraintRotLim(), constraintSizeLim(), and constraintTransLim().
void id_loop_constraints | ( | struct ListBase * | list, |
ConstraintIDFunc | func, | ||
void * | userdata | ||
) |
Definition at line 4545 of file constraint.c.
References constraint_get_typeinfo(), ListBase::first, bConstraintTypeInfo::id_looper, and bConstraint::next.
Referenced by expand_constraints(), and lib_link_constraints().
short proxylocked_constraints_owner | ( | struct Object * | ob, |
struct bPoseChannel * | pchan | ||
) |
Definition at line 4657 of file constraint.c.
References bPoseChannel::bone, Object::data, Bone::layer, bArmature::layer_protected, Object::pose, and Object::proxy.
Referenced by add_new_constraint(), and draw_constraint().
void relink_constraints | ( | struct ListBase * | list | ) |
Definition at line 4515 of file constraint.c.
References constraint_get_typeinfo(), ListBase::first, bConstraintTypeInfo::flush_constraint_targets, bConstraintTypeInfo::get_constraint_targets, ID_NEW, bConstraintTarget::next, bConstraint::next, NULL, bConstraintTypeInfo::relink_data, and bConstraintTarget::tar.
Referenced by object_relink().
int remove_constraint | ( | ListBase * | list, |
struct bConstraint * | con | ||
) |
Definition at line 4377 of file constraint.c.
References BLI_freelinkN(), and free_constraint_data().
Referenced by constraint_delete_exec(), object_track_clear_exec(), pose_ik_clear_exec(), and remove_constraints_type().
void remove_constraints_type | ( | ListBase * | list, |
short | type, | ||
short | last_only | ||
) |
Definition at line 4389 of file constraint.c.
References ListBase::last, NULL, bConstraint::prev, remove_constraint(), and bConstraint::type.
void solve_constraints | ( | struct ListBase * | conlist, |
struct bConstraintOb * | cob, | ||
float | ctime | ||
) |
Definition at line 4790 of file constraint.c.
References blend_m4_m4m4(), CONSTRAINT_DISABLE, constraint_get_typeinfo(), constraint_mat_convertspace(), CONSTRAINT_OFF, CONSTRAINT_SPACE_WORLD, CONSTRAINT_SPACEONCE, copy_m4_m4(), bConstraint::enforce, bConstraintTypeInfo::evaluate_constraint, ListBase::first, bConstraint::flag, bConstraintTypeInfo::flush_constraint_targets, get_constraint_targets_for_solving(), bConstraintOb::matrix, bConstraint::next, NULL, bConstraintOb::ob, bConstraint::ownspace, and bConstraintOb::pchan.
Referenced by where_is_object_simul(), where_is_object_time(), and where_is_pose_bone().
void unique_constraint_name | ( | struct bConstraint * | con, |
struct ListBase * | list | ||
) |
Definition at line 104 of file constraint.c.
References BLI_uniquename(), and bConstraint::name.
Referenced by add_new_constraint().