142 view_layer->
basact = base;
182 bool any_visible =
false;
183 bool changed =
false;
216 *r_any_visible = any_visible;
260 int priority_best = 0;
263 if (base->object && base->object->data ==
id) {
270 if (priority_test > priority_best) {
271 priority_best = priority_test;
326 const char *bone_name,
327 const bool reveal_hidden)
415 if (obact && obact->
mode) {
432 short obtype, extend;
442 if (base->object->type == obtype) {
460 ot->
name =
"Select by Type";
461 ot->
description =
"Select all visible objects that are of a type";
462 ot->
idname =
"OBJECT_OT_select_by_type";
477 "Extend selection instead of deselecting everything first");
512 bool changed =
false;
516 if (base->object->data == obdata) {
529 bool changed =
false;
533 Object *ob = base->object;
554 bool changed =
false;
562 base->object->instance_collection :
564 if (instance_collection == instance_collection_other) {
578 bool changed =
false;
585 for (psys = base->object->particlesystem.first; psys; psys = psys->
next) {
605 bool changed =
false;
609 if (
lib == base->object->id.lib) {
622 bool changed =
false;
626 if (base->object->data &&
lib == ((
ID *)base->object->data)->lib) {
640 bool changed =
false;
645 else if (idtype ==
ID_MA) {
648 else if (idtype ==
ID_LI) {
666 bool changed =
false, extend;
674 ob =
OBACT(view_layer);
745 ot->
name =
"Select Linked";
746 ot->
description =
"Select all visible objects that are linked";
747 ot->
idname =
"OBJECT_OT_select_linked";
762 "Extend selection instead of deselecting everything first");
800 "Objects included in active Keying Set"},
807 bool changed =
false;
810 if (ob == base->object->
parent) {
830 bool changed =
false;
847 #define COLLECTION_MENU_MAX 24
852 bool changed =
false;
860 collection = collection->
id.
next) {
871 collection = ob_collections[0];
889 collection = ob_collections[i];
893 "OBJECT_OT_select_same_collection",
907 bool changed =
false;
931 bool changed =
false;
946 bool changed =
false;
949 if (base->object->type ==
OB_LAMP) {
950 Light *la_test = base->object->data;
962 bool changed =
false;
976 bool changed =
false;
990 bool changed =
false;
1006 bool changed =
false;
1018 "Use another Keying Set, as the active one depends on the currently "
1019 "selected objects or cannot find any targets due to unsuitable context");
1041 if (ksp->
id == (
ID *)base->object) {
1061 bool changed =
false, extend;
1069 ob =
OBACT(view_layer);
1130 ot->
name =
"Select Grouped";
1131 ot->
description =
"Select all visible objects grouped by various properties";
1132 ot->
idname =
"OBJECT_OT_select_grouped";
1147 "Extend selection instead of deselecting everything first");
1162 bool any_visible =
false;
1175 if (any_visible ==
false) {
1187 ot->
name =
"(De)select All";
1188 ot->
description =
"Change selection of all visible objects in scene";
1189 ot->
idname =
"OBJECT_OT_select_all";
1248 ot->
name =
"Select Same Collection";
1250 ot->
idname =
"OBJECT_OT_select_same_collection";
1283 if (!
STREQ(name_flip, primbase->object->id.name + 2)) {
1294 if (extend ==
false) {
1313 ot->
name =
"Select Mirror";
1315 "Select the mirror objects of the selected object e.g. \"L.sword\" and \"R.sword\"";
1316 ot->
idname =
"OBJECT_OT_select_mirror";
1326 ot->
srna,
"extend", 0,
"Extend",
"Extend selection instead of deselecting everything first");
1340 Object *ob = base->object;
1359 for (ctx_base = ctx_base_list.
first; ctx_base; ctx_base = ctx_base->
next) {
1369 bool changed =
false;
1373 for (ctx_base = ctx_base_list.
first; ctx_base; ctx_base = ctx_base->
next) {
1406 ot->
name =
"Select More";
1407 ot->
idname =
"OBJECT_OT_select_more";
1437 ot->
name =
"Select Less";
1438 ot->
idname =
"OBJECT_OT_select_less";
1439 ot->
description =
"Deselect objects at the boundaries of parent/child relationships";
1484 ot->
name =
"Select Random";
1486 ot->
idname =
"OBJECT_OT_select_random";
Blender kernel action and pose functionality.
struct bPoseChannel * BKE_pose_channel_find_name(const struct bPose *pose, const char *name)
bool BKE_collection_has_object(struct Collection *collection, const struct Object *ob)
struct Scene * CTX_data_scene(const bContext *C)
struct Object * CTX_data_edit_object(const bContext *C)
struct Base * CTX_data_active_base(const bContext *C)
#define CTX_DATA_BEGIN(C, Type, instance, member)
struct ViewLayer * CTX_data_view_layer(const bContext *C)
struct Object * CTX_data_active_object(const bContext *C)
struct View3D * CTX_wm_view3d(const bContext *C)
#define CTX_DATA_COUNT(C, member)
int CTX_data_selectable_bases(const bContext *C, ListBase *list)
struct Main * CTX_data_main(const bContext *C)
#define FOREACH_VISIBLE_BASE_END
#define FOREACH_VISIBLE_BASE_BEGIN(_view_layer, _v3d, _instance)
struct Base * BKE_view_layer_base_find(struct ViewLayer *view_layer, struct Object *ob)
struct ID * BKE_libblock_find_name(struct Main *bmain, const short type, const char *name) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL()
General operations, lookup, etc. for materials.
struct Material * BKE_object_material_get(struct Object *ob, short act)
General operations, lookup, etc. for blender objects.
struct ParticleSystem * psys_get_current(struct Object *ob)
void BKE_report(ReportList *reports, ReportType type, const char *message)
void BKE_scene_object_base_flag_sync_from_base(struct Base *base)
BLI_INLINE bool BLI_listbase_is_empty(const struct ListBase *lb)
#define LISTBASE_FOREACH(type, var, list)
void void BLI_freelistN(struct ListBase *listbase) ATTR_NONNULL(1)
MINLINE unsigned int bitscan_forward_uint(unsigned int a)
MINLINE bool compare_v3v3(const float a[3], const float b[3], const float limit) ATTR_WARN_UNUSED_RESULT
void BLI_rng_free(struct RNG *rng) ATTR_NONNULL(1)
struct RNG * BLI_rng_new_srandom(unsigned int seed)
float BLI_rng_get_float(struct RNG *rng) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
void BLI_string_flip_side_name(char *r_name, const char *from_name, const bool strip_number, const size_t name_len)
#define BLT_I18NCONTEXT_ID_ID
void DEG_id_tag_update(struct ID *id, int flag)
Object groups, one object can be in many groups at once.
#define OB_DATA_SUPPORT_ID(_id_type)
#define OBEDIT_FROM_VIEW_LAYER(view_layer)
#define OBACT(_view_layer)
#define BASE_VISIBLE(v3d, base)
#define EBONE_SELECTABLE(arm, ebone)
bool ED_object_editmode_exit_multi_ex(struct Main *bmain, struct Scene *scene, struct ViewLayer *view_layer, int flag)
bool ED_object_mode_set(struct bContext *C, eObjectMode mode)
void ED_outliner_select_sync_from_object_tag(struct bContext *C)
bool ED_operator_objectmode(struct bContext *C)
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum type
struct uiLayout * UI_popup_menu_layout(uiPopupMenu *pup)
void UI_popup_menu_end(struct bContext *C, struct uiPopupMenu *pup)
void uiItemStringO(uiLayout *layout, const char *name, int icon, const char *opname, const char *propname, const char *value)
uiPopupMenu * UI_popup_menu_begin(struct bContext *C, const char *title, int icon) ATTR_NONNULL()
bool ED_armature_edit_deselect_all(Object *obedit)
void ED_armature_edit_sync_selection(ListBase *edbo)
void ED_armature_ebone_select_set(EditBone *ebone, bool select)
EditBone * ED_armature_ebone_find_name(const ListBase *edbo, const char *name)
static unsigned long seed
eModifyKey_Returns ANIM_validate_keyingset(bContext *C, ListBase *dsources, KeyingSet *ks)
KeyingSet * ANIM_scene_get_active_keyingset(const Scene *scene)
static int collection_count(ListBase *lb)
bool active
all scheduled work for the GPU.
static bool object_select_all_by_instance_collection(bContext *C, Object *ob)
static const EnumPropertyItem prop_select_linked_types[]
static bool select_grouped_lighttype(bContext *C, Object *ob)
void OBJECT_OT_select_linked(wmOperatorType *ot)
static int get_base_select_priority(Base *base)
static bool select_grouped_children(bContext *C, Object *ob, const bool recursive)
static bool object_select_all_by_material(bContext *C, Material *mat)
static bool select_grouped_collection(bContext *C, Object *ob)
@ OBJECT_SELECT_LINKED_LIBRARY
@ OBJECT_SELECT_LINKED_LIBRARY_OBDATA
@ OBJECT_SELECT_LINKED_IPO
@ OBJECT_SELECT_LINKED_DUPGROUP
@ OBJECT_SELECT_LINKED_PARTICLE
@ OBJECT_SELECT_LINKED_OBDATA
@ OBJECT_SELECT_LINKED_MATERIAL
void OBJECT_OT_select_by_type(wmOperatorType *ot)
void ED_object_base_activate_with_mode_exit_if_needed(bContext *C, Base *base)
static int object_select_same_collection_exec(bContext *C, wmOperator *op)
static int object_select_all_exec(bContext *C, wmOperator *op)
bool ED_object_base_deselect_all_ex(ViewLayer *view_layer, View3D *v3d, int action, bool *r_any_visible)
@ OBJECT_GRPSEL_LIGHT_TYPE
@ OBJECT_GRPSEL_KEYINGSET
@ OBJECT_GRPSEL_CHILDREN_RECURSIVE
@ OBJECT_GRPSEL_COLLECTION
#define COLLECTION_MENU_MAX
static int object_select_linked_exec(bContext *C, wmOperator *op)
static bool object_select_more_less(bContext *C, const bool select)
void OBJECT_OT_select_grouped(wmOperatorType *ot)
void OBJECT_OT_select_less(wmOperatorType *ot)
static int object_select_mirror_exec(bContext *C, wmOperator *op)
static bool select_grouped_object_hooks(bContext *C, Object *ob)
void ED_object_select_linked_by_id(bContext *C, ID *id)
bool ED_object_jump_to_bone(bContext *C, Object *ob, const char *bone_name, const bool reveal_hidden)
static bool objects_selectable_poll(bContext *C)
static bool select_grouped_color(bContext *C, Object *ob)
void OBJECT_OT_select_same_collection(wmOperatorType *ot)
static int object_select_grouped_exec(bContext *C, wmOperator *op)
void OBJECT_OT_select_mirror(wmOperatorType *ot)
static bool select_grouped_index_object(bContext *C, Object *ob)
static bool object_select_all_by_obdata(bContext *C, void *obdata)
static bool select_grouped_siblings(bContext *C, Object *ob)
static bool select_grouped_parent(bContext *C)
void OBJECT_OT_select_all(wmOperatorType *ot)
static int object_select_less_exec(bContext *C, wmOperator *UNUSED(op))
void OBJECT_OT_select_random(wmOperatorType *ot)
static bool object_select_all_by_particle(bContext *C, Object *ob)
bool ED_object_base_deselect_all(ViewLayer *view_layer, View3D *v3d, int action)
void ED_object_base_activate(bContext *C, Base *base)
void ED_object_base_select(Base *base, eObjectSelect_Mode mode)
static int object_select_random_exec(bContext *C, wmOperator *op)
static bool object_select_all_by_library_obdata(bContext *C, Library *lib)
void ED_object_base_active_refresh(Main *bmain, Scene *scene, ViewLayer *view_layer)
static bool select_grouped_type(bContext *C, Object *ob)
static bool object_select_all_by_library(bContext *C, Library *lib)
bool ED_object_jump_to_object(bContext *C, Object *ob, const bool UNUSED(reveal_hidden))
static bool select_grouped_keyingset(bContext *C, Object *UNUSED(ob), ReportList *reports)
static int object_select_by_type_exec(bContext *C, wmOperator *op)
static const EnumPropertyItem prop_select_grouped_types[]
void OBJECT_OT_select_more(wmOperatorType *ot)
static int object_select_more_exec(bContext *C, wmOperator *UNUSED(op))
Base * ED_object_find_first_by_data_id(ViewLayer *view_layer, ID *id)
void ED_pose_bone_select_tag_update(Object *ob)
bool ED_pose_deselect_all(Object *ob, int select_mode, const bool ignore_visibility)
void ED_pose_bone_select(Object *ob, bPoseChannel *pchan, bool select)
void RNA_string_get(PointerRNA *ptr, const char *name, char *value)
float RNA_float_get(PointerRNA *ptr, const char *name)
bool RNA_boolean_get(PointerRNA *ptr, const char *name)
int RNA_enum_get(PointerRNA *ptr, const char *name)
PropertyRNA * RNA_def_boolean(StructOrFunctionRNA *cont_, const char *identifier, bool default_value, const char *ui_name, const char *ui_description)
PropertyRNA * RNA_def_string(StructOrFunctionRNA *cont_, const char *identifier, const char *default_value, int maxlen, const char *ui_name, const char *ui_description)
void RNA_def_property_translation_context(PropertyRNA *prop, const char *context)
PropertyRNA * RNA_def_enum(StructOrFunctionRNA *cont_, const char *identifier, const EnumPropertyItem *items, int default_value, const char *ui_name, const char *ui_description)
const EnumPropertyItem rna_enum_object_type_items[]
struct CollectionPointerLink * next
struct ModifierData * next
struct Collection * instance_collection
struct ParticleSystem * next
int object_type_exclude_select
struct EditBone * act_edbone
int(* invoke)(struct bContext *, struct wmOperator *, const struct wmEvent *) ATTR_WARN_UNUSED_RESULT
bool(* poll)(struct bContext *) ATTR_WARN_UNUSED_RESULT
int(* exec)(struct bContext *, struct wmOperator *) ATTR_WARN_UNUSED_RESULT
struct ReportList * reports
__forceinline const avxb select(const avxb &m, const avxb &t, const avxb &f)
void WM_main_add_notifier(unsigned int type, void *reference)
void WM_event_add_notifier(const bContext *C, uint type, void *reference)
#define WM_msg_publish_rna_prop(mbus, id_, data_, type_, prop_)
int WM_operator_properties_select_random_seed_increment_get(wmOperator *op)
void WM_operator_properties_select_random(wmOperatorType *ot)
void WM_operator_properties_select_all(wmOperatorType *ot)
int WM_menu_invoke(bContext *C, wmOperator *op, const wmEvent *UNUSED(event))