Blender V5.3
blender::ed::geometry Namespace Reference

Classes

class  AssetRepresentation
struct  ErrorsForType
struct  GeoOperatorLog
struct  GetIDName
class  MeshState
struct  OperatorTypeData
struct  RegistrationData

Enumerations

enum class  ConvertAttributeMode { Generic = 0 , VertexGroup = 1 }

Functions

static bool geometry_attributes_poll_ex (bContext *C, const Object *ob)
static bool geometry_attributes_with_id_type_poll_ex (bContext *C, const Object *ob, const ID_Type obdata_type)
static bool geometry_attributes_poll (bContext *C)
static bool geometry_attributes_for_mesh_poll (bContext *C)
static bool geometry_attributes_remove_poll (bContext *C)
static const EnumPropertyItem * geometry_attribute_domain_itemf (bContext *C, PointerRNA *, PropertyRNA *, bool *r_free)
static void set_active_default_status_on_add (Mesh &mesh, const bke::AttrDomain domain, const bke::AttrType type, const StringRefNull name)
static wmOperatorStatus geometry_attribute_add_exec (bContext *C, wmOperator *op)
static wmOperatorStatus geometry_attribute_add_invoke (bContext *C, wmOperator *op, const wmEvent *event)
void GEOMETRY_OT_attribute_add (wmOperatorType *ot)
static wmOperatorStatus geometry_attribute_remove_exec (bContext *C, wmOperator *op)
void GEOMETRY_OT_attribute_remove (wmOperatorType *ot)
static wmOperatorStatus geometry_color_attribute_add_exec (bContext *C, wmOperator *op)
static wmOperatorStatus geometry_color_attribute_add_invoke (bContext *C, wmOperator *op, const wmEvent *event)
static bool geometry_attribute_convert_poll (bContext *C)
bool convert_attribute (AttributeOwner &owner, bke::MutableAttributeAccessor attributes, const StringRef name, const bke::AttrDomain dst_domain, const bke::AttrType dst_type, ReportList *reports)
static wmOperatorStatus geometry_attribute_convert_exec (bContext *C, wmOperator *op)
static void geometry_color_attribute_add_ui (bContext *, wmOperator *op)
void GEOMETRY_OT_color_attribute_add (wmOperatorType *ot)
static wmOperatorStatus geometry_color_attribute_set_render_exec (bContext *C, wmOperator *op)
void GEOMETRY_OT_color_attribute_render_set (wmOperatorType *ot)
static wmOperatorStatus geometry_color_attribute_remove_exec (bContext *C, wmOperator *op)
static bool geometry_color_attributes_remove_poll (bContext *C)
void GEOMETRY_OT_color_attribute_remove (wmOperatorType *ot)
static wmOperatorStatus geometry_color_attribute_duplicate_exec (bContext *C, wmOperator *)
static bool geometry_color_attributes_duplicate_poll (bContext *C)
void GEOMETRY_OT_color_attribute_duplicate (wmOperatorType *ot)
static wmOperatorStatus geometry_attribute_convert_invoke (bContext *C, wmOperator *op, const wmEvent *)
static void geometry_attribute_convert_ui (bContext *C, wmOperator *op)
static const EnumPropertyItem * geometry_attribute_convert_mode_itemf (bContext *C, PointerRNA *, PropertyRNA *, bool *r_free)
static bool geometry_color_attribute_convert_poll (bContext *C)
static wmOperatorStatus geometry_color_attribute_convert_exec (bContext *C, wmOperator *op)
static wmOperatorStatus geometry_color_attribute_convert_invoke (bContext *C, wmOperator *op, const wmEvent *)
static void geometry_color_attribute_convert_ui (bContext *, wmOperator *op)
void GEOMETRY_OT_color_attribute_convert (wmOperatorType *ot)
void GEOMETRY_OT_attribute_convert (wmOperatorType *ot)
void GEOMETRY_OT_geometry_randomization (wmOperatorType *ot)
void operatortypes_geometry ()
static wmOperatorStatus geometry_randomization_invoke (bContext *C, wmOperator *op, const wmEvent *event)
static wmOperatorStatus geometry_randomization_exec (bContext *C, wmOperator *op)
static RegistrationData & get_registration_data ()
static std::optional< std::string > operator_idname_get (const StringRefNull custom_idname, RegistrationData::Errors *errors)
static std::optional< StringRefNull > custom_idname_for_asset (const AssetRepresentation &asset)
static std::optional< StringRefNull > custom_idname_for_group (const bNodeTree &group)
Attribute Value RNA Property Helpers

Functions to make it easier to register RNA properties for the various attribute types and retrieve/set their values.

StringRefNull rna_property_name_for_type (const bke::AttrType type)
PropertyRNA * rna_property_for_type (PointerRNA &ptr, const bke::AttrType type)
void register_rna_properties_for_attribute_types (StructRNA &srna)
GPointer rna_property_for_attribute_type_retrieve_value (PointerRNA &ptr, const bke::AttrType type, void *buffer)
void rna_property_for_attribute_type_set_value (PointerRNA &ptr, PropertyRNA &prop, const GPointer value)
bool attribute_set_poll (bContext &C, const ID &object_data)
Menu
GeometryNodeAssetTraitFlag asset_flag_for_context (const Object &active_object)
static bool asset_menu_poll (const bContext *C, MenuType *)
static GeometryNodeAssetTraitFlag asset_flag_for_context (const ObjectType type, const eObjectMode mode)
static Set< StringRef > get_builtin_menus (const ObjectType object_type, const eObjectMode mode)
static bool menu_operators_poll (const bContext &C, const RegistrationData::TypeTreeItem &node)
static void add_node_group_operator_button (const bContext *C, ui::Layout &layout, wmOperatorType *ot)
static void catalog_assets_draw (const bContext *C, Menu *menu)
MenuType node_group_operator_assets_menu ()
static void catalog_assets_draw_unassigned (const bContext *C, Menu *menu)
MenuType node_group_operator_assets_menu_unassigned ()
void ui_template_node_operator_asset_menu_items (ui::Layout &layout, const bContext &C, const StringRef path)
void ui_template_node_operator_asset_root_items (ui::Layout &layout, const bContext &C)

Variables

static EnumPropertyItem convert_attribute_mode_items []

Operator

using OperatorsToRegister = CustomIDVectorSet<std::unique_ptr<OperatorTypeData>, GetIDName>
static const bNodeTree * get_asset_or_local_node_group (const bContext &C, const wmOperatorType &ot, ReportList *reports)
static const bNodeTree * get_node_group (const bContext &C, const wmOperatorType &ot, ReportList *reports)
static GeoOperatorLog & get_static_eval_log ()
const GeoOperatorLog & node_group_operator_static_eval_log ()
static void find_verbose_log_contexts (const Main &bmain, Set< ComputeContextHash > &r_verbose_log_contexts)
static const ImplicitSharingInfo * get_vertex_group_sharing_info (const Mesh &mesh)
static std::string shape_key_attribute_name (const KeyBlock &kb)
static void add_shape_keys_as_attributes (Mesh &mesh, const Key &key)
static void store_attributes_to_shape_keys (const Mesh &mesh, Key &key)
static void remove_shape_key_attributes (Mesh &mesh, const Key &key)
static bke::GeometrySet get_original_geometry_eval_copy (Depsgraph &depsgraph, Object &object, nodes::GeoNodesOperatorData &operator_data, Vector< MeshState > &orig_mesh_states)
static void store_result_geometry (const bContext &C, const wmOperator &op, const Depsgraph &depsgraph, Main &bmain, Scene &scene, Object &object, const RegionView3D *rv3d, bke::GeometrySet geometry)
static void gather_node_group_ids (const bNodeTree &node_tree, Set< ID * > &ids)
static std::optional< ID_Type > socket_type_to_id_type (const eNodeSocketDatatype socket_type)
static Map< std::string, ID * > gather_input_ids (const Main &bmain, const bNodeTree &node_group, const PointerRNA &properties_ptr)
static Depsgraph * build_extra_depsgraph (const Depsgraph &depsgraph_active, const Set< ID * > &ids)
static bool object_has_editable_data (const Main &bmain, const Object &object)
static Vector< Object * > gather_supported_objects (const bContext &C, const Main &bmain, const eObjectMode mode)
static void store_input_node_values_rna_props (const bContext &C, wmOperator &op, const wmEvent &event)
static wmOperatorStatus run_node_group_exec (bContext *C, wmOperator *op)
static wmOperatorStatus run_node_group_invoke (bContext *C, wmOperator *op, const wmEvent *event)
static void run_node_group_ui (bContext *C, wmOperator *op)
static bool run_node_ui_poll (wmOperatorType *, PointerRNA *ptr)
static bool run_node_group_poll (bContext *C, wmOperatorType *ot)
static Array< EnumPropertyItem, 0 > get_input_enum_items (const IDProperty &input_idprop)
static void make_common_type_prop (StructRNA &srna, const EnumPropertyItem *items, const nodes::GeometryNodesInputType default_type)
static void make_common_attribute_name_prop (StructRNA &srna, const StringRefNull name, const StringRefNull description, const IDProperty &input_idprop)
static void make_common_value_and_attribute_props (StructRNA &srna, const StringRefNull name, const StringRefNull description, const IDProperty &input_idprop)
static void make_common_value_props (StructRNA &srna)
static StructRNA * get_input_socket_struct_rna (IDProperty &input_idprop, OperatorTypeData &type_data)
static StructRNA * create_inputs_srna (const IDProperty &properties, OperatorTypeData &type_data)
static StructRNA * create_panels_srna (const IDProperty &properties, Vector< StructRNA * > &r_generated)
static void register_node_tool (wmOperatorType *ot, std::unique_ptr< OperatorTypeData > &type_data_ptr)
void ui_template_node_operator_registration_errors (ui::Layout &layout, const StringRefNull idname_py)
static RegistrationData::TypeTreeItem * find_tree_child (const Span< std::unique_ptr< RegistrationData::TypeTreeItem > > children, const StringRef name)
static const RegistrationData::TypeTreeItem * find_tree_node (const Span< std::unique_ptr< RegistrationData::TypeTreeItem > > nodes, StringRef path)
static RegistrationData::TypeTreeItem & ensure_child (Vector< std::unique_ptr< RegistrationData::TypeTreeItem > > &children, const StringRef name)
static void tree_add_type (Vector< std::unique_ptr< RegistrationData::TypeTreeItem > > &nodes, StringRef path, wmOperatorType *ot)
static OperatorsToRegister get_node_tools_type_data (const bContext &C, Main &bmain, RegistrationData::Errors &errors)
static void show_error_reports (const bContext &C, RegistrationData::Errors errors)
void register_node_group_operators (const bContext &C)

Typedef Documentation

◆ OperatorsToRegister

Enumeration Type Documentation

◆ ConvertAttributeMode

Enumerator
Generic 
VertexGroup 

Definition at line 604 of file geometry_attributes.cc.

Function Documentation

◆ add_node_group_operator_button()

void blender::ed::geometry::add_node_group_operator_button ( const bContext * C,
ui::Layout & layout,
wmOperatorType * ot )
static

◆ add_shape_keys_as_attributes()

void blender::ed::geometry::add_shape_keys_as_attributes ( Mesh & mesh,
const Key & key )
static

◆ asset_flag_for_context() [1/2]

GeometryNodeAssetTraitFlag blender::ed::geometry::asset_flag_for_context ( const Object & active_object)

◆ asset_flag_for_context() [2/2]

◆ asset_menu_poll()

bool blender::ed::geometry::asset_menu_poll ( const bContext * C,
MenuType *  )
static

◆ attribute_set_poll()

◆ build_extra_depsgraph()

◆ catalog_assets_draw()

◆ catalog_assets_draw_unassigned()

◆ convert_attribute()

◆ create_inputs_srna()

◆ create_panels_srna()

◆ custom_idname_for_asset()

◆ custom_idname_for_group()

◆ ensure_child()

RegistrationData::TypeTreeItem & blender::ed::geometry::ensure_child ( Vector< std::unique_ptr< RegistrationData::TypeTreeItem > > & children,
const StringRef name )
static

Definition at line 1573 of file node_group_operator.cc.

References ensure_child(), and find_tree_child().

Referenced by ensure_child(), and tree_add_type().

◆ find_tree_child()

RegistrationData::TypeTreeItem * blender::ed::geometry::find_tree_child ( const Span< std::unique_ptr< RegistrationData::TypeTreeItem > > children,
const StringRef name )
static

Definition at line 1547 of file node_group_operator.cc.

References find_tree_child().

Referenced by ensure_child(), find_tree_child(), and find_tree_node().

◆ find_tree_node()

◆ find_verbose_log_contexts()

◆ gather_input_ids()

Map< std::string, ID * > blender::ed::geometry::gather_input_ids ( const Main & bmain,
const bNodeTree & node_group,
const PointerRNA & properties_ptr )
static

Gather IDs referenced from node group input properties (the redo panel). In the end, the group input properties will be copied to contain evaluated data-blocks from the active and/or an extra depsgraph.

Definition at line 827 of file node_group_operator.cc.

References blender::Map< Key, Value, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::add(), blender::BKE_libblock_find_name(), gather_input_ids(), blender::RNA_pointer_get(), blender::RNA_string_get(), and socket_type_to_id_type().

Referenced by gather_input_ids(), and run_node_group_exec().

◆ gather_node_group_ids()

void blender::ed::geometry::gather_node_group_ids ( const bNodeTree & node_tree,
Set< ID * > & ids )
static

Gather IDs used by the node group, and the node group itself if there are any. We need to use all IDs because the only mechanism we have to replace the socket ID pointers with their evaluated counterparts is evaluating the node group data-block itself.

Definition at line 765 of file node_group_operator.cc.

References blender::Set< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::add(), blender::BLI_assert(), blender::bke::bNodeTreeRuntime::eval_dependencies, gather_node_group_ids(), blender::bNodeTree::id, blender::bNodeTree::runtime, and blender::Set< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::size().

Referenced by gather_node_group_ids(), and run_node_group_exec().

◆ gather_supported_objects()

◆ geometry_attribute_add_exec()

◆ geometry_attribute_add_invoke()

◆ geometry_attribute_convert_exec()

◆ geometry_attribute_convert_invoke()

◆ geometry_attribute_convert_mode_itemf()

◆ geometry_attribute_convert_poll()

◆ geometry_attribute_convert_ui()

◆ geometry_attribute_domain_itemf()

◆ geometry_attribute_remove_exec()

◆ geometry_attributes_for_mesh_poll()

◆ geometry_attributes_poll()

◆ geometry_attributes_poll_ex()

◆ geometry_attributes_remove_poll()

◆ geometry_attributes_with_id_type_poll_ex()

bool blender::ed::geometry::geometry_attributes_with_id_type_poll_ex ( bContext * C,
const Object * ob,
const ID_Type obdata_type )
static

◆ geometry_color_attribute_add_exec()

◆ geometry_color_attribute_add_invoke()

◆ geometry_color_attribute_add_ui()

◆ geometry_color_attribute_convert_exec()

◆ geometry_color_attribute_convert_invoke()

◆ geometry_color_attribute_convert_poll()

◆ geometry_color_attribute_convert_ui()

◆ geometry_color_attribute_duplicate_exec()

◆ geometry_color_attribute_remove_exec()

◆ geometry_color_attribute_set_render_exec()

◆ geometry_color_attributes_duplicate_poll()

◆ geometry_color_attributes_remove_poll()

◆ GEOMETRY_OT_attribute_add()

◆ GEOMETRY_OT_attribute_convert()

◆ GEOMETRY_OT_attribute_remove()

◆ GEOMETRY_OT_color_attribute_add()

◆ GEOMETRY_OT_color_attribute_convert()

◆ GEOMETRY_OT_color_attribute_duplicate()

◆ GEOMETRY_OT_color_attribute_remove()

◆ GEOMETRY_OT_color_attribute_render_set()

◆ GEOMETRY_OT_geometry_randomization()

◆ geometry_randomization_exec()

◆ geometry_randomization_invoke()

wmOperatorStatus blender::ed::geometry::geometry_randomization_invoke ( bContext * C,
wmOperator * op,
const wmEvent * event )
static

◆ get_asset_or_local_node_group()

◆ get_builtin_menus()

Set< StringRef > blender::ed::geometry::get_builtin_menus ( const ObjectType object_type,
const eObjectMode mode )
static

◆ get_input_enum_items()

◆ get_input_socket_struct_rna()

StructRNA * blender::ed::geometry::get_input_socket_struct_rna ( IDProperty & input_idprop,
OperatorTypeData & type_data )
static

Definition at line 1214 of file node_group_operator.cc.

References blender::BLI_assert(), blender::StringRefNull::c_str(), blender::ed::geometry::OperatorTypeData::enum_item_storage, FLT_MAX, blender::ed::geometry::OperatorTypeData::generated_structs, blender::nodes::geometry_nodes_input_type_items_value_or_attribute_or_layer, get_input_enum_items(), get_input_socket_struct_rna(), blender::IDP_group_lookup_bool(), blender::IDP_group_lookup_float(), blender::IDP_group_lookup_float_array(), blender::IDP_group_lookup_int(), blender::IDP_group_lookup_string(), INT_MAX, blender::blender::StringRefBase::is_empty(), make_common_attribute_name_prop(), make_common_type_prop(), make_common_value_and_attribute_props(), make_common_value_props(), blender::IDProperty::name, blender::PROP_COLOR, blender::PROP_NONE, blender::RNA_blender_rna_get(), blender::RNA_def_boolean(), blender::RNA_def_enum(), blender::RNA_def_float(), blender::RNA_def_float_array(), blender::RNA_def_float_color(), blender::RNA_def_float_rotation(), blender::RNA_def_int(), blender::RNA_def_property_subtype(), blender::RNA_def_string(), blender::RNA_def_struct_ptr(), blender::RNA_def_struct_ui_text(), blender::RNA_PropertyGroup, blender::RNA_struct_in_public_namespace(), blender::SOCK_BOOLEAN, blender::SOCK_COLLECTION, blender::SOCK_FLOAT, blender::SOCK_FONT, blender::SOCK_IMAGE, blender::SOCK_INT, blender::SOCK_MATERIAL, blender::SOCK_MENU, blender::SOCK_OBJECT, blender::SOCK_RGBA, blender::SOCK_ROTATION, blender::SOCK_SOUND, blender::SOCK_STRING, blender::SOCK_VECTOR, and blender::nodes::Value.

Referenced by create_inputs_srna(), and get_input_socket_struct_rna().

◆ get_node_group()

◆ get_node_tools_type_data()

◆ get_original_geometry_eval_copy()

bke::GeometrySet blender::ed::geometry::get_original_geometry_eval_copy ( Depsgraph & depsgraph,
Object & object,
nodes::GeoNodesOperatorData & operator_data,
Vector< MeshState > & orig_mesh_states )
static

Geometry nodes currently requires working on "evaluated" data-blocks (rather than "original" data-blocks that are part of a Main data-base). This could change in the future, but for now, we need to create evaluated copies of geometry before passing it to geometry nodes. Implicit sharing lets us avoid copying attribute data though.

Definition at line 543 of file node_group_operator.cc.

References blender::nodes::GeoNodesOperatorData::active_edge_index, blender::nodes::GeoNodesOperatorData::active_face_index, blender::nodes::GeoNodesOperatorData::active_layer_index, blender::nodes::GeoNodesOperatorData::active_point_index, add_shape_keys_as_attributes(), blender::Vector< T, InlineBufferCapacity, Allocator >::append_as(), blender::BKE_curves_copy_for_eval(), blender::BKE_editmesh_bmesh_get_for_write(), blender::BKE_grease_pencil_copy_for_eval(), blender::BKE_mesh_copy_for_eval(), blender::BKE_pointcloud_copy_for_eval(), blender::bm, blender::BM_mesh_active_edge_index_get(), blender::BM_mesh_active_face_index_get(), blender::BM_mesh_active_vert_index_get(), blender::data, blender::DEG_get_bmain(), blender::DEG_get_ctime(), blender::EDBM_mesh_free_data(), blender::EDBM_mesh_load_ex(), blender::bke::GeometrySet::from_curves(), blender::bke::GeometrySet::from_grease_pencil(), blender::bke::GeometrySet::from_mesh(), blender::bke::GeometrySet::from_pointcloud(), get_original_geometry_eval_copy(), blender::OB_CURVES, blender::OB_GREASE_PENCIL, blender::OB_MESH, blender::OB_POINTCLOUD, blender::bke::object::pbvh_get(), and blender::bke::pbvh::update_normals().

Referenced by get_original_geometry_eval_copy(), and run_node_group_exec().

◆ get_registration_data()

◆ get_static_eval_log()

GeoOperatorLog & blender::ed::geometry::get_static_eval_log ( )
static

The socket value log is stored statically so it can be used in the node editor. A fancier storage system shouldn't be necessary, since the goal is just to be able to debug intermediate values when building a tool.

Definition at line 396 of file node_group_operator.cc.

References get_static_eval_log(), and log.

Referenced by get_static_eval_log(), node_group_operator_static_eval_log(), run_node_group_exec(), and run_node_group_ui().

◆ get_vertex_group_sharing_info()

const ImplicitSharingInfo * blender::ed::geometry::get_vertex_group_sharing_info ( const Mesh & mesh)
static

◆ make_common_attribute_name_prop()

void blender::ed::geometry::make_common_attribute_name_prop ( StructRNA & srna,
const StringRefNull name,
const StringRefNull description,
const IDProperty & input_idprop )
static

◆ make_common_type_prop()

◆ make_common_value_and_attribute_props()

void blender::ed::geometry::make_common_value_and_attribute_props ( StructRNA & srna,
const StringRefNull name,
const StringRefNull description,
const IDProperty & input_idprop )
static

◆ make_common_value_props()

void blender::ed::geometry::make_common_value_props ( StructRNA & srna)
static

◆ menu_operators_poll()

bool blender::ed::geometry::menu_operators_poll ( const bContext & C,
const RegistrationData::TypeTreeItem & node )
static

◆ node_group_operator_assets_menu()

◆ node_group_operator_assets_menu_unassigned()

◆ node_group_operator_static_eval_log()

const GeoOperatorLog & blender::ed::geometry::node_group_operator_static_eval_log ( )

◆ object_has_editable_data()

bool blender::ed::geometry::object_has_editable_data ( const Main & bmain,
const Object & object )
static

◆ operator_idname_get()

◆ operatortypes_geometry()

◆ register_node_group_operators()

void blender::ed::geometry::register_node_group_operators ( const bContext & C)

Re-register all operator types for node tool assets and local node groups. This process unregisters old operators.

Definition at line 1725 of file node_group_operator.cc.

References blender::Set< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::add(), blender::Set< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::add_new(), blender::asset_system::all_library_reference(), blender::BLI_assert(), C, blender::asset_system::AssetLibrary::catalog_service(), blender::VectorSet< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::contains_as(), blender::Core, blender::CTX_data_main(), blender::CTX_wm_manager(), blender::VectorSet< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::extract_vector(), blender::ed::asset::find_asset_from_weak_ref(), blender::asset_system::AssetCatalogService::find_catalog(), get_node_tools_type_data(), get_registration_data(), blender::ed::geometry::ErrorsForType::is_builtin_operator, blender::Set< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::is_empty(), blender::VectorSet< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::is_empty(), blender::ed::asset::list::library_get_once_available(), blender::ed::geometry::RegistrationData::local_types, blender::Map< Key, Value, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::lookup_or_add_default(), blender::ed::geometry::RegistrationData::menu_path_tree_roots, blender::OPTYPE_NODE_TOOL, blender::asset_system::AssetCatalog::path, PRF_scope, register_node_group_operators(), register_node_tool(), blender::VectorSet< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::remove_if(), blender::RNA_blender_rna_get(), blender::RNA_struct_free(), blender::RNA_struct_py_type_set(), show_error_reports(), blender::asset_system::AssetCatalogPath::str(), tree_add_type(), blender::ed::geometry::RegistrationData::unassigned_types, blender::WM_operator_handlers_clear(), blender::WM_operator_stack_clear(), blender::WM_operatortype_append_ptr(), blender::WM_operatortype_find(), blender::WM_operatortype_remove_ptr(), and blender::WM_operatortypes_registered_get().

Referenced by register_node_group_operators(), and blender::wm_event_do_notifiers().

◆ register_node_tool()

void blender::ed::geometry::register_node_tool ( wmOperatorType * ot,
std::unique_ptr< OperatorTypeData > & type_data_ptr )
static

◆ register_rna_properties_for_attribute_types()

◆ remove_shape_key_attributes()

void blender::ed::geometry::remove_shape_key_attributes ( Mesh & mesh,
const Key & key )
static

◆ rna_property_for_attribute_type_retrieve_value()

◆ rna_property_for_attribute_type_set_value()

◆ rna_property_for_type()

◆ rna_property_name_for_type()

◆ run_node_group_exec()

wmOperatorStatus blender::ed::geometry::run_node_group_exec ( bContext * C,
wmOperator * op )
static

Definition at line 957 of file node_group_operator.cc.

References blender::Set< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::add(), blender::nodes::eval_log::NodeTreeLog::all_warnings, blender::MatBase< T, NumCol, NumRow, Alignment >::base_ptr(), blender::BKE_report(), build_extra_depsgraph(), C, blender::CTX_data_active_object(), blender::CTX_data_ensure_evaluated_depsgraph(), blender::CTX_data_main(), blender::CTX_data_scene(), blender::CTX_wm_region_view3d(), blender::nodes::GeoNodesOperatorData::cursor_position, blender::nodes::GeoNodesOperatorData::cursor_rotation, blender::DEG_get_evaluated(), blender::DEG_id_is_fully_evaluated(), blender::nodes::GeoNodesOperatorData::depsgraphs, blender::nodes::ensure_geometry_nodes_lazy_function_graph(), blender::nodes::eval_log::NodeTreeLog::ensure_node_warnings(), blender::nodes::GeoNodesCallData::eval_log, blender::nodes::execute_geometry_nodes_on_geometry(), blender::nodes::GeoNodesOperatorDepsgraphs::extra, find_verbose_log_contexts(), gather_input_ids(), gather_node_group_ids(), gather_supported_objects(), get_node_group(), get_original_geometry_eval_copy(), get_static_eval_log(), blender::ComputeContext::hash(), blender::bNodeTree::id, blender::nodes::Info, blender::nodes::GeoNodesOperatorData::input_ids, blender::Set< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::is_empty(), blender::nodes::NodeWarning::message, blender::nodes::GeoNodesOperatorData::mode, blender::Object::mode, blender::nodes::GeoNodesOperatorData::mouse_position, blender::ID::name, NC_GEOM, ND_DATA, blender::nullptr, blender::OPERATOR_CANCELLED, blender::nodes::GeoNodesCallData::operator_data, blender::OPERATOR_FINISHED, blender::wmOperator::ptr, blender::nodes::GeoNodesOperatorData::region_size, blender::wmOperator::reports, blender::RNA_boolean_get(), blender::RNA_float_get_array(), blender::RNA_int_get_array(), blender::RPT_ERROR, blender::RPT_INFO, blender::RPT_WARNING, run_node_group_exec(), blender::nodes::GeoNodesOperatorData::scene_orig, blender::nodes::GeoNodesOperatorData::self_object_orig, store_result_geometry(), STREQ, blender::nodes::NodeWarning::type, blender::wmOperator::type, blender::Map< Key, Value, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::values(), blender::nodes::GeoNodesCallData::verbose_log_contexts, blender::nodes::GeoNodesOperatorData::viewport_is_perspective, blender::nodes::GeoNodesOperatorData::viewport_viewmat, blender::nodes::GeoNodesOperatorData::viewport_winmat, blender::math::QuaternionBase< T >::w, and blender::WM_event_add_notifier().

Referenced by register_node_tool(), run_node_group_exec(), and run_node_group_invoke().

◆ run_node_group_invoke()

◆ run_node_group_poll()

bool blender::ed::geometry::run_node_group_poll ( bContext * C,
wmOperatorType * ot )
static

◆ run_node_group_ui()

◆ run_node_ui_poll()

bool blender::ed::geometry::run_node_ui_poll ( wmOperatorType * ,
PointerRNA * ptr )
static

◆ set_active_default_status_on_add()

◆ shape_key_attribute_name()

std::string blender::ed::geometry::shape_key_attribute_name ( const KeyBlock & kb)
static

◆ show_error_reports()

◆ socket_type_to_id_type()

◆ store_attributes_to_shape_keys()

◆ store_input_node_values_rna_props()

void blender::ed::geometry::store_input_node_values_rna_props ( const bContext & C,
wmOperator & op,
const wmEvent & event )
static

Input node values are stored as operator properties in order to support redoing from the redo panel for a few reasons:

  1. Some data (like the mouse position) cannot be retrieved from the exec callback used for operator redo. Redo is meant to just call the operator again with the exact same properties.
  2. While adjusting an input in the redo panel, the user doesn't expect anything else to change. If we retrieve other data like the viewport transform on every execution, that won't be the case. We use operator RNA properties instead of operator custom data because the custom data struct isn't maintained for the redo exec call.

Definition at line 925 of file node_group_operator.cc.

References blender::MatBase< T, NumCol, NumRow, Alignment >::base_ptr(), blender::BLI_rcti_size_x(), blender::BLI_rcti_size_y(), C, blender::CTX_data_scene(), blender::CTX_wm_region(), blender::CTX_wm_region_view3d(), blender::Scene::cursor, blender::MatBase< float, 4, 4 >::identity(), blender::RegionView3D::is_persp, blender::View3DCursor::location, blender::wmEvent::mval, blender::wmOperator::ptr, blender::RNA_boolean_set(), blender::RNA_float_set_array(), blender::RNA_int_set_array(), store_input_node_values_rna_props(), blender::RegionView3D::viewmat, blender::math::QuaternionBase< T >::w, blender::RegionView3D::winmat, and blender::ARegion::winrct.

Referenced by run_node_group_invoke(), and store_input_node_values_rna_props().

◆ store_result_geometry()

void blender::ed::geometry::store_result_geometry ( const bContext & C,
const wmOperator & op,
const Depsgraph & depsgraph,
Main & bmain,
Scene & scene,
Object & object,
const RegionView3D * rv3d,
bke::GeometrySet geometry )
static

◆ tree_add_type()

◆ ui_template_node_operator_asset_menu_items()

◆ ui_template_node_operator_asset_root_items()

◆ ui_template_node_operator_registration_errors()

Variable Documentation

◆ convert_attribute_mode_items

EnumPropertyItem blender::ed::geometry::convert_attribute_mode_items[]
static
Initial value:
= {
{int(ConvertAttributeMode::Generic), "GENERIC", 0, "Generic", ""},
{int(ConvertAttributeMode::VertexGroup), "VERTEX_GROUP", 0, "Vertex Group", ""},
{0, nullptr, 0, nullptr, nullptr},
}

Definition at line 1036 of file geometry_attributes.cc.

Referenced by geometry_attribute_convert_mode_itemf(), and GEOMETRY_OT_attribute_convert().