29 return (!is_select && (is_inside)) ? 1 : -1;
31 return (is_select && is_inside) ? 0 : -1;
33 return is_inside ? 1 : 0;
35 return (is_select && is_inside) ? -1 : (is_select ? 0 : -1);
37 return (is_select && is_inside) ? 0 : ((!is_select && is_inside) ? 1 : -1);
48 return (!is_select && is_inside) ? 1 : -1;
50 return (is_select && is_inside) ? 0 : -1;
53 return is_inside ? 1 : -1;
55 return (is_select && is_inside) ? -1 : (is_select ? 0 : -1);
57 return (is_select && is_inside) ? 0 : ((!is_select && is_inside) ? 1 : -1);
66 if (is_first ==
false) {
80 return (
fabsf(delta) <= thresh);
82 return ((delta + thresh) >= 0.0f);
84 return ((delta - thresh) <= 0.0f);
99 float nearest_edge_length;
104 nearest_edge_length =
length;
111 nearest_edge_length = -1.0f;
122 KDTreeNearest_1d nearest;
123 if (BLI_kdtree_1d_find_nearest(tree, &nearest_edge_length, &nearest) != -1) {
125 float delta =
length - nearest.co[0];
#define BLI_assert_unreachable()
#define BLI_assert_msg(a, msg)
A KD-tree for nearest neighbor search.
#define CTX_IFACE_(context, msgid)
#define BLT_I18NCONTEXT_OPERATOR_DEFAULT
int ED_select_op_action_deselected(eSelectOp sel_op, bool is_select, bool is_inside)
eSelectOp ED_select_op_modal(eSelectOp sel_op, bool is_first)
eSelectOp ED_select_op_from_operator(PointerRNA *ptr) ATTR_WARN_UNUSED_RESULT
int ED_select_op_action(eSelectOp sel_op, bool is_select, bool is_inside)
std::string ED_select_circle_get_name(wmOperatorType *ot, PointerRNA *ptr)
bool ED_select_similar_compare_float(float delta, float thresh, eSimilarCmp compare)
SelectPick_Params ED_select_pick_params_from_operator(PointerRNA *ptr) ATTR_NONNULL(1)
bool ED_select_similar_compare_float_tree(const KDTree_1d *tree, float length, float thresh, eSimilarCmp compare)
std::string ED_select_pick_get_name(wmOperatorType *ot, PointerRNA *ptr)
float length(VecOp< float, D >) RET
PropertyRNA * RNA_struct_find_property(PointerRNA *ptr, const char *identifier)
bool RNA_property_boolean_get(PointerRNA *ptr, PropertyRNA *prop)
bool RNA_boolean_get(PointerRNA *ptr, const char *name)
int RNA_enum_get(PointerRNA *ptr, const char *name)