Blender
V3.3
|
#include <float.h>
#include <math.h>
#include <stdio.h>
#include <string.h>
#include "DNA_action_types.h"
#include "DNA_armature_types.h"
#include "DNA_curve_types.h"
#include "DNA_gpencil_types.h"
#include "DNA_mesh_types.h"
#include "DNA_meshdata_types.h"
#include "DNA_meta_types.h"
#include "DNA_object_types.h"
#include "DNA_scene_types.h"
#include "DNA_tracking_types.h"
#include "MEM_guardedalloc.h"
#include "BLI_array.h"
#include "BLI_bitmap.h"
#include "BLI_lasso_2d.h"
#include "BLI_linklist.h"
#include "BLI_listbase.h"
#include "BLI_math.h"
#include "BLI_rect.h"
#include "BLI_string.h"
#include "BLI_utildefines.h"
#include "BKE_global.h"
#include "BKE_main.h"
#include "IMB_imbuf.h"
#include "IMB_imbuf_types.h"
#include "BKE_action.h"
#include "BKE_armature.h"
#include "BKE_context.h"
#include "BKE_curve.h"
#include "BKE_editmesh.h"
#include "BKE_layer.h"
#include "BKE_mball.h"
#include "BKE_mesh.h"
#include "BKE_object.h"
#include "BKE_paint.h"
#include "BKE_scene.h"
#include "BKE_tracking.h"
#include "BKE_workspace.h"
#include "WM_api.h"
#include "WM_toolsystem.h"
#include "WM_types.h"
#include "RNA_access.h"
#include "RNA_define.h"
#include "RNA_enum_types.h"
#include "ED_armature.h"
#include "ED_curve.h"
#include "ED_gpencil.h"
#include "ED_lattice.h"
#include "ED_mball.h"
#include "ED_mesh.h"
#include "ED_object.h"
#include "ED_outliner.h"
#include "ED_particle.h"
#include "ED_screen.h"
#include "ED_sculpt.h"
#include "ED_select_utils.h"
#include "UI_interface.h"
#include "UI_resources.h"
#include "GPU_matrix.h"
#include "GPU_select.h"
#include "DEG_depsgraph.h"
#include "DEG_depsgraph_query.h"
#include "DRW_engine.h"
#include "DRW_select_buffer.h"
#include "view3d_intern.h"
Go to the source code of this file.
Classes | |
struct | EditSelectBuf_Cache |
struct | LassoSelectUserData |
struct | LassoSelectUserData_ForMeshEdge |
struct | SelMenuItemF |
struct | BoxSelectUserData |
struct | BoxSelectUserData_ForMeshEdge |
struct | CircleSelectUserData |
Lasso Select | |
typedef struct LassoSelectUserData | LassoSelectUserData |
static void | view3d_userdata_lassoselect_init (LassoSelectUserData *r_data, ViewContext *vc, const rcti *rect, const int(*mcoords)[2], const int mcoords_len, const eSelectOp sel_op) |
static bool | view3d_selectable_data (bContext *C) |
static bool | edge_fully_inside_rect (const rctf *rect, const float v1[2], const float v2[2]) |
static bool | edge_inside_rect (const rctf *rect, const float v1[2], const float v2[2]) |
static void | do_lasso_select_pose__do_tag (void *userData, struct bPoseChannel *pchan, const float screen_co_a[2], const float screen_co_b[2]) |
static void | do_lasso_tag_pose (ViewContext *vc, Object *ob, const int mcoords[][2], const int mcoords_len) |
static bool | do_lasso_select_objects (ViewContext *vc, const int mcoords[][2], const int mcoords_len, const eSelectOp sel_op) |
static Base ** | do_pose_tag_select_op_prepare (ViewContext *vc, uint *r_bases_len) |
static bool | do_pose_tag_select_op_exec (Base **bases, const uint bases_len, const eSelectOp sel_op) |
static bool | do_lasso_select_pose (ViewContext *vc, const int mcoords[][2], const int mcoords_len, const eSelectOp sel_op) |
static void | do_lasso_select_mesh__doSelectVert (void *userData, BMVert *eve, const float screen_co[2], int UNUSED(index)) |
static void | do_lasso_select_mesh__doSelectEdge_pass0 (void *user_data, BMEdge *eed, const float screen_co_a[2], const float screen_co_b[2], int index) |
static void | do_lasso_select_mesh__doSelectEdge_pass1 (void *user_data, BMEdge *eed, const float screen_co_a[2], const float screen_co_b[2], int index) |
static void | do_lasso_select_mesh__doSelectFace (void *userData, BMFace *efa, const float screen_co[2], int UNUSED(index)) |
static bool | do_lasso_select_mesh (ViewContext *vc, wmGenericUserData *wm_userdata, const int mcoords[][2], const int mcoords_len, const eSelectOp sel_op) |
static void | do_lasso_select_curve__doSelect (void *userData, Nurb *UNUSED(nu), BPoint *bp, BezTriple *bezt, int beztindex, bool handles_visible, const float screen_co[2]) |
static bool | do_lasso_select_curve (ViewContext *vc, const int mcoords[][2], const int mcoords_len, const eSelectOp sel_op) |
static void | do_lasso_select_lattice__doSelect (void *userData, BPoint *bp, const float screen_co[2]) |
static bool | do_lasso_select_lattice (ViewContext *vc, const int mcoords[][2], const int mcoords_len, const eSelectOp sel_op) |
static void | do_lasso_select_armature__doSelectBone (void *userData, EditBone *ebone, const float screen_co_a[2], const float screen_co_b[2]) |
static void | do_lasso_select_armature__doSelectBone_clip_content (void *userData, EditBone *ebone, const float screen_co_a[2], const float screen_co_b[2]) |
static bool | do_lasso_select_armature (ViewContext *vc, const int mcoords[][2], const int mcoords_len, const eSelectOp sel_op) |
static void | do_lasso_select_mball__doSelectElem (void *userData, struct MetaElem *ml, const float screen_co[2]) |
static bool | do_lasso_select_meta (ViewContext *vc, const int mcoords[][2], const int mcoords_len, const eSelectOp sel_op) |
static void | do_lasso_select_meshobject__doSelectVert (void *userData, MVert *mv, const float screen_co[2], int UNUSED(index)) |
static bool | do_lasso_select_paintvert (ViewContext *vc, wmGenericUserData *wm_userdata, const int mcoords[][2], const int mcoords_len, const eSelectOp sel_op) |
static bool | do_lasso_select_paintface (ViewContext *vc, wmGenericUserData *wm_userdata, const int mcoords[][2], const int mcoords_len, const eSelectOp sel_op) |
static bool | view3d_lasso_select (bContext *C, ViewContext *vc, const int mcoords[][2], const int mcoords_len, const eSelectOp sel_op) |
static int | view3d_lasso_select_exec (bContext *C, wmOperator *op) |
void | VIEW3D_OT_select_lasso (wmOperatorType *ot) |
Circle Select | |
typedef struct CircleSelectUserData | CircleSelectUserData |
static void | view3d_userdata_circleselect_init (CircleSelectUserData *r_data, ViewContext *vc, const bool select, const int mval[2], const float rad) |
static void | mesh_circle_doSelectVert (void *userData, BMVert *eve, const float screen_co[2], int UNUSED(index)) |
static void | mesh_circle_doSelectEdge (void *userData, BMEdge *eed, const float screen_co_a[2], const float screen_co_b[2], int UNUSED(index)) |
static void | mesh_circle_doSelectFace (void *userData, BMFace *efa, const float screen_co[2], int UNUSED(index)) |
static bool | mesh_circle_select (ViewContext *vc, wmGenericUserData *wm_userdata, eSelectOp sel_op, const int mval[2], float rad) |
static bool | paint_facesel_circle_select (ViewContext *vc, wmGenericUserData *wm_userdata, const eSelectOp sel_op, const int mval[2], float rad) |
static void | paint_vertsel_circle_select_doSelectVert (void *userData, MVert *mv, const float screen_co[2], int UNUSED(index)) |
static bool | paint_vertsel_circle_select (ViewContext *vc, wmGenericUserData *wm_userdata, const eSelectOp sel_op, const int mval[2], float rad) |
static void | nurbscurve_circle_doSelect (void *userData, Nurb *UNUSED(nu), BPoint *bp, BezTriple *bezt, int beztindex, bool UNUSED(handles_visible), const float screen_co[2]) |
static bool | nurbscurve_circle_select (ViewContext *vc, const eSelectOp sel_op, const int mval[2], float rad) |
static void | latticecurve_circle_doSelect (void *userData, BPoint *bp, const float screen_co[2]) |
static bool | lattice_circle_select (ViewContext *vc, const eSelectOp sel_op, const int mval[2], float rad) |
static bool | pchan_circle_doSelectJoint (void *userData, bPoseChannel *pchan, const float screen_co[2]) |
static void | do_circle_select_pose__doSelectBone (void *userData, struct bPoseChannel *pchan, const float screen_co_a[2], const float screen_co_b[2]) |
static bool | pose_circle_select (ViewContext *vc, const eSelectOp sel_op, const int mval[2], float rad) |
static bool | armature_circle_doSelectJoint (void *userData, EditBone *ebone, const float screen_co[2], bool head) |
static void | do_circle_select_armature__doSelectBone (void *userData, struct EditBone *ebone, const float screen_co_a[2], const float screen_co_b[2]) |
static void | do_circle_select_armature__doSelectBone_clip_content (void *userData, struct EditBone *ebone, const float screen_co_a[2], const float screen_co_b[2]) |
static bool | armature_circle_select (ViewContext *vc, const eSelectOp sel_op, const int mval[2], float rad) |
static void | do_circle_select_mball__doSelectElem (void *userData, struct MetaElem *ml, const float screen_co[2]) |
static bool | mball_circle_select (ViewContext *vc, const eSelectOp sel_op, const int mval[2], float rad) |
static bool | obedit_circle_select (bContext *C, ViewContext *vc, wmGenericUserData *wm_userdata, const eSelectOp sel_op, const int mval[2], float rad) |
static bool | object_circle_select (ViewContext *vc, const eSelectOp sel_op, const int mval[2], float rad) |
static void | view3d_circle_select_recalc (void *user_data) |
static int | view3d_circle_select_modal (bContext *C, wmOperator *op, const wmEvent *event) |
static void | view3d_circle_select_cancel (bContext *C, wmOperator *op) |
static int | view3d_circle_select_exec (bContext *C, wmOperator *op) |
void | VIEW3D_OT_select_circle (wmOperatorType *ot) |
#define SEL_MENU_SIZE 22 |
Definition at line 1414 of file view3d_select.c.
typedef struct BoxSelectUserData BoxSelectUserData |
typedef struct CircleSelectUserData CircleSelectUserData |
typedef struct LassoSelectUserData LassoSelectUserData |
typedef struct SelMenuItemF SelMenuItemF |
|
static |
Definition at line 4375 of file view3d_select.c.
References BONE_ROOTSEL, BONE_TIPSEL, data, EditBone::flag, and len_squared_v2v2().
Referenced by do_circle_select_armature__doSelectBone().
|
static |
Definition at line 4479 of file view3d_select.c.
References armature_foreachScreenBone(), data, Object::data, do_circle_select_armature__doSelectBone(), do_circle_select_armature__doSelectBone_clip_content(), ED_armature_edit_deselect_all_visible(), ED_armature_edit_sync_selection(), ED_armature_edit_validate_active(), ED_view3d_init_mats_rv3d(), bArmature::edbo, NC_OBJECT, ND_BONE_SELECT, ViewContext::obedit, ViewContext::rv3d, SEL_OP_SUB, SEL_OP_USE_PRE_DESELECT, select(), V3D_PROJ_TEST_CLIP_CONTENT_DEFAULT, V3D_PROJ_TEST_CLIP_DEFAULT, view3d_userdata_circleselect_init(), and WM_main_add_notifier().
Referenced by obedit_circle_select().
|
static |
Definition at line 1746 of file view3d_select.c.
References Freestyle::a, SelMenuItemF::base_ptr, BLI_assert, BLI_findlink(), BLI_gset_free(), BLI_gset_haskey(), BLI_gset_insert(), BLI_gset_ptr_new(), BLI_linklist_append(), BLI_linklist_free(), BLI_strncpy(), bPoseChannel::bone, BONE_UNSELECTABLE, BONESEL_ANY, buffer, C, bPose::chanbase, CTX_DATA_BEGIN, CTX_DATA_END, Object::data, bArmature::edbo, EditBone::flag, Bone::flag, SelMenuItemF::icon, SelMenuItemF::item_ptr, LinkNode::link, LinkNodePair::list, MAX_ID_NAME, EditBone::name, bPoseChannel::name, LinkNode::next, NULL, Base::object, object_mouse_select_menu_data, ot, params, Object::pose, ptr, RNA_boolean_set(), SEL_MENU_SIZE, SEL_OP_ADD, SEL_OP_SUB, SEL_OP_XOR, WM_OP_INVOKE_DEFAULT, WM_operator_name_call_ptr(), WM_operator_properties_create_ptr(), WM_operator_properties_free(), and WM_operatortype_find().
Referenced by ed_object_select_pick(), and view3d_select_exec().
|
static |
Definition at line 1643 of file view3d_select.c.
References BA_SELECT, BASACT, SelMenuItemF::base_ptr, BASE_SELECTABLE, BLI_assert, bPoseChannel::bone, BONE_SELECTED, C, CTX_data_scene(), CTX_data_view_layer(), CTX_wm_view3d(), DEG_id_tag_update(), ED_armature_edit_select_pick_bone(), ED_armature_pose_select_in_wpaint_mode(), ED_armature_pose_select_pick_bone(), ED_object_base_activate(), ED_object_base_select(), ED_outliner_select_sync_from_object_tag(), ED_select_op_from_operator(), Scene::id, ID_RECALC_BASE_FLAGS, ID_RECALC_SELECT, Object::mode, NC_OBJECT, NC_SCENE, ND_BONE_ACTIVE, ND_BONE_SELECT, ND_OB_SELECT, NULL, OB_MODE_ALL_WEIGHT_PAINT, OB_MODE_EDIT, Base::object, object_mouse_select_menu_data, OPERATOR_CANCELLED, OPERATOR_FINISHED, params, wmOperator::ptr, RNA_enum_get(), scene, and WM_event_add_notifier().
Referenced by VIEW3D_OT_bone_select_menu().
|
static |
Definition at line 2312 of file view3d_select.c.
References BKE_tracking_object_get_tracks(), BKE_tracking_track_deselect(), ListBase::first, MovieTracking::objects, Object::track, and TRACK_AREA_ALL.
Referenced by ed_object_select_pick_camera_track().
|
static |
Definition at line 3546 of file view3d_select.c.
References Freestyle::a, BKE_view_layer_array_from_bases_in_edit_mode_unique_data, BONESEL_ANY, buffer, Object::data, ED_armature_base_and_ebone_from_select_buffer(), ED_armature_ebone_listbase_temp_clear(), ED_armature_edit_deselect_all_visible_multi_ex(), ED_armature_edit_select_op_from_tagged(), bArmature::edbo, EditBone::i, Object::id, LIB_TAG_DOIT, MAXPICKELEMS, MEM_freeN, Base::object, SEL_OP_USE_PRE_DESELECT, ID::tag, EditBone::temp, ViewContext::v3d, view3d_opengl_select(), VIEW3D_SELECT_ALL, VIEW3D_SELECT_FILTER_NOP, and ViewContext::view_layer.
Referenced by view3d_box_select_exec().
|
static |
Definition at line 4403 of file view3d_select.c.
References armature_circle_doSelectJoint(), BONE_ROOTSEL, BONE_SELECTED, BONE_TIPSEL, data, EBONE_SELECTABLE, EBONE_VISIBLE, edge_inside_circle(), EditBone::flag, EditBone::i, IS_CLIPPED, SET_FLAG_FROM_TEST, and EditBone::temp.
Referenced by armature_circle_select().
|
static |
Definition at line 4457 of file view3d_select.c.
References BONE_ROOTSEL, BONE_SELECTED, BONE_TIPSEL, data, EBONE_SELECTABLE, EBONE_VISIBLE, edge_inside_circle(), EditBone::flag, EditBone::i, SET_FLAG_FROM_TEST, and EditBone::temp.
Referenced by armature_circle_select().
|
static |
Definition at line 4517 of file view3d_select.c.
References data, MetaElem::flag, len_squared_v2v2(), and SELECT.
Referenced by mball_circle_select().
|
static |
Definition at line 4293 of file view3d_select.c.
References bPoseChannel::bone, BONE_SELECTED, data, edge_inside_circle(), Bone::flag, IS_CLIPPED, PBONE_SELECTABLE, and pchan_circle_doSelectJoint().
Referenced by pose_circle_select().
|
static |
Definition at line 1066 of file view3d_select.c.
References armature_foreachScreenBone(), BLI_lasso_boundbox(), data, Object::data, do_lasso_select_armature__doSelectBone(), do_lasso_select_armature__doSelectBone_clip_content(), ED_armature_ebone_listbase_temp_clear(), ED_armature_edit_deselect_all_visible(), ED_armature_edit_select_op_from_tagged(), ED_view3d_init_mats_rv3d(), bArmature::edbo, NC_OBJECT, ND_BONE_SELECT, ViewContext::obedit, ViewContext::rv3d, SEL_OP_USE_PRE_DESELECT, V3D_PROJ_TEST_CLIP_CONTENT_DEFAULT, V3D_PROJ_TEST_CLIP_DEFAULT, view3d_userdata_lassoselect_init(), and WM_main_add_notifier().
Referenced by view3d_lasso_select().
|
static |
Definition at line 988 of file view3d_select.c.
References BLI_lasso_is_edge_inside(), BLI_lasso_is_point_inside(), BLI_rcti_isect_pt(), BONE_ROOTSEL, BONE_TIPSEL, BONESEL_BONE, BONESEL_ROOT, BONESEL_TIP, data, EBONE_VISIBLE, EditBone::i, IS_CLIPPED, EditBone::temp, and UNPACK2.
Referenced by do_lasso_select_armature().
|
static |
Definition at line 1037 of file view3d_select.c.
References BLI_lasso_is_edge_inside(), BONE_ROOTSEL, BONE_TIPSEL, BONESEL_BONE, data, EBONE_VISIBLE, EditBone::i, EditBone::temp, and UNPACK2.
Referenced by do_lasso_select_armature().
|
static |
Definition at line 916 of file view3d_select.c.
References BEZT_FLAG_TEMP_TAG, BKE_curve_editNurbs_get(), BKE_curve_nurb_vert_active_validate(), BKE_nurbList_flag_set(), BKE_nurbList_flag_set_from_flag(), BLI_lasso_boundbox(), curve, data, Object::data, do_lasso_select_curve__doSelect(), ED_view3d_init_mats_rv3d(), nurbs_foreachScreenVert(), ViewContext::obedit, ViewContext::rv3d, SEL_OP_SET, SELECT, V3D_PROJ_TEST_CLIP_DEFAULT, and view3d_userdata_lassoselect_init().
Referenced by view3d_lasso_select().
|
static |
Definition at line 873 of file view3d_select.c.
References BLI_lasso_is_point_inside(), data, ED_select_op_action_deselected(), BezTriple::f1, BPoint::f1, BezTriple::f2, BezTriple::f3, IS_CLIPPED, is_inside(), SELECT, and SET_FLAG_FROM_TEST.
Referenced by do_lasso_select_curve().
|
static |
Definition at line 966 of file view3d_select.c.
References BLI_lasso_boundbox(), data, do_lasso_select_lattice__doSelect(), ED_lattice_flags_set(), ED_view3d_init_mats_rv3d(), lattice_foreachScreenVert(), ViewContext::obedit, ViewContext::rv3d, SEL_OP_USE_PRE_DESELECT, V3D_PROJ_TEST_CLIP_DEFAULT, and view3d_userdata_lassoselect_init().
Referenced by view3d_lasso_select().
|
static |
Definition at line 952 of file view3d_select.c.
References BLI_lasso_is_point_inside(), BLI_rctf_isect_pt_v(), data, ED_select_op_action_deselected(), BPoint::f1, IS_CLIPPED, is_inside(), SELECT, and SET_FLAG_FROM_TEST.
Referenced by do_lasso_select_lattice().
|
static |
Definition at line 1108 of file view3d_select.c.
References BLI_lasso_is_point_inside(), BLI_rctf_isect_pt_v(), data, ED_select_op_action_deselected(), MetaElem::flag, is_inside(), SELECT, and SET_FLAG_FROM_TEST.
Referenced by do_lasso_select_meta().
|
static |
Definition at line 780 of file view3d_select.c.
References BKE_editmesh_from_object(), BLI_lasso_boundbox(), BMEditMesh::bm, BM_ELEM_SELECT, data, LassoSelectUserData_ForMeshEdge::data, wmGenericUserData::data, ViewContext::depsgraph, do_lasso_select_mesh__doSelectEdge_pass0(), do_lasso_select_mesh__doSelectEdge_pass1(), do_lasso_select_mesh__doSelectFace(), do_lasso_select_mesh__doSelectVert(), DRW_select_buffer_bitmap_from_poly(), DRW_select_buffer_context_offset_for_object_elem(), ED_view3d_init_mats_rv3d(), edbm_backbuf_check_and_select_faces(), edbm_backbuf_check_and_select_verts(), EDBM_flag_disable_all(), EDBM_selectmode_flush(), editselect_buf_cache_init_with_generic_userdata(), ViewContext::em, LassoSelectUserData_ForMeshEdge::esel, GPU_matrix_set, mesh_foreachScreenEdge_clip_bb_segment(), mesh_foreachScreenFace(), mesh_foreachScreenVert(), NULL, ViewContext::obedit, ViewContext::region, ViewContext::rv3d, SCE_SELECT_EDGE, SCE_SELECT_FACE, SCE_SELECT_VERTEX, ViewContext::scene, SEL_OP_USE_PRE_DESELECT, EditSelectBuf_Cache::select_bitmap, ToolSettings::selectmode, Scene::toolsettings, BMesh::totvertsel, ViewContext::v3d, V3D_PROJ_TEST_CLIP_BB, V3D_PROJ_TEST_CLIP_CONTENT_DEFAULT, V3D_PROJ_TEST_CLIP_DEFAULT, V3D_PROJ_TEST_CLIP_NEAR, view3d_userdata_lassoselect_init(), RegionView3D::viewmat, and XRAY_FLAG_ENABLED.
Referenced by view3d_lasso_select().
|
static |
Definition at line 707 of file view3d_select.c.
References LassoSelectUserData_ForMeshEdge::backbuf_offset, BLI_BITMAP_TEST_BOOL, BLI_lasso_is_point_inside(), BM_edge_select_set(), BM_elem_flag_test, BM_ELEM_SELECT, data, LassoSelectUserData_ForMeshEdge::data, ED_select_op_action_deselected(), edge_fully_inside_rect(), LassoSelectUserData_ForMeshEdge::esel, IS_CLIPPED, is_inside(), EditSelectBuf_Cache::select_bitmap, UNPACK2, and user_data.
Referenced by do_lasso_select_mesh().
|
static |
Definition at line 735 of file view3d_select.c.
References LassoSelectUserData_ForMeshEdge::backbuf_offset, BLI_BITMAP_TEST_BOOL, BLI_lasso_is_edge_inside(), BM_edge_select_set(), BM_elem_flag_test, BM_ELEM_SELECT, data, LassoSelectUserData_ForMeshEdge::data, ED_select_op_action_deselected(), LassoSelectUserData_ForMeshEdge::esel, IS_CLIPPED, is_inside(), EditSelectBuf_Cache::select_bitmap, UNPACK2, and user_data.
Referenced by do_lasso_select_mesh().
|
static |
Definition at line 762 of file view3d_select.c.
References BLI_lasso_is_point_inside(), BLI_rctf_isect_pt_v(), BM_elem_flag_test, BM_ELEM_SELECT, BM_face_select_set(), data, ED_select_op_action_deselected(), IS_CLIPPED, and is_inside().
Referenced by do_lasso_select_mesh().
|
static |
Definition at line 685 of file view3d_select.c.
References BLI_lasso_is_point_inside(), BLI_rctf_isect_pt_v(), BM_elem_flag_test, BM_ELEM_SELECT, BM_vert_select_set(), data, ED_select_op_action_deselected(), IS_CLIPPED, and is_inside().
Referenced by do_lasso_select_mesh().
|
static |
Definition at line 1150 of file view3d_select.c.
References BLI_lasso_is_point_inside(), BLI_rctf_isect_pt_v(), data, ED_select_op_action_deselected(), IS_CLIPPED, is_inside(), SELECT, and SET_FLAG_FROM_TEST.
Referenced by do_lasso_select_paintvert().
|
static |
Definition at line 1124 of file view3d_select.c.
References BKE_mball_deselect_all(), BLI_lasso_boundbox(), data, Object::data, do_lasso_select_mball__doSelectElem(), ED_view3d_init_mats_rv3d(), mball_foreachScreenElem(), ViewContext::obedit, ViewContext::rv3d, SEL_OP_USE_PRE_DESELECT, V3D_PROJ_TEST_CLIP_DEFAULT, and view3d_userdata_lassoselect_init().
Referenced by view3d_lasso_select().
|
static |
Definition at line 550 of file view3d_select.c.
References BA_DESELECT, BA_SELECT, BASE_SELECTABLE, BASE_SELECTED, BLI_lasso_is_point_inside(), DEG_id_tag_update(), ED_object_base_select(), ED_select_op_action_deselected(), ED_view3d_project_base(), ListBase::first, Base::flag, Scene::id, ID_RECALC_SELECT, IS_CLIPPED, is_inside(), NC_SCENE, ND_OB_SELECT, Base::next, ViewLayer::object_bases, object_deselect_all_visible(), ViewContext::region, ViewContext::scene, SEL_OP_USE_PRE_DESELECT, Base::sx, Base::sy, ViewContext::v3d, V3D_PROJ_RET_OK, ViewContext::view_layer, and WM_main_add_notifier().
Referenced by view3d_lasso_select().
|
static |
Definition at line 1228 of file view3d_select.c.
References BLI_lasso_boundbox(), ViewContext::C, Object::data, wmGenericUserData::data, ViewContext::depsgraph, DRW_select_buffer_bitmap_from_poly(), edbm_backbuf_check_and_select_faces_obmode(), editselect_buf_cache_init_with_generic_userdata(), NULL, ViewContext::obact, paintface_deselect_all_visible(), paintface_flush_flags(), ViewContext::region, SCE_SELECT_FACE, SEL_DESELECT, SEL_OP_USE_PRE_DESELECT, SELECT, EditSelectBuf_Cache::select_bitmap, Mesh::totpoly, and ViewContext::v3d.
Referenced by view3d_lasso_select().
|
static |
Definition at line 1167 of file view3d_select.c.
References BKE_mesh_mselect_validate(), BLI_lasso_boundbox(), ViewContext::C, data, Object::data, wmGenericUserData::data, ViewContext::depsgraph, do_lasso_select_meshobject__doSelectVert(), DRW_select_buffer_bitmap_from_poly(), ED_view3d_init_mats_rv3d(), edbm_backbuf_check_and_select_verts_obmode(), editselect_buf_cache_init_with_generic_userdata(), meshobject_foreachScreenVert(), NULL, ViewContext::obact, paintvert_deselect_all_visible(), paintvert_flush_flags(), paintvert_tag_select_update(), ViewContext::region, ViewContext::rv3d, SCE_SELECT_VERTEX, SEL_DESELECT, SEL_OP_CAN_DESELECT, SEL_OP_USE_PRE_DESELECT, EditSelectBuf_Cache::select_bitmap, Mesh::totvert, ViewContext::v3d, V3D_PROJ_TEST_CLIP_DEFAULT, view3d_userdata_lassoselect_init(), and XRAY_ENABLED.
Referenced by view3d_lasso_select().
|
static |
Definition at line 661 of file view3d_select.c.
References DEG_id_tag_update(), do_lasso_tag_pose(), do_pose_tag_select_op_exec(), do_pose_tag_select_op_prepare(), Scene::id, ID_RECALC_SELECT, MEM_freeN, NC_SCENE, ND_OB_SELECT, Base::object, ViewContext::scene, and WM_main_add_notifier().
Referenced by view3d_lasso_select().
|
static |
Definition at line 503 of file view3d_select.c.
References BLI_lasso_is_edge_inside(), BLI_rctf_isect_segment(), bPoseChannel::bone, BONE_DONE, data, Bone::flag, PBONE_SELECTABLE, and UNPACK2.
Referenced by do_lasso_tag_pose().
|
static |
Definition at line 521 of file view3d_select.c.
References BLI_lasso_boundbox(), data, do_lasso_select_pose__do_tag(), ED_view3d_init_mats_rv3d(), NULL, OB_ARMATURE, ViewContext::obact, Object::pose, pose_foreachScreenBone(), ViewContext::rv3d, Object::type, V3D_PROJ_TEST_CLIP_CONTENT_DEFAULT, V3D_PROJ_TEST_CLIP_DEFAULT, and view3d_userdata_lassoselect_init().
Referenced by do_lasso_select_pose().
|
static |
Definition at line 3294 of file view3d_select.c.
References data, do_lattice_box_select__doSelect(), ED_lattice_flags_set(), ED_view3d_init_mats_rv3d(), lattice_foreachScreenVert(), ViewContext::obedit, ViewContext::rv3d, SEL_OP_USE_PRE_DESELECT, V3D_PROJ_TEST_CLIP_DEFAULT, and view3d_userdata_boxselect_init().
Referenced by view3d_box_select_exec().
|
static |
Definition at line 3283 of file view3d_select.c.
References BLI_rctf_isect_pt_v(), data, ED_select_op_action_deselected(), BPoint::f1, is_inside(), SELECT, and SET_FLAG_FROM_TEST.
Referenced by do_lattice_box_select().
|
static |
Definition at line 3390 of file view3d_select.c.
References BMEditMesh::bm, BM_ELEM_SELECT, data, BoxSelectUserData_ForMeshEdge::data, wmGenericUserData::data, ViewContext::depsgraph, do_mesh_box_select__doSelectEdge_pass0(), do_mesh_box_select__doSelectEdge_pass1(), do_mesh_box_select__doSelectFace(), do_mesh_box_select__doSelectVert(), DRW_select_buffer_bitmap_from_rect(), DRW_select_buffer_context_offset_for_object_elem(), ED_view3d_init_mats_rv3d(), edbm_backbuf_check_and_select_faces(), edbm_backbuf_check_and_select_verts(), EDBM_flag_disable_all(), EDBM_selectmode_flush(), editselect_buf_cache_init_with_generic_userdata(), ViewContext::em, BoxSelectUserData_ForMeshEdge::esel, GPU_matrix_set, mesh_foreachScreenEdge_clip_bb_segment(), mesh_foreachScreenFace(), mesh_foreachScreenVert(), NULL, ViewContext::obedit, ViewContext::region, ViewContext::rv3d, SCE_SELECT_EDGE, SCE_SELECT_FACE, SCE_SELECT_VERTEX, ViewContext::scene, SEL_OP_USE_PRE_DESELECT, EditSelectBuf_Cache::select_bitmap, ToolSettings::selectmode, Scene::toolsettings, BMesh::totvertsel, ViewContext::v3d, V3D_PROJ_TEST_CLIP_BB, V3D_PROJ_TEST_CLIP_CONTENT_DEFAULT, V3D_PROJ_TEST_CLIP_DEFAULT, V3D_PROJ_TEST_CLIP_NEAR, view3d_userdata_boxselect_init(), RegionView3D::viewmat, and XRAY_FLAG_ENABLED.
Referenced by view3d_box_select_exec().
|
static |
Pass 0 operates on edges when fully inside.
Definition at line 3333 of file view3d_select.c.
References BoxSelectUserData_ForMeshEdge::backbuf_offset, BLI_BITMAP_TEST_BOOL, BM_edge_select_set(), BM_elem_flag_test, BM_ELEM_SELECT, data, BoxSelectUserData_ForMeshEdge::data, ED_select_op_action_deselected(), edge_fully_inside_rect(), BoxSelectUserData_ForMeshEdge::esel, is_inside(), and EditSelectBuf_Cache::select_bitmap.
Referenced by do_mesh_box_select().
|
static |
Pass 1 operates on edges when partially inside.
Definition at line 3357 of file view3d_select.c.
References BoxSelectUserData_ForMeshEdge::backbuf_offset, BLI_BITMAP_TEST_BOOL, BM_edge_select_set(), BM_elem_flag_test, BM_ELEM_SELECT, data, BoxSelectUserData_ForMeshEdge::data, ED_select_op_action_deselected(), edge_inside_rect(), BoxSelectUserData_ForMeshEdge::esel, is_inside(), and EditSelectBuf_Cache::select_bitmap.
Referenced by do_mesh_box_select().
|
static |
Definition at line 3376 of file view3d_select.c.
References BLI_rctf_isect_pt_v(), BM_elem_flag_test, BM_ELEM_SELECT, BM_face_select_set(), data, ED_select_op_action_deselected(), and is_inside().
Referenced by do_mesh_box_select().
|
static |
Definition at line 3311 of file view3d_select.c.
References BLI_rctf_isect_pt_v(), BM_elem_flag_test, BM_ELEM_SELECT, BM_vert_select_set(), data, ED_select_op_action_deselected(), and is_inside().
Referenced by do_mesh_box_select().
|
static |
Definition at line 3476 of file view3d_select.c.
References Freestyle::a, BKE_mball_deselect_all(), buffer, Object::data, ED_select_op_action_deselected(), MetaBall::editelems, ListBase::first, is_inside(), MAXPICKELEMS, MB_SCALE_RAD, MBALLSEL_ANY, MBALLSEL_RADIUS, MBALLSEL_STIFF, ViewContext::obedit, Object::runtime, SEL_OP_USE_PRE_DESELECT, SELECT, Object_Runtime::select_id, SET_FLAG_FROM_TEST, view3d_opengl_select(), VIEW3D_SELECT_ALL, and VIEW3D_SELECT_FILTER_NOP.
Referenced by view3d_box_select_exec().
|
static |
Definition at line 3254 of file view3d_select.c.
References BEZT_FLAG_TEMP_TAG, BKE_curve_editNurbs_get(), BKE_curve_nurb_vert_active_validate(), BKE_nurbList_flag_set(), BKE_nurbList_flag_set_from_flag(), curve, data, Object::data, do_nurbs_box_select__doSelect(), ED_view3d_init_mats_rv3d(), nurbs_foreachScreenVert(), ViewContext::obedit, ViewContext::rv3d, SEL_OP_SET, SELECT, V3D_PROJ_TEST_CLIP_DEFAULT, and view3d_userdata_boxselect_init().
Referenced by view3d_box_select_exec().
|
static |
Definition at line 3213 of file view3d_select.c.
References BLI_rctf_isect_pt_v(), data, ED_select_op_action_deselected(), BezTriple::f1, BPoint::f1, BezTriple::f2, BezTriple::f3, is_inside(), SELECT, and SET_FLAG_FROM_TEST.
Referenced by do_nurbs_box_select().
|
static |
Definition at line 3625 of file view3d_select.c.
References BA_DESELECT, BA_SELECT, BASE_SELECTABLE, BASE_SELECTED, BLI_array_append, BLI_array_declare, BLI_array_len, buffer, C, DEG_id_tag_update(), ED_armature_base_and_pchan_from_select_buffer(), ED_object_base_select(), ED_select_op_action_deselected(), ED_view3d_select_filter_from_mode(), ListBase::first, Object::id, Scene::id, ID_RECALC_SELECT, is_inside(), LIB_TAG_DOIT, LISTBASE_FOREACH, MAXPICKELEMS, MEM_freeN, MEM_mallocN, NC_SCENE, ND_OB_SELECT, NULL, ViewContext::obact, Base::object, ViewLayer::object_bases, object_deselect_all_visible(), opengl_bone_select_buffer_cmp(), ViewContext::scene, SEL_OP_USE_OUTSIDE, SEL_OP_USE_PRE_DESELECT, ID::tag, ViewContext::v3d, view3d_opengl_select(), VIEW3D_SELECT_ALL, ViewContext::view_layer, and WM_event_add_notifier().
Referenced by view3d_box_select_exec().
|
static |
Definition at line 3173 of file view3d_select.c.
References BKE_mesh_from_object(), BLI_rcti_is_empty(), ViewContext::C, wmGenericUserData::data, ViewContext::depsgraph, DRW_select_buffer_bitmap_from_rect(), edbm_backbuf_check_and_select_faces_obmode(), editselect_buf_cache_init_with_generic_userdata(), NULL, ViewContext::obact, paintface_deselect_all_visible(), paintface_flush_flags(), ViewContext::region, SCE_SELECT_FACE, SEL_DESELECT, SEL_OP_USE_PRE_DESELECT, SELECT, EditSelectBuf_Cache::select_bitmap, Mesh::totpoly, and ViewContext::v3d.
Referenced by view3d_box_select_exec().
|
static |
Definition at line 3117 of file view3d_select.c.
References BKE_mesh_mselect_validate(), BLI_rcti_is_empty(), ViewContext::C, data, Object::data, wmGenericUserData::data, ViewContext::depsgraph, do_paintvert_box_select__doSelectVert(), DRW_select_buffer_bitmap_from_rect(), ED_view3d_init_mats_rv3d(), edbm_backbuf_check_and_select_verts_obmode(), editselect_buf_cache_init_with_generic_userdata(), meshobject_foreachScreenVert(), NULL, ViewContext::obact, OPERATOR_CANCELLED, paintvert_deselect_all_visible(), paintvert_flush_flags(), paintvert_tag_select_update(), ViewContext::region, ViewContext::rv3d, SCE_SELECT_VERTEX, SEL_DESELECT, SEL_OP_CAN_DESELECT, SEL_OP_USE_PRE_DESELECT, EditSelectBuf_Cache::select_bitmap, Mesh::totvert, ViewContext::v3d, V3D_PROJ_TEST_CLIP_DEFAULT, view3d_userdata_boxselect_init(), and XRAY_ENABLED.
Referenced by view3d_box_select_exec().
|
static |
Definition at line 3103 of file view3d_select.c.
References BLI_rctf_isect_pt_v(), data, ED_select_op_action_deselected(), is_inside(), SELECT, and SET_FLAG_FROM_TEST.
Referenced by do_paintvert_box_select().
|
static |
Definition at line 3701 of file view3d_select.c.
References BLI_findlink(), bPoseChannel::bone, BONE_DONE, BONESEL_ANY, buffer, C, bPose::chanbase, DEG_id_tag_update(), do_pose_tag_select_op_exec(), do_pose_tag_select_op_prepare(), ED_armature_base_and_bone_from_select_buffer(), ED_view3d_select_filter_from_mode(), Bone::flag, GPUSelectResult::id, Object::id, Scene::id, ID_RECALC_SELECT, LIB_TAG_DOIT, MAXPICKELEMS, MEM_freeN, MEM_mallocN, NC_SCENE, ND_OB_SELECT, NULL, ViewContext::obact, Base::object, opengl_bone_select_buffer_cmp(), Object::pose, Object::runtime, ViewContext::scene, Object_Runtime::select_id, ID::tag, view3d_opengl_select(), VIEW3D_SELECT_ALL, and WM_event_add_notifier().
Referenced by view3d_box_select_exec().
|
static |
Definition at line 607 of file view3d_select.c.
References bArmature::act_bone, BONE_DONE, BONE_SELECTED, BONE_UNSELECTABLE, bPose::chanbase, Object::data, ED_pose_bone_select_tag_update(), ED_pose_deselect_all(), ED_select_op_action_deselected(), Bone::flag, bArmature::id, is_inside(), LIB_TAG_DOIT, LISTBASE_FOREACH, NULL, Base::object, Object::pose, SEL_DESELECT, SEL_OP_USE_PRE_DESELECT, SET_FLAG_FROM_TEST, and ID::tag.
Referenced by do_lasso_select_pose(), and do_pose_box_select().
|
static |
Use for lasso & box select.
Definition at line 587 of file view3d_select.c.
References BLI_array_append, BLI_array_declare, BLI_array_len, BONE_DONE, bPose::chanbase, Object::data, Bone::flag, FOREACH_BASE_IN_MODE_BEGIN, FOREACH_BASE_IN_MODE_END, bArmature::id, Object::id, LIB_TAG_DOIT, LISTBASE_FOREACH, NULL, OB_ARMATURE, OB_MODE_POSE, Object::pose, ID::tag, ViewContext::v3d, and ViewContext::view_layer.
Referenced by do_lasso_select_pose(), and do_pose_box_select().
|
static |
Cursor selection picking for object & pose-mode.
mval | Region relative cursor coordinates. |
params | Selection parameters. |
center | Select by the cursors on-screen distances to the center/origin instead of the geometry any other contents of the item being selected. This could be used to select by bones by their origin too, currently it's only used for objects. |
enumerate | Show a menu for objects at the cursor location. Otherwise fall-through to non-menu selection. |
object_only | Only select objects (not bones / track markers). |
Definition at line 2430 of file view3d_select.c.
References ARRAY_SIZE, BA_DESELECT, BA_SELECT, BASACT, BASE_SELECTABLE, BASE_SELECTED, BKE_object_is_mode_compat(), BKE_object_movieclip_get(), BLI_assert, BLI_assert_unreachable, ViewContext::bmain, bone_mouse_select_menu(), buffer, C, center, CTX_data_ensure_evaluated_depsgraph(), DEG_id_tag_update(), depsgraph, ViewContext::depsgraph, ED_armature_pose_select_in_wpaint_mode(), ED_armature_pose_select_pick_with_buffer(), ED_object_base_activate(), ED_object_base_select(), ED_object_mode_generic_exit(), ed_object_select_pick_camera_track(), ED_outliner_select_sync_from_object_tag(), ED_outliner_select_sync_from_pose_bone_tag(), ED_view3d_select_filter_from_mode(), ED_view3d_viewcontext_init(), FIRSTBASE, Base::flag, Scene::id, ID_RECALC_SELECT, MAXPICKELEMS, MEM_freeN, MEM_mallocN, mixed_bones_object_selectbuffer_extended(), Object::mode, mouse_select_eval_buffer(), mouse_select_object_center(), NC_OBJECT, NC_SCENE, ND_BONE_ACTIVE, ND_BONE_SELECT, ND_OB_SELECT, Base::next, NULL, OB_CAMERA, OB_MODE_ALL_WEIGHT_PAINT, OB_MODE_OBJECT, OB_MODE_POSE, ViewContext::obact, ViewContext::obedit, Base::object, object_deselect_all_except(), ToolSettings::object_flag, object_mouse_select_menu(), params, SCE_OBJECT_MODE_LOCK, scene, ViewContext::scene, SEL_OP_ADD, SEL_OP_AND, SEL_OP_SET, SEL_OP_SUB, SEL_OP_XOR, selectbuffer_has_bones(), Scene::toolsettings, Object::type, ViewContext::v3d, VIEW3D_SELECT_FILTER_NOP, ViewContext::view_layer, WM_event_add_notifier(), and WM_toolsystem_update_from_context_view3d().
Referenced by view3d_select_exec().
|
static |
Definition at line 2331 of file view3d_select.c.
References BKE_tracking_track_deselect(), BKE_tracking_track_get_indexed(), BKE_tracking_track_select(), BLI_assert_unreachable, buffer, C, DEG_id_tag_update(), deselect_all_tracks(), MovieClip::id, Scene::id, ID_RECALC_SELECT, NC_MOVIECLIP, NC_SCENE, ND_OB_SELECT, ND_SELECT, NULL, Base::object, params, Object::runtime, scene, SEL_OP_ADD, SEL_OP_AND, SEL_OP_SET, SEL_OP_SUB, SEL_OP_XOR, Object_Runtime::select_id, Object::track, TRACK_AREA_ALL, TRACK_SELECTED, MovieClip::tracking, and WM_event_add_notifier().
Referenced by ed_object_select_pick().
mval
comes from event->mval, only use within region handlers.
Definition at line 2282 of file view3d_select.c.
References C, ed_view3d_give_base_under_cursor_ex(), and NULL.
Referenced by datadropper_id_sample_pt(), ED_view3d_give_object_under_cursor(), and object_transfer_mode_invoke().
|
static |
Definition at line 2247 of file view3d_select.c.
References ARRAY_SIZE, BKE_object_update_select_id(), buffer, C, CTX_data_ensure_evaluated_depsgraph(), CTX_data_main(), depsgraph, ED_view3d_viewcontext_init(), MAXPICKELEMS, mixed_bones_object_selectbuffer(), mouse_select_eval_buffer(), NULL, selectbuffer_has_bones(), ViewContext::v3d, view3d_operator_needs_opengl(), VIEW3D_SELECT_FILTER_NOP, and XRAY_ACTIVE.
Referenced by ED_view3d_give_base_under_cursor(), and ED_view3d_give_material_slot_under_cursor().
struct Object* ED_view3d_give_material_slot_under_cursor | ( | struct bContext * | C, |
const int | mval[2], | ||
int * | r_material_slot | ||
) |
Definition at line 2296 of file view3d_select.c.
References C, ed_view3d_give_base_under_cursor_ex(), NULL, and Base::object.
Referenced by drop_named_material_invoke(), and ED_object_ot_drop_named_material_tooltip().
Definition at line 2287 of file view3d_select.c.
References C, ED_view3d_give_base_under_cursor(), NULL, and Base::object.
Referenced by ED_view3d_is_object_under_cursor(), empty_drop_named_image_invoke(), and view3d_ima_empty_drop_poll().
Definition at line 2307 of file view3d_select.c.
References C, ED_view3d_give_object_under_cursor(), and NULL.
Referenced by view3d_ima_bg_drop_poll().
Definition at line 101 of file view3d_select.c.
Referenced by curve_pen_invoke(), curve_pen_modal(), ED_curve_editfont_select_pick(), ED_curve_pick_vert(), edbm_elem_find_nearest(), findnearestLattvert(), get_closest_vertex_to_point_in_nurbs(), gizmo_preselect_edgering_test_select(), gizmo_preselect_elem_test_select(), insert_point_to_segment(), loopcut_mouse_move(), mouse_select_object_center(), pe_deflect_emitter(), pe_nearest_point_and_key(), unified_findnearest(), and view3d_select_exec().
void ED_view3d_viewcontext_init | ( | bContext * | C, |
ViewContext * | vc, | ||
Depsgraph * | depsgraph | ||
) |
Definition at line 106 of file view3d_select.c.
References ViewContext::bmain, ViewContext::C, C, CTX_data_active_object(), CTX_data_edit_object(), CTX_data_main(), CTX_data_scene(), CTX_data_view_layer(), CTX_wm_region(), CTX_wm_region_view3d(), CTX_wm_view3d(), CTX_wm_window(), depsgraph, ViewContext::depsgraph, ViewContext::obact, ViewContext::obedit, ViewContext::region, ViewContext::rv3d, ViewContext::scene, ViewContext::v3d, ViewContext::view_layer, and ViewContext::win.
Referenced by add_vertex_invoke(), clip_planes_from_rect(), curve_draw_init(), curve_pen_invoke(), curve_pen_modal(), ED_armature_edit_deselect_all_visible_multi(), ED_armature_edit_select_pick(), ed_armature_pick_bone_impl(), ED_curve_deselect_all_multi(), ED_curve_editfont_select_pick(), ED_curve_editnurb_select_pick(), ED_lattice_deselect_all_multi(), ED_lattice_select_pick(), ED_mball_deselect_all_multi(), ed_mball_findnearest_metaelem(), ED_mesh_pick_face(), ED_mesh_pick_vert(), ed_object_select_pick(), ED_pose_deselect_all_multi(), ED_sculpt_update_modal_transform(), ed_view3d_give_base_under_cursor_ex(), EDBM_mesh_deselect_all_multi(), EDBM_selectmode_disable_multi(), edcu_shortest_path_pick_invoke(), em_setup_viewcontext(), object_transform_axis_target_invoke(), paint_cursor_context_init(), paint_sample_color(), paint_stroke_new(), PE_set_view3d_data(), sample_detail(), SCULPT_cursor_geometry_info_update(), SCULPT_filter_cache_init(), sculpt_gesture_context_init_common(), SCULPT_stroke_get_location(), select_linked_pick_invoke(), blender::ed::sculpt_paint::image::ops::paint::texture_paint_init(), view3d_box_select_exec(), view3d_circle_select_exec(), view3d_circle_select_recalc(), view3d_lasso_select_exec(), view3d_select_exec(), vpaint_init_vpaint(), weight_paint_sample_enum_itemf(), weight_sample_group_exec(), weight_sample_invoke(), and wpaint_stroke_test_start().
void ED_view3d_viewcontext_init_object | ( | struct ViewContext * | vc, |
struct Object * | obact | ||
) |
Re-initialize vc
with obact
as if it's active object (with some differences).
This is often used when operating on multiple objects in modes (edit, pose mode etc) where the vc
is passed in as an argument which then references it's object data.
vc
to explicitly disable edit-mode operation (to force object selection in edit-mode for e.g.). So object-mode specific values should remain cleared when initialized with another object. Definition at line 124 of file view3d_select.c.
References BKE_editmesh_from_object(), BKE_object_is_in_editmode(), BLI_assert, ViewContext::em, ViewContext::obact, and ViewContext::obedit.
Referenced by ED_curve_pick_vert_ex(), ED_lattice_select_pick(), edbm_dupli_extrude_cursor_invoke(), EDBM_edge_find_nearest_ex(), EDBM_face_find_nearest_ex(), edbm_preselect_or_active_init_viewcontext(), edbm_select_linked_pick_invoke(), EDBM_select_pick(), edbm_shortest_path_pick_invoke(), EDBM_unified_findnearest_from_raycast(), EDBM_vert_find_nearest_ex(), edcu_shortest_path_pick_invoke(), findnearestLattvert(), knifeproject_exec(), loopcut_init(), loopcut_mouse_move(), mouse_mesh_loop(), view3d_box_select_exec(), view3d_circle_select_exec(), view3d_circle_select_recalc(), and view3d_lasso_select().
|
static |
Mouse selection in weight paint. Called via generic mouse select operator.
Definition at line 2802 of file view3d_select.c.
References BKE_mesh_mselect_active_set(), BKE_mesh_mselect_validate(), BLI_assert_unreachable, C, CTX_wm_view3d(), Object::data, ED_MESH_PICK_DEFAULT_VERT_DIST, ED_mesh_pick_vert(), MVert::flag, ME_VSEL, Mesh::mvert, paintface_deselect_all_visible(), paintvert_deselect_all_visible(), paintvert_flush_flags(), paintvert_tag_select_update(), params, SEL_DESELECT, SEL_OP_ADD, SEL_OP_AND, SEL_OP_SET, SEL_OP_SUB, SEL_OP_XOR, SELECT, and XRAY_ENABLED.
Referenced by view3d_select_exec().
|
static |
Definition at line 268 of file view3d_select.c.
References BLI_BITMAP_TEST_BOOL, BMEditMesh::bm, BM_edge_select_set(), BM_EDGES_OF_MESH, BM_elem_flag_test, BM_ELEM_HIDDEN, BM_ELEM_SELECT, BM_ITER_MESH, depsgraph, DRW_select_buffer_context_offset_for_object_elem(), ED_select_op_action_deselected(), is_inside(), SCE_SELECT_EDGE, and EditSelectBuf_Cache::select_bitmap.
Referenced by mesh_circle_select().
|
static |
Definition at line 300 of file view3d_select.c.
References BLI_BITMAP_TEST_BOOL, BMEditMesh::bm, BM_elem_flag_test, BM_ELEM_HIDDEN, BM_ELEM_SELECT, BM_face_select_set(), BM_FACES_OF_MESH, BM_ITER_MESH, depsgraph, DRW_select_buffer_context_offset_for_object_elem(), ED_select_op_action_deselected(), is_inside(), SCE_SELECT_FACE, and EditSelectBuf_Cache::select_bitmap.
Referenced by do_lasso_select_mesh(), do_mesh_box_select(), and mesh_circle_select().
|
static |
Definition at line 360 of file view3d_select.c.
References BLI_BITMAP_TEST_BOOL, ED_select_op_action_deselected(), MPoly::flag, is_inside(), ME_FACE_SEL, ME_HIDE, Mesh::mpoly, EditSelectBuf_Cache::select_bitmap, SET_FLAG_FROM_TEST, and Mesh::totpoly.
Referenced by do_lasso_select_paintface(), do_paintface_box_select(), and paint_facesel_circle_select().
|
static |
Definition at line 236 of file view3d_select.c.
References BLI_BITMAP_TEST_BOOL, BMEditMesh::bm, BM_elem_flag_test, BM_ELEM_HIDDEN, BM_ELEM_SELECT, BM_ITER_MESH, BM_vert_select_set(), BM_VERTS_OF_MESH, depsgraph, DRW_select_buffer_context_offset_for_object_elem(), ED_select_op_action_deselected(), is_inside(), SCE_SELECT_VERTEX, and EditSelectBuf_Cache::select_bitmap.
Referenced by do_lasso_select_mesh(), do_mesh_box_select(), and mesh_circle_select().
|
static |
Definition at line 333 of file view3d_select.c.
References BLI_BITMAP_TEST_BOOL, ED_select_op_action_deselected(), is_inside(), ME_HIDE, Mesh::mvert, SELECT, EditSelectBuf_Cache::select_bitmap, SET_FLAG_FROM_TEST, and Mesh::totvert.
Referenced by do_lasso_select_paintvert(), do_paintvert_box_select(), and paint_vertsel_circle_select().
|
static |
Definition at line 459 of file view3d_select.c.
References BLI_rctf_isect_pt_v(), v1, and v2.
Referenced by do_lasso_select_mesh__doSelectEdge_pass0(), do_mesh_box_select__doSelectEdge_pass0(), and edge_inside_rect().
bool edge_inside_circle | ( | const float | cent[2], |
float | radius, | ||
const float | screen_co_a[2], | ||
const float | screen_co_b[2] | ||
) |
XXX: should move to BLI_math
Definition at line 3094 of file view3d_select.c.
References dist_squared_to_line_segment_v2().
Referenced by do_circle_select_armature__doSelectBone(), do_circle_select_armature__doSelectBone_clip_content(), do_circle_select_pose__doSelectBone(), gpencil_stroke_inside_circle(), and mesh_circle_doSelectEdge().
Definition at line 464 of file view3d_select.c.
References edge_fully_inside_rect(), v1, v2, rctf::xmax, rctf::xmin, rctf::ymax, and rctf::ymin.
Referenced by do_mesh_box_select__doSelectEdge_pass1().
|
static |
Definition at line 208 of file view3d_select.c.
References MEM_SAFE_FREE, and EditSelectBuf_Cache::select_bitmap.
Referenced by editselect_buf_cache_free_voidp().
Definition at line 213 of file view3d_select.c.
References editselect_buf_cache_free(), and MEM_freeN.
Referenced by editselect_buf_cache_init_with_generic_userdata().
|
static |
Definition at line 189 of file view3d_select.c.
References BKE_view_layer_array_from_bases_in_edit_mode, BKE_view_layer_base_find(), DRW_select_buffer_context_create(), MEM_freeN, ViewContext::obact, ViewContext::obedit, ViewContext::v3d, and ViewContext::view_layer.
Referenced by editselect_buf_cache_init_with_generic_userdata().
|
static |
Definition at line 219 of file view3d_select.c.
References wmGenericUserData::data, editselect_buf_cache_free_voidp(), editselect_buf_cache_init(), wmGenericUserData::free_fn, MEM_callocN, and wmGenericUserData::use_free.
Referenced by do_lasso_select_mesh(), do_lasso_select_paintface(), do_lasso_select_paintvert(), do_mesh_box_select(), do_paintface_box_select(), do_paintvert_box_select(), mesh_circle_select(), paint_facesel_circle_select(), and paint_vertsel_circle_select().
Compare result of 'GPU_select': 'GPUSelectResult', Needed for stable sorting, so cycling through all items near the cursor behaves predictably.
Definition at line 2052 of file view3d_select.c.
References Freestyle::a, usdtokens::b(), and BLI_endian_switch_uint32().
Referenced by mouse_select_eval_buffer().
|
static |
Definition at line 4253 of file view3d_select.c.
References data, ED_lattice_flags_set(), ED_view3d_init_mats_rv3d(), lattice_foreachScreenVert(), latticecurve_circle_doSelect(), ViewContext::obedit, ViewContext::rv3d, SEL_OP_SUB, SEL_OP_USE_PRE_DESELECT, select(), V3D_PROJ_TEST_CLIP_DEFAULT, and view3d_userdata_circleselect_init().
Referenced by obedit_circle_select().
|
static |
Definition at line 4244 of file view3d_select.c.
References data, BPoint::f1, len_squared_v2v2(), and SELECT.
Referenced by lattice_circle_select().
|
static |
Definition at line 4533 of file view3d_select.c.
References BKE_mball_deselect_all(), data, Object::data, do_circle_select_mball__doSelectElem(), ED_view3d_init_mats_rv3d(), mball_foreachScreenElem(), ViewContext::obedit, ViewContext::rv3d, SEL_OP_SUB, SEL_OP_USE_PRE_DESELECT, select(), V3D_PROJ_TEST_CLIP_DEFAULT, and view3d_userdata_circleselect_init().
Referenced by obedit_circle_select().
|
static |
Definition at line 3960 of file view3d_select.c.
References BM_edge_select_set(), data, and edge_inside_circle().
Referenced by mesh_circle_select().
|
static |
Definition at line 3973 of file view3d_select.c.
References BM_face_select_set(), data, and len_squared_v2v2().
Referenced by mesh_circle_select().
|
static |
Definition at line 3948 of file view3d_select.c.
References BM_vert_select_set(), data, and len_squared_v2v2().
Referenced by mesh_circle_select().
|
static |
Definition at line 3986 of file view3d_select.c.
References BKE_editmesh_from_object(), BMEditMesh::bm, BM_ELEM_SELECT, BM_mesh_select_mode_flush_ex(), BM_SELECT_LEN_FLUSH_RECALC_NOTHING, data, wmGenericUserData::data, ViewContext::depsgraph, DRW_select_buffer_bitmap_from_circle(), ED_view3d_init_mats_rv3d(), edbm_backbuf_check_and_select_edges(), edbm_backbuf_check_and_select_faces(), edbm_backbuf_check_and_select_verts(), EDBM_flag_disable_all(), editselect_buf_cache_init_with_generic_userdata(), ViewContext::em, mesh_circle_doSelectEdge(), mesh_circle_doSelectFace(), mesh_circle_doSelectVert(), mesh_foreachScreenEdge_clip_bb_segment(), mesh_foreachScreenFace(), mesh_foreachScreenVert(), NULL, ViewContext::obedit, ViewContext::region, ViewContext::rv3d, SCE_SELECT_EDGE, SCE_SELECT_FACE, SCE_SELECT_VERTEX, ViewContext::scene, SEL_OP_ADD, SEL_OP_SUB, SEL_OP_USE_PRE_DESELECT, select(), EditSelectBuf_Cache::select_bitmap, BMEditMesh::selectmode, ToolSettings::selectmode, Scene::toolsettings, BMesh::totedgesel, BMesh::totfacesel, BMesh::totvertsel, ViewContext::v3d, V3D_PROJ_TEST_CLIP_BB, V3D_PROJ_TEST_CLIP_CONTENT_DEFAULT, V3D_PROJ_TEST_CLIP_DEFAULT, V3D_PROJ_TEST_CLIP_NEAR, view3d_userdata_circleselect_init(), and XRAY_FLAG_ENABLED.
Referenced by obedit_circle_select().
|
static |
Populate a select buffer with objects and bones, if there are any. Checks three selection levels and compare.
do_nearest_xray_if_supported | When set, read in hits that don't stop at the nearest surface. The hits must still be ordered by depth. Needed so we can step to the next, non-active object when it's already selected, see: T76445. |
Definition at line 1918 of file view3d_select.c.
References BLI_rcti_init_pt_radius(), buffer, selectbuffer_has_bones(), selectbuffer_ret_hits_15(), selectbuffer_ret_hits_5(), selectbuffer_ret_hits_9(), USER_GPU_FLAG_NO_DEPT_PICK, view3d_opengl_select(), view3d_opengl_select_cache_begin(), view3d_opengl_select_cache_end(), view3d_opengl_select_ex(), VIEW3D_SELECT_PICK_ALL, and VIEW3D_SELECT_PICK_NEAREST.
Referenced by ed_view3d_give_base_under_cursor_ex(), mixed_bones_object_selectbuffer_extended(), and view3d_select_exec().
|
static |
Definition at line 2010 of file view3d_select.c.
References buffer, mixed_bones_object_selectbuffer(), ViewContext::v3d, WM_cursor_test_motion_and_update(), and XRAY_ACTIVE.
Referenced by ed_object_select_pick().
|
static |
has_bones | When true, skip non-bone hits, also allow bases to be used that are visible but not select-able, since you may be in pose mode with an un-selectable object. |
Definition at line 2089 of file view3d_select.c.
References Freestyle::a, BASACT, BASE_SELECTABLE, BASE_SELECTED, BASE_VISIBLE, buffer, FIRSTBASE, gpu_select_buffer_depth_id_cmp(), MEM_freeN, MEM_mallocN, min, NULL, ViewContext::v3d, and ViewContext::view_layer.
Referenced by ed_object_select_pick(), and ed_view3d_give_base_under_cursor_ex().
|
static |
Definition at line 2204 of file view3d_select.c.
References BASACT, BASE_SELECTABLE, ED_view3d_project_float_global(), ED_view3d_select_dist_px(), FIRSTBASE, float(), len_manhattan_v2v2(), Base::next, NULL, Base::object, Object::obmat, ViewContext::region, UI_DPI_FAC, ViewContext::v3d, V3D_PROJ_RET_OK, V3D_PROJ_TEST_CLIP_DEFAULT, and ViewContext::view_layer.
Referenced by ed_object_select_pick().
|
static |
Definition at line 4183 of file view3d_select.c.
References data, BezTriple::f1, BPoint::f1, BezTriple::f2, BezTriple::f3, len_squared_v2v2(), and SET_FLAG_FROM_TEST.
Referenced by nurbscurve_circle_select().
|
static |
Definition at line 4211 of file view3d_select.c.
References BEZT_FLAG_TEMP_TAG, BKE_curve_editNurbs_get(), BKE_curve_nurb_vert_active_validate(), BKE_nurbList_flag_set(), BKE_nurbList_flag_set_from_flag(), curve, data, Object::data, ED_view3d_init_mats_rv3d(), nurbs_foreachScreenVert(), nurbscurve_circle_doSelect(), ViewContext::obedit, ViewContext::rv3d, SEL_OP_SET, SEL_OP_SUB, select(), SELECT, V3D_PROJ_TEST_CLIP_DEFAULT, and view3d_userdata_circleselect_init().
Referenced by obedit_circle_select().
|
static |
Callbacks for circle selection in Editmode
Definition at line 4558 of file view3d_select.c.
References armature_circle_select(), BLI_assert, C, Object::data, DEG_id_tag_update(), ED_outliner_select_sync_from_edit_bone_tag(), ELEM, ID_RECALC_SELECT, lattice_circle_select(), mball_circle_select(), mesh_circle_select(), NC_GEOM, ND_SELECT, nurbscurve_circle_select(), OB_ARMATURE, OB_CURVES_LEGACY, OB_LATTICE, OB_MBALL, OB_MESH, OB_SURF, ViewContext::obact, ViewContext::obedit, SEL_OP_ADD, SEL_OP_SET, SEL_OP_SUB, Object::type, and WM_main_add_notifier().
Referenced by view3d_circle_select_exec().
|
static |
Definition at line 4599 of file view3d_select.c.
References BA_DESELECT, BA_SELECT, BASE_SELECTABLE, BASE_SELECTED, BLI_assert, ED_object_base_select(), ED_view3d_project_float_global(), ELEM, FIRSTBASE, Base::flag, len_squared_v2v2(), Base::next, Base::object, object_deselect_all_visible(), Object::obmat, ViewContext::region, SEL_OP_ADD, SEL_OP_SET, SEL_OP_SUB, SEL_OP_USE_PRE_DESELECT, select(), ViewContext::v3d, V3D_PROJ_RET_OK, V3D_PROJ_TEST_CLIP_DEFAULT, and ViewContext::view_layer.
Referenced by view3d_circle_select_exec().
Definition at line 158 of file view3d_select.c.
References usdtokens::b(), BA_DESELECT, BASE_SELECTED, ED_object_base_select(), LISTBASE_FOREACH, and ViewLayer::object_bases.
Referenced by ed_object_select_pick(), and object_select_menu_exec().
Definition at line 143 of file view3d_select.c.
References BA_DESELECT, BASE_SELECTABLE, BASE_SELECTED, ED_object_base_select(), LISTBASE_FOREACH, and ViewLayer::object_bases.
Referenced by do_lasso_select_objects(), do_object_box_select(), and object_circle_select().
|
static |
Definition at line 1555 of file view3d_select.c.
References Freestyle::a, BLI_linklist_append(), BLI_linklist_free(), BLI_strncpy(), buffer, C, CTX_DATA_BEGIN, CTX_DATA_END, ED_view3d_project_base(), SelMenuItemF::icon, Object::id, len_manhattan_v2_int(), LinkNode::link, LinkNodePair::list, MAX_ID_NAME, ID::name, node, NULL, Base::object, object_mouse_select_menu_data, ot, params, ptr, ViewContext::region, RNA_boolean_set(), SEL_MENU_SIZE, SEL_OP_ADD, SEL_OP_SUB, SEL_OP_XOR, UI_icon_from_id(), V3D_PROJ_RET_OK, WM_OP_INVOKE_DEFAULT, WM_operator_name_call_ptr(), WM_operator_properties_create_ptr(), WM_operator_properties_free(), and WM_operatortype_find().
Referenced by ed_object_select_pick().
|
static |
Definition at line 1418 of file view3d_select.c.
References C, DummyRNA_NULL_items, SelMenuItemF::icon, SelMenuItemF::idname, EnumPropertyItem::name, NULL, object_mouse_select_menu_data, RNA_enum_item_add(), RNA_enum_item_end(), and SEL_MENU_SIZE.
Referenced by VIEW3D_OT_bone_select_menu(), and VIEW3D_OT_select_menu().
|
static |
Definition at line 1446 of file view3d_select.c.
References BA_DESELECT, BA_SELECT, BASACT, BASE_SELECTABLE, BASE_SELECTED, BLI_assert, C, CTX_DATA_BEGIN, CTX_DATA_END, CTX_data_scene(), CTX_data_view_layer(), CTX_wm_view3d(), DEG_id_tag_update(), ED_object_base_activate(), ED_object_base_select(), ED_outliner_select_sync_from_object_tag(), Base::flag, Scene::id, ID_RECALC_SELECT, SelMenuItemF::idname, NC_SCENE, ND_OB_SELECT, NULL, object_deselect_all_except(), object_mouse_select_menu_data, OPERATOR_CANCELLED, OPERATOR_FINISHED, wmOperator::ptr, RNA_boolean_get(), RNA_enum_get(), scene, STREQ, UNUSED_VARS_NDEBUG, and WM_event_add_notifier().
Referenced by VIEW3D_OT_select_menu().
Compare result of 'GPU_select': 'GPUSelectResult', needed for when we need to align with object draw-order.
Definition at line 3606 of file view3d_select.c.
References BLI_endian_switch_uint32().
Referenced by do_object_box_select(), and do_pose_box_select().
|
static |
Definition at line 4077 of file view3d_select.c.
References BLI_assert, ViewContext::C, Object::data, wmGenericUserData::data, ViewContext::depsgraph, DRW_select_buffer_bitmap_from_circle(), edbm_backbuf_check_and_select_faces_obmode(), editselect_buf_cache_init_with_generic_userdata(), ELEM, MEM_freeN, NULL, ViewContext::obact, paintface_deselect_all_visible(), paintface_flush_flags(), ViewContext::region, SCE_SELECT_FACE, SEL_DESELECT, SEL_OP_ADD, SEL_OP_SET, SEL_OP_SUB, SEL_OP_USE_PRE_DESELECT, SELECT, EditSelectBuf_Cache::select_bitmap, and ViewContext::v3d.
Referenced by view3d_circle_select_exec().
|
static |
Definition at line 4126 of file view3d_select.c.
References BKE_mesh_mselect_validate(), BLI_assert, ViewContext::C, data, Object::data, wmGenericUserData::data, ViewContext::depsgraph, DRW_select_buffer_bitmap_from_circle(), ED_view3d_init_mats_rv3d(), edbm_backbuf_check_and_select_verts_obmode(), editselect_buf_cache_init_with_generic_userdata(), ELEM, MEM_freeN, meshobject_foreachScreenVert(), NULL, ViewContext::obact, paint_vertsel_circle_select_doSelectVert(), paintvert_deselect_all_visible(), paintvert_flush_flags(), paintvert_tag_select_update(), ViewContext::region, ViewContext::rv3d, SCE_SELECT_VERTEX, SEL_DESELECT, SEL_OP_ADD, SEL_OP_SET, SEL_OP_SUB, SEL_OP_USE_PRE_DESELECT, select(), EditSelectBuf_Cache::select_bitmap, ViewContext::v3d, V3D_PROJ_TEST_CLIP_DEFAULT, view3d_userdata_circleselect_init(), and XRAY_ENABLED.
Referenced by view3d_circle_select_exec().
|
static |
Definition at line 4114 of file view3d_select.c.
References data, len_squared_v2v2(), SELECT, and SET_FLAG_FROM_TEST.
Referenced by paint_vertsel_circle_select().
|
static |
Definition at line 4276 of file view3d_select.c.
References bPoseChannel::bone, BONE_SELECTED, data, Bone::flag, and len_squared_v2v2().
Referenced by do_circle_select_pose__doSelectBone().
|
static |
Definition at line 4343 of file view3d_select.c.
References BLI_assert, data, do_circle_select_pose__doSelectBone(), ED_pose_bone_select_tag_update(), ED_pose_deselect_all(), ED_view3d_init_mats_rv3d(), ELEM, ViewContext::obact, pose_foreachScreenBone(), ViewContext::rv3d, SEL_DESELECT, SEL_OP_ADD, SEL_OP_SET, SEL_OP_SUB, SEL_OP_USE_PRE_DESELECT, select(), V3D_PROJ_TEST_CLIP_CONTENT_DEFAULT, V3D_PROJ_TEST_CLIP_DEFAULT, and view3d_userdata_circleselect_init().
Referenced by view3d_circle_select_exec().
|
static |
Definition at line 1877 of file view3d_select.c.
References buffer.
Referenced by ed_object_select_pick(), ed_view3d_give_base_under_cursor_ex(), and mixed_bones_object_selectbuffer().
|
static |
Definition at line 1888 of file view3d_select.c.
Referenced by mixed_bones_object_selectbuffer().
|
static |
Definition at line 1900 of file view3d_select.c.
References buffer.
Referenced by mixed_bones_object_selectbuffer().
|
static |
Definition at line 1893 of file view3d_select.c.
References buffer.
Referenced by mixed_bones_object_selectbuffer().
|
static |
Definition at line 3781 of file view3d_select.c.
References BKE_editmesh_from_object(), BKE_object_update_select_id(), BKE_paint_select_face_test(), BKE_paint_select_vert_test(), BLI_assert_msg, C, CTX_data_ensure_evaluated_depsgraph(), CTX_data_main(), Object::data, DEG_id_tag_update(), depsgraph, do_armature_box_select(), do_lattice_box_select(), do_mesh_box_select(), do_meta_box_select(), do_nurbs_box_select(), do_object_box_select(), do_paintface_box_select(), do_paintvert_box_select(), do_pose_box_select(), ED_outliner_select_sync_from_edit_bone_tag(), ED_outliner_select_sync_from_object_tag(), ED_outliner_select_sync_from_pose_bone_tag(), ED_view3d_viewcontext_init(), ED_view3d_viewcontext_init_object(), ViewContext::em, FOREACH_OBJECT_IN_MODE_BEGIN, FOREACH_OBJECT_IN_MODE_END, Object::id, ID_RECALC_SELECT, Object::mode, NC_GEOM, NC_OBJECT, ND_BONE_SELECT, ND_SELECT, OB_ARMATURE, OB_CURVES_LEGACY, OB_LATTICE, OB_MBALL, OB_MESH, OB_MODE_PARTICLE_EDIT, OB_MODE_POSE, OB_SURF, ViewContext::obact, ViewContext::obedit, OPERATOR_CANCELLED, OPERATOR_FINISHED, PE_box_select(), wmOperator::ptr, RNA_enum_get(), Object::type, ViewContext::v3d, view3d_operator_needs_opengl(), ViewContext::view_layer, WM_event_add_notifier(), WM_generic_user_data_free(), and WM_operator_properties_border_to_rcti().
Referenced by VIEW3D_OT_select_box().
|
static |
Definition at line 4673 of file view3d_select.c.
References C, view3d_circle_select_recalc(), and WM_gesture_circle_cancel().
Referenced by VIEW3D_OT_select_circle().
|
static |
Definition at line 4679 of file view3d_select.c.
References BKE_object_update_select_id(), BKE_paint_select_elem_test(), BKE_paint_select_face_test(), BKE_paint_select_vert_test(), BLI_assert, C, CTX_data_ensure_evaluated_depsgraph(), CTX_data_main(), wmOperator::customdata, wmGenericUserData::data, DEG_id_tag_update(), depsgraph, ED_outliner_select_sync_from_object_tag(), ED_outliner_select_sync_from_pose_bone_tag(), ED_select_op_modal(), ED_view3d_viewcontext_init(), ED_view3d_viewcontext_init_object(), FOREACH_OBJECT_IN_MODE_BEGIN, FOREACH_OBJECT_IN_MODE_END, Scene::id, ID_RECALC_SELECT, MEM_freeN, Object::mode, NC_SCENE, ND_OB_SELECT, NULL, OB_MODE_PARTICLE_EDIT, OB_MODE_POSE, OB_MODE_SCULPT, ViewContext::obact, ViewContext::obedit, obedit_circle_select(), object_circle_select(), OPERATOR_CANCELLED, OPERATOR_FINISHED, paint_facesel_circle_select(), paint_vertsel_circle_select(), PE_circle_select(), pose_circle_select(), wmOperator::ptr, RNA_enum_get(), RNA_int_get(), ViewContext::scene, EditSelectBuf_Cache::select_bitmap, Object::type, wmGesture::user_data, ViewContext::v3d, view3d_operator_needs_opengl(), ViewContext::view_layer, WM_event_add_notifier(), WM_generic_user_data_free(), and WM_gesture_is_modal_first().
Referenced by VIEW3D_OT_select_circle().
|
static |
Definition at line 4664 of file view3d_select.c.
References C, OPERATOR_FINISHED, result, view3d_circle_select_recalc(), and WM_gesture_circle_modal().
Referenced by VIEW3D_OT_select_circle().
Definition at line 4637 of file view3d_select.c.
References BMEditMesh::bm, BM_mesh_select_mode_flush_ex(), BM_SELECT_LEN_FLUSH_RECALC_ALL, C, CTX_data_ensure_evaluated_depsgraph(), depsgraph, ED_view3d_viewcontext_init(), ED_view3d_viewcontext_init_object(), ViewContext::em, em_setup_viewcontext(), FOREACH_OBJECT_IN_MODE_BEGIN, FOREACH_OBJECT_IN_MODE_END, Object::mode, OB_MESH, ViewContext::obact, ViewContext::obedit, BMEditMesh::selectmode, Object::type, user_data, ViewContext::v3d, and ViewContext::view_layer.
Referenced by view3d_circle_select_cancel(), and view3d_circle_select_modal().
|
static |
Definition at line 1268 of file view3d_select.c.
References BKE_paint_select_face_test(), BKE_paint_select_vert_test(), BLI_assert_msg, C, CTX_data_active_object(), Object::data, DEG_id_tag_update(), do_lasso_select_armature(), do_lasso_select_curve(), do_lasso_select_lattice(), do_lasso_select_mesh(), do_lasso_select_meta(), do_lasso_select_objects(), do_lasso_select_paintface(), do_lasso_select_paintvert(), do_lasso_select_pose(), ED_outliner_select_sync_from_edit_bone_tag(), ED_outliner_select_sync_from_object_tag(), ED_outliner_select_sync_from_pose_bone_tag(), ED_view3d_viewcontext_init_object(), FOREACH_OBJECT_IN_MODE_BEGIN, FOREACH_OBJECT_IN_MODE_END, ID_RECALC_SELECT, Object::mode, NC_GEOM, ND_SELECT, NULL, OB_ARMATURE, OB_CURVES_LEGACY, OB_LATTICE, OB_MBALL, OB_MESH, OB_MODE_PARTICLE_EDIT, OB_MODE_POSE, OB_MODE_TEXTURE_PAINT, OB_MODE_VERTEX_PAINT, OB_MODE_WEIGHT_PAINT, OB_SURF, ViewContext::obedit, PE_lasso_select(), Object::type, ViewContext::v3d, ViewContext::view_layer, WM_event_add_notifier(), and WM_generic_user_data_free().
Referenced by view3d_lasso_select_exec().
|
static |
Definition at line 1353 of file view3d_select.c.
References BKE_object_update_select_id(), C, CTX_data_ensure_evaluated_depsgraph(), CTX_data_main(), depsgraph, ED_view3d_viewcontext_init(), MEM_freeN, OPERATOR_CANCELLED, OPERATOR_FINISHED, OPERATOR_PASS_THROUGH, wmOperator::ptr, RNA_enum_get(), view3d_lasso_select(), view3d_operator_needs_opengl(), and WM_gesture_lasso_path_to_array().
Referenced by VIEW3D_OT_select_lasso().
void VIEW3D_OT_bone_select_menu | ( | wmOperatorType * | ot | ) |
Definition at line 1713 of file view3d_select.c.
References bone_select_menu_exec(), wmOperatorType::description, DummyRNA_NULL_items, wmOperatorType::exec, wmOperatorType::flag, wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::name, object_select_menu_enum_itemf(), OPTYPE_REGISTER, OPTYPE_UNDO, ot, wmOperatorType::prop, PROP_ENUM_NO_TRANSLATE, PROP_HIDDEN, PROP_SKIP_SAVE, RNA_def_boolean(), RNA_def_enum(), RNA_def_enum_funcs(), RNA_def_property_flag(), wmOperatorType::srna, and WM_menu_invoke().
Referenced by view3d_operatortypes().
void VIEW3D_OT_select | ( | wmOperatorType * | ot | ) |
Definition at line 2999 of file view3d_select.c.
References wmOperatorType::description, ED_operator_view3d_active(), ED_select_pick_get_name(), wmOperatorType::exec, wmOperatorType::flag, wmOperatorType::get_name, wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::name, NULL, OPTYPE_UNDO, ot, wmOperatorType::poll, PROP_HIDDEN, PROP_SKIP_SAVE, RNA_def_boolean(), RNA_def_int_vector(), RNA_def_property_flag(), wmOperatorType::srna, view3d_select_exec(), view3d_select_invoke(), and WM_operator_properties_mouse_select().
Referenced by view3d_operatortypes().
void VIEW3D_OT_select_box | ( | wmOperatorType * | ot | ) |
Definition at line 3885 of file view3d_select.c.
References wmOperatorType::cancel, wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::modal, wmOperatorType::name, OPTYPE_UNDO, ot, wmOperatorType::poll, view3d_box_select_exec(), view3d_selectable_data(), WM_gesture_box_cancel(), WM_gesture_box_invoke(), WM_gesture_box_modal(), WM_operator_properties_gesture_box(), and WM_operator_properties_select_operation().
Referenced by view3d_operatortypes().
void VIEW3D_OT_select_circle | ( | wmOperatorType * | ot | ) |
Definition at line 4763 of file view3d_select.c.
References wmOperatorType::cancel, wmOperatorType::description, ED_select_circle_get_name(), wmOperatorType::exec, wmOperatorType::flag, wmOperatorType::get_name, wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::modal, wmOperatorType::name, OPTYPE_UNDO, ot, wmOperatorType::poll, view3d_circle_select_cancel(), view3d_circle_select_exec(), view3d_circle_select_modal(), view3d_selectable_data(), WM_gesture_circle_invoke(), WM_operator_properties_gesture_circle(), and WM_operator_properties_select_operation_simple().
Referenced by view3d_operatortypes().
void VIEW3D_OT_select_lasso | ( | wmOperatorType * | ot | ) |
Definition at line 1380 of file view3d_select.c.
References wmOperatorType::cancel, wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::modal, wmOperatorType::name, OPTYPE_DEPENDS_ON_CURSOR, OPTYPE_UNDO, ot, wmOperatorType::poll, view3d_lasso_select_exec(), view3d_selectable_data(), WM_gesture_lasso_cancel(), WM_gesture_lasso_invoke(), WM_gesture_lasso_modal(), WM_operator_properties_gesture_lasso(), and WM_operator_properties_select_operation().
Referenced by view3d_operatortypes().
void VIEW3D_OT_select_menu | ( | wmOperatorType * | ot | ) |
Definition at line 1522 of file view3d_select.c.
References wmOperatorType::description, DummyRNA_NULL_items, wmOperatorType::exec, wmOperatorType::flag, wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::name, object_select_menu_enum_itemf(), object_select_menu_exec(), OPTYPE_REGISTER, OPTYPE_UNDO, ot, wmOperatorType::prop, PROP_ENUM_NO_TRANSLATE, PROP_HIDDEN, PROP_SKIP_SAVE, RNA_def_boolean(), RNA_def_enum(), RNA_def_enum_funcs(), RNA_def_property_flag(), wmOperatorType::srna, and WM_menu_invoke().
Referenced by view3d_operatortypes().
|
static |
Definition at line 2873 of file view3d_select.c.
References ARRAY_SIZE, BKE_object_pose_armature_get(), BKE_object_pose_armature_get_with_wpaint_check(), BKE_object_update_select_id(), BKE_paint_select_elem_test(), BKE_paint_select_face_test(), BKE_paint_select_vert_test(), bone_mouse_select_menu(), buffer, C, center, CTX_data_active_object(), CTX_data_edit_object(), CTX_data_ensure_evaluated_depsgraph(), CTX_data_main(), CTX_data_scene(), Object::data, depsgraph, ED_armature_edit_select_pick(), ED_curve_editfont_select_pick(), ED_curve_editnurb_select_pick(), ED_lattice_select_pick(), ED_mball_select_pick(), ed_object_select_pick(), ED_select_pick_params_from_operator(), ED_view3d_select_dist_px(), ED_view3d_viewcontext_init(), ed_wpaint_vertex_select_pick(), EDBM_select_pick(), ELEM, GPENCIL_ANY_MODE, MAXPICKELEMS, mixed_bones_object_selectbuffer(), Object::mode, NC_SCENE, ND_OB_SELECT, NULL, OB_ARMATURE, OB_CURVES_LEGACY, OB_FONT, OB_GPENCIL, OB_LATTICE, OB_MBALL, OB_MESH, OB_MODE_ALL_WEIGHT_PAINT, OB_MODE_PARTICLE_EDIT, OB_SURF, OPERATOR_CANCELLED, OPERATOR_FINISHED, OPERATOR_PASS_THROUGH, paintface_mouse_select(), params, PE_mouse_particles(), wmOperator::ptr, RNA_boolean_get(), RNA_int_get_array(), scene, Object::type, view3d_operator_needs_opengl(), VIEW3D_SELECT_FILTER_NOP, and WM_event_add_notifier().
Referenced by VIEW3D_OT_select(), and view3d_select_invoke().
|
static |
Definition at line 2990 of file view3d_select.c.
References C, wmEvent::mval, wmOperator::ptr, RNA_int_set_array(), view3d_select_exec(), and WM_operator_flag_only_pass_through_on_press().
Referenced by VIEW3D_OT_select().
Definition at line 433 of file view3d_select.c.
References BKE_paint_select_elem_test(), C, CTX_data_active_object(), ED_operator_region_view3d_active(), Object::mode, OB_FONT, OB_MODE_EDIT, OB_MODE_TEXTURE_PAINT, OB_MODE_VERTEX_PAINT, OB_MODE_WEIGHT_PAINT, and Object::type.
Referenced by VIEW3D_OT_select_box(), VIEW3D_OT_select_circle(), and VIEW3D_OT_select_lasso().
|
static |
Definition at line 3074 of file view3d_select.c.
References BoxSelectUserData::_rect_fl, BLI_rctf_rcti_copy(), BoxSelectUserData::is_changed, BoxSelectUserData::is_done, BoxSelectUserData::rect, BoxSelectUserData::rect_fl, BoxSelectUserData::sel_op, SELECT, BoxSelectUserData::select_flag, and BoxSelectUserData::vc.
Referenced by do_lattice_box_select(), do_mesh_box_select(), do_nurbs_box_select(), and do_paintvert_box_select().
|
static |
Definition at line 3926 of file view3d_select.c.
References copy_v2_v2_int(), CircleSelectUserData::is_changed, CircleSelectUserData::mval, CircleSelectUserData::mval_fl, CircleSelectUserData::radius, CircleSelectUserData::radius_squared, select(), SELECT, CircleSelectUserData::select, CircleSelectUserData::select_flag, and CircleSelectUserData::vc.
Referenced by armature_circle_select(), lattice_circle_select(), mball_circle_select(), mesh_circle_select(), nurbscurve_circle_select(), paint_vertsel_circle_select(), and pose_circle_select().
|
static |
Definition at line 408 of file view3d_select.c.
References LassoSelectUserData::_rect_fl, BLI_rctf_rcti_copy(), LassoSelectUserData::is_changed, LassoSelectUserData::is_done, LassoSelectUserData::mcoords, LassoSelectUserData::mcoords_len, LassoSelectUserData::pass, LassoSelectUserData::rect, LassoSelectUserData::rect_fl, LassoSelectUserData::sel_op, SELECT, LassoSelectUserData::select_flag, and LassoSelectUserData::vc.
Referenced by do_lasso_select_armature(), do_lasso_select_curve(), do_lasso_select_lattice(), do_lasso_select_mesh(), do_lasso_select_meta(), do_lasso_select_paintvert(), and do_lasso_tag_pose().
|
static |
Definition at line 1415 of file view3d_select.c.
Referenced by bone_mouse_select_menu(), bone_select_menu_exec(), object_mouse_select_menu(), object_select_menu_enum_itemf(), and object_select_menu_exec().