|
Blender V5.0
|
Rigid Body constraint editing operators. More...
#include <cstdlib>#include <cstring>#include "DNA_collection_types.h"#include "DNA_object_types.h"#include "DNA_rigidbody_types.h"#include "DNA_scene_types.h"#include "BKE_collection.hh"#include "BKE_context.hh"#include "BKE_layer.hh"#include "BKE_lib_id.hh"#include "BKE_library.hh"#include "BKE_report.hh"#include "BKE_rigidbody.h"#include "DEG_depsgraph.hh"#include "DEG_depsgraph_build.hh"#include "RNA_access.hh"#include "RNA_define.hh"#include "RNA_enum_types.hh"#include "WM_api.hh"#include "WM_types.hh"#include "ED_object.hh"#include "ED_physics.hh"#include "ED_screen.hh"#include "physics_intern.hh"Go to the source code of this file.
Functions | |
| static bool | operator_rigidbody_constraints_editable_poll (Scene *scene) |
| static bool | operator_rigidbody_con_active_poll (bContext *C) |
| static bool | operator_rigidbody_con_add_poll (bContext *C) |
| bool | ED_rigidbody_constraint_add (Main *bmain, Scene *scene, Object *ob, int type, ReportList *reports) |
| void | ED_rigidbody_constraint_remove (Main *bmain, Scene *scene, Object *ob) |
| static wmOperatorStatus | rigidbody_con_add_exec (bContext *C, wmOperator *op) |
| void | RIGIDBODY_OT_constraint_add (wmOperatorType *ot) |
| static wmOperatorStatus | rigidbody_con_remove_exec (bContext *C, wmOperator *op) |
| void | RIGIDBODY_OT_constraint_remove (wmOperatorType *ot) |
Rigid Body constraint editing operators.
Definition in file rigidbody_constraint.cc.
| bool ED_rigidbody_constraint_add | ( | Main * | bmain, |
| Scene * | scene, | ||
| Object * | ob, | ||
| int | type, | ||
| ReportList * | reports ) |
Definition at line 80 of file rigidbody_constraint.cc.
References BKE_collection_add(), BKE_collection_object_add(), BKE_reportf(), BKE_rigidbody_create_constraint(), BKE_rigidbody_get_world(), RigidBodyWorld::constraints, DEG_id_tag_update(), DEG_relations_tag_update(), Collection::id, Object::id, ID_RECALC_SYNC_TO_EVAL, ID_RECALC_TRANSFORM, id_us_plus(), ID::name, Object::rigidbody_constraint, and RPT_INFO.
Referenced by rigidbody_con_add_exec().
Definition at line 109 of file rigidbody_constraint.cc.
References BKE_rigidbody_remove_constraint(), DEG_id_tag_update(), DEG_relations_tag_update(), Object::id, and ID_RECALC_TRANSFORM.
Referenced by rigidbody_con_remove_exec().
|
static |
Definition at line 57 of file rigidbody_constraint.cc.
References C, blender::ed::object::context_active_object(), CTX_data_scene(), ED_operator_object_active_editable(), operator_rigidbody_constraints_editable_poll(), and Object::rigidbody_constraint.
Referenced by RIGIDBODY_OT_constraint_remove().
|
static |
Definition at line 71 of file rigidbody_constraint.cc.
References C, CTX_data_scene(), ED_operator_object_active_editable(), and operator_rigidbody_constraints_editable_poll().
Referenced by RIGIDBODY_OT_constraint_add().
|
static |
Definition at line 45 of file rigidbody_constraint.cc.
References RigidBodyWorld::constraints, ID_IS_EDITABLE, ID_IS_OVERRIDE_LIBRARY, and Scene::rigidbody_world.
Referenced by operator_rigidbody_con_active_poll(), and operator_rigidbody_con_add_poll().
|
static |
Definition at line 122 of file rigidbody_constraint.cc.
References BKE_report(), BKE_rigidbody_get_world(), BKE_view_layer_active_object_get(), BKE_view_layer_synced_ensure(), C, CTX_data_main(), CTX_data_scene(), CTX_data_view_layer(), ED_rigidbody_constraint_add(), ELEM, NC_OBJECT, ND_TRANSFORM, OPERATOR_CANCELLED, OPERATOR_FINISHED, wmOperator::ptr, wmOperator::reports, RNA_enum_get(), RPT_ERROR, and WM_event_add_notifier().
Referenced by RIGIDBODY_OT_constraint_add().
|
static |
Definition at line 176 of file rigidbody_constraint.cc.
References BKE_report(), BKE_view_layer_active_object_get(), BKE_view_layer_synced_ensure(), C, CTX_data_main(), CTX_data_scene(), CTX_data_view_layer(), ED_rigidbody_constraint_remove(), ELEM, NC_OBJECT, ND_TRANSFORM, OPERATOR_CANCELLED, OPERATOR_FINISHED, wmOperator::reports, Object::rigidbody_constraint, RPT_ERROR, and WM_event_add_notifier().
Referenced by RIGIDBODY_OT_constraint_remove().
| void RIGIDBODY_OT_constraint_add | ( | wmOperatorType * | ot | ) |
Definition at line 151 of file rigidbody_constraint.cc.
References operator_rigidbody_con_add_poll(), OPTYPE_REGISTER, OPTYPE_UNDO, ot, RBC_TYPE_FIXED, rigidbody_con_add_exec(), RNA_def_enum(), and rna_enum_rigidbody_constraint_type_items.
Referenced by operatortypes_particle().
| void RIGIDBODY_OT_constraint_remove | ( | wmOperatorType * | ot | ) |
Definition at line 198 of file rigidbody_constraint.cc.
References operator_rigidbody_con_active_poll(), OPTYPE_REGISTER, OPTYPE_UNDO, ot, and rigidbody_con_remove_exec().
Referenced by operatortypes_particle().