Blender V5.0
blender::ed::view3d::geometry_nodes_gizmos Namespace Reference

Classes

struct  UpdateReport
struct  GizmosUpdateParams
class  NodeGizmos
class  LinearGizmo
class  DialGizmo
class  TransformGizmos
struct  GeoNodesObjectGizmoID
struct  GeometryNodesGizmoGroup

Typedefs

using ApplyChangeFn

Functions

static bool gizmo_is_interacting (const wmGizmo &gizmo)
static ThemeColorID get_gizmo_theme_color_id (const GeometryNodeGizmoColor color_id)
static ThemeColorID get_axis_theme_color_id (const int axis)
static void get_axis_gizmo_colors (const int axis, float *r_color, float *r_color_hi)
static void make_matrix_orthonormal_but_keep_z_axis (float4x4 &m)
static float4x4 matrix_from_position_and_up_direction (const float3 &position, const float3 &direction, const math::AxisSigned direction_axis)
static std::unique_ptr< NodeGizmoscreate_gizmo_node_gizmos (const bNode &gizmo_node)
static const float4x4find_direct_gizmo_transform (const bke::GeometrySet &geometry, const bke::NodeGizmoID &gizmo_id)
static bool has_nested_gizmo_transform (const bke::GeometrySet &geometry, const bke::NodeGizmoID &gizmo_id)
static std::optional< float4x4find_gizmo_geometry_transform_recursive (const bke::GeometrySet &geometry, const bke::NodeGizmoID &gizmo_id, const float4x4 &transform)
static bke::GeometrySet find_geometry_for_gizmo (const Object &object_eval, const NodesModifierData &nmd_orig, const View3D &v3d)
static std::optional< float4x4find_gizmo_geometry_transform (const bke::GeometrySet &geometry, const bke::NodeGizmoID &gizmo_id)
static bool WIDGETGROUP_geometry_nodes_poll (const bContext *C, wmGizmoGroupType *)
static void WIDGETGROUP_geometry_nodes_setup (const bContext *, wmGizmoGroup *gzgroup)
static void WIDGETGROUP_geometry_nodes_refresh (const bContext *C, wmGizmoGroup *gzgroup)
static void WIDGETGROUP_geometry_nodes_draw_prepare (const bContext *, wmGizmoGroup *)

Typedef Documentation

◆ ApplyChangeFn

Function Documentation

◆ create_gizmo_node_gizmos()

std::unique_ptr< NodeGizmos > blender::ed::view3d::geometry_nodes_gizmos::create_gizmo_node_gizmos ( const bNode & gizmo_node)
static

◆ find_direct_gizmo_transform()

const float4x4 * blender::ed::view3d::geometry_nodes_gizmos::find_direct_gizmo_transform ( const bke::GeometrySet & geometry,
const bke::NodeGizmoID & gizmo_id )
static

Finds the gizmo transform stored directly in the geometry, ignoring the instances.

Definition at line 804 of file view3d_gizmo_geometry_nodes.cc.

Referenced by find_gizmo_geometry_transform_recursive(), and has_nested_gizmo_transform().

◆ find_geometry_for_gizmo()

bke::GeometrySet blender::ed::view3d::geometry_nodes_gizmos::find_geometry_for_gizmo ( const Object & object_eval,
const NodesModifierData & nmd_orig,
const View3D & v3d )
static

Find the geometry that the gizmo should be drawn for. This is generally either the final evaluated geometry or the viewer geometry.

Definition at line 882 of file view3d_gizmo_geometry_nodes.cc.

References View3D::flag2, blender::bke::object_get_evaluated_geometry_set(), NodesModifierData::runtime, V3D_SHOW_VIEWER, and View3D::viewer_path.

Referenced by WIDGETGROUP_geometry_nodes_refresh().

◆ find_gizmo_geometry_transform()

std::optional< float4x4 > blender::ed::view3d::geometry_nodes_gizmos::find_gizmo_geometry_transform ( const bke::GeometrySet & geometry,
const bke::NodeGizmoID & gizmo_id )
static

Tries to find a transformation of the gizmo in the given geometry.

Definition at line 902 of file view3d_gizmo_geometry_nodes.cc.

References find_gizmo_geometry_transform_recursive(), and blender::MatBase< float, 4, 4 >::identity().

Referenced by WIDGETGROUP_geometry_nodes_refresh().

◆ find_gizmo_geometry_transform_recursive()

◆ get_axis_gizmo_colors()

◆ get_axis_theme_color_id()

ThemeColorID blender::ed::view3d::geometry_nodes_gizmos::get_axis_theme_color_id ( const int axis)
static

Definition at line 76 of file view3d_gizmo_geometry_nodes.cc.

References TH_AXIS_X, TH_AXIS_Y, and TH_AXIS_Z.

Referenced by get_axis_gizmo_colors().

◆ get_gizmo_theme_color_id()

◆ gizmo_is_interacting()

◆ has_nested_gizmo_transform()

bool blender::ed::view3d::geometry_nodes_gizmos::has_nested_gizmo_transform ( const bke::GeometrySet & geometry,
const bke::NodeGizmoID & gizmo_id )
static

True, if the geometry contains a transform for the given gizmo. Also checks if all instances.

Definition at line 822 of file view3d_gizmo_geometry_nodes.cc.

References find_direct_gizmo_transform(), blender::bke::InstanceReference::GeometrySet, has_nested_gizmo_transform(), and blender::bke::Instances::references().

Referenced by find_gizmo_geometry_transform_recursive(), and has_nested_gizmo_transform().

◆ make_matrix_orthonormal_but_keep_z_axis()

◆ matrix_from_position_and_up_direction()

◆ WIDGETGROUP_geometry_nodes_draw_prepare()

void blender::ed::view3d::geometry_nodes_gizmos::WIDGETGROUP_geometry_nodes_draw_prepare ( const bContext * ,
wmGizmoGroup *  )
static

Definition at line 1104 of file view3d_gizmo_geometry_nodes.cc.

Referenced by VIEW3D_GGT_geometry_nodes().

◆ WIDGETGROUP_geometry_nodes_poll()

bool blender::ed::view3d::geometry_nodes_gizmos::WIDGETGROUP_geometry_nodes_poll ( const bContext * C,
wmGizmoGroupType *  )
static

◆ WIDGETGROUP_geometry_nodes_refresh()

void blender::ed::view3d::geometry_nodes_gizmos::WIDGETGROUP_geometry_nodes_refresh ( const bContext * C,
wmGizmoGroup * gzgroup )
static

Definition at line 929 of file view3d_gizmo_geometry_nodes.cc.

References blender::Map< Key, Value, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::add(), blender::ed::view3d::geometry_nodes_gizmos::NodeGizmos::apply_change, blender::nodes::gizmos::apply_gizmo_change(), BKE_main_ensure_invariants(), C, blender::Map< Key, Value, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::contains(), create_gizmo_node_gizmos(), CTX_data_depsgraph_pointer(), CTX_data_main(), CTX_wm_manager(), CTX_wm_view3d(), wmGizmoGroup::customdata, DEG_get_evaluated(), DEG_id_tag_update_for_side_effect_request(), depsgraph, find_geometry_for_gizmo(), find_gizmo_geometry_transform(), blender::nodes::gizmos::foreach_active_gizmo(), blender::nodes::gizmos::get_editable_gizmo_elem(), blender::ed::view3d::geometry_nodes_gizmos::GeoNodesObjectGizmoID::gizmo_id, gizmo_is_interacting(), wmGizmoGroup::gizmos, blender::ComputeContext::hash(), blender::ed::view3d::geometry_nodes_gizmos::NodeGizmos::hide_all(), Object::id, ID_RECALC_GEOMETRY, bNode::identifier, blender::MatBase< float, 4, 4 >::identity(), blender::ed::view3d::geometry_nodes_gizmos::UpdateReport::invalid_transform, blender::ed::view3d::geometry_nodes_gizmos::NodeGizmos::is_any_interacting(), main, blender::ed::view3d::geometry_nodes_gizmos::UpdateReport::missing_socket_logs, NC_GEOM, ND_DATA, NodesModifierData::node_group, wmGizmoGroup::parent_gzmap, NodesModifierData::runtime, blender::ed::view3d::geometry_nodes_gizmos::NodeGizmos::show_all(), blender::ed::view3d::geometry_nodes_gizmos::NodeGizmos::update(), blender::Map< Key, Value, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::values(), WM_GIZMO_HIDDEN, WM_GIZMO_NEEDS_UNDO, WM_gizmo_set_flag(), WM_gizmo_unlink(), and WM_main_add_notifier().

Referenced by VIEW3D_GGT_geometry_nodes().

◆ WIDGETGROUP_geometry_nodes_setup()

void blender::ed::view3d::geometry_nodes_gizmos::WIDGETGROUP_geometry_nodes_setup ( const bContext * ,
wmGizmoGroup * gzgroup )
static