21 .
description(
N_(
"The number of evaluated points on the curve"));
23 .default_value({-1.0f, 0.0f, 0.0f})
25 .
description(
N_(
"Position of the start control point of the curve"));
27 .default_value({-0.5f, 0.5f, 0.0f})
30 N_(
"Position of the start handle used to define the shape of the curve. In Offset mode, "
31 "relative to Start point"));
35 N_(
"Position of the end handle used to define the shape of the curve. In Offset mode, "
36 "relative to End point"));
38 .default_value({1.0f, 0.0f, 0.0f})
40 .
description(
N_(
"Position of the end control point of the curve"));
52 MEM_cnew<NodeGeometryCurvePrimitiveBezierSegment>(__func__);
59 const float3 start_handle_right,
61 const float3 end_handle_left,
67 curves.resolution_for_write().fill(resolution);
80 handles_left.
first() = 2.0f * start - start_handle_right;
81 handles_right.
first() = start_handle_right;
83 handles_left.
last() = end_handle_left;
84 handles_right.
last() = 2.0f * end - end_handle_left;
87 handles_left.
first() = start - start_handle_right;
88 handles_right.
first() = start + start_handle_right;
90 handles_left.
last() = end + end_handle_left;
91 handles_right.
last() = end - end_handle_left;
124 "NodeGeometryCurvePrimitiveBezierSegment",
Low-level operations for curves.
#define NODE_STORAGE_FUNCS(StorageT)
void node_type_init(struct bNodeType *ntype, void(*initfunc)(struct bNodeTree *ntree, struct bNode *node))
#define NODE_CLASS_GEOMETRY
void node_type_storage(struct bNodeType *ntype, const char *storagename, void(*freefunc)(struct bNode *node), void(*copyfunc)(struct bNodeTree *dest_ntree, struct bNode *dest_node, const struct bNode *src_node))
#define GEO_NODE_CURVE_PRIMITIVE_BEZIER_SEGMENT
void nodeRegisterType(struct bNodeType *ntype)
GeometryNodeCurvePrimitiveBezierSegmentMode
@ GEO_NODE_CURVE_PRIMITIVE_BEZIER_SEGMENT_POSITION
Group Output data from inside of a node group A color picker Mix two input colors RGB to Convert a color s luminance to a grayscale value Generate a normal vector and a dot product Bright Control the brightness and contrast of the input color Vector Map an input vectors to curves
void uiItemR(uiLayout *layout, struct PointerRNA *ptr, const char *propname, int flag, const char *name, int icon)
constexpr T & last(const int64_t n=0) const
constexpr T & first() const
static CurvesGeometry & wrap(::CurvesGeometry &dna_struct)
StringRefNull description() const
Curves * curves_new_nomain_single(int points_num, CurveType type)
static void node_geo_exec(GeoNodeExecParams params)
static Curves * create_bezier_segment_curve(const float3 start, const float3 start_handle_right, const float3 end, const float3 end_handle_left, const int resolution, const GeometryNodeCurvePrimitiveBezierSegmentMode mode)
static void node_layout(uiLayout *layout, bContext *UNUSED(C), PointerRNA *ptr)
static void node_declare(NodeDeclarationBuilder &b)
static void node_init(bNodeTree *UNUSED(tree), bNode *node)
static const pxr::TfToken b("b", pxr::TfToken::Immortal)
static void node_init(const struct bContext *C, bNodeTree *ntree, bNode *node)
void register_node_type_geo_curve_primitive_bezier_segment()
MutableSpan< float3 > positions
void geo_node_type_base(bNodeType *ntype, int type, const char *name, short nclass)
void node_copy_standard_storage(bNodeTree *UNUSED(dest_ntree), bNode *dest_node, const bNode *src_node)
void node_free_standard_storage(bNode *node)
static GeometrySet create_with_curves(Curves *curves, GeometryOwnershipType ownership=GeometryOwnershipType::Owned)
NodeGeometryExecFunction geometry_node_execute
void(* draw_buttons)(struct uiLayout *, struct bContext *C, struct PointerRNA *ptr)
NodeDeclareFunction declare