Differential D13043 Diff 44271 source/blender/nodes/geometry/nodes/legacy/node_geo_align_rotation_to_vector.cc
Changeset View
Changeset View
Standalone View
Standalone View
source/blender/nodes/geometry/nodes/legacy/node_geo_align_rotation_to_vector.cc
| Show All 20 Lines | |||||
| #include "UI_resources.h" | #include "UI_resources.h" | ||||
| #include "node_geometry_util.hh" | #include "node_geometry_util.hh" | ||||
| namespace blender::nodes { | namespace blender::nodes { | ||||
| static void geo_node_align_rotation_to_vector_declare(NodeDeclarationBuilder &b) | static void geo_node_align_rotation_to_vector_declare(NodeDeclarationBuilder &b) | ||||
| { | { | ||||
| b.add_input<decl::Geometry>("Geometry"); | b.add_input<decl::Geometry>(N_("Geometry")); | ||||
| b.add_input<decl::String>("Factor"); | b.add_input<decl::String>(N_("Factor")); | ||||
| b.add_input<decl::Float>("Factor", "Factor_001") | b.add_input<decl::Float>(N_("Factor"), "Factor_001") | ||||
| .default_value(1.0f) | .default_value(1.0f) | ||||
| .min(0.0f) | .min(0.0f) | ||||
| .max(1.0f) | .max(1.0f) | ||||
| .subtype(PROP_FACTOR); | .subtype(PROP_FACTOR); | ||||
| b.add_input<decl::String>("Vector"); | b.add_input<decl::String>(N_("Vector")); | ||||
| b.add_input<decl::Vector>("Vector", "Vector_001") | b.add_input<decl::Vector>(N_("Vector"), "Vector_001") | ||||
| .default_value({0.0, 0.0, 1.0}) | .default_value({0.0, 0.0, 1.0}) | ||||
| .subtype(PROP_ANGLE); | .subtype(PROP_ANGLE); | ||||
| b.add_output<decl::Geometry>("Geometry"); | b.add_output<decl::Geometry>(N_("Geometry")); | ||||
| } | } | ||||
| static void geo_node_align_rotation_to_vector_layout(uiLayout *layout, | static void geo_node_align_rotation_to_vector_layout(uiLayout *layout, | ||||
| bContext *UNUSED(C), | bContext *UNUSED(C), | ||||
| PointerRNA *ptr) | PointerRNA *ptr) | ||||
| { | { | ||||
| uiItemR(layout, ptr, "axis", UI_ITEM_R_EXPAND, nullptr, ICON_NONE); | uiItemR(layout, ptr, "axis", UI_ITEM_R_EXPAND, nullptr, ICON_NONE); | ||||
| uiLayoutSetPropSep(layout, true); | uiLayoutSetPropSep(layout, true); | ||||
| ▲ Show 20 Lines • Show All 195 Lines • Show Last 20 Lines | |||||