38 .default_value({0.0f, 0.0f, 1.0f})
41 "In offset mode, the distance between each socket on each axis. In end points mode, the "
42 "position of the final vertex"));
50 uiItemR(layout,
ptr,
"mode", 0,
"", ICON_NONE);
52 uiItemR(layout,
ptr,
"count_mode", 0,
"", ICON_NONE);
63 node->storage = node_storage;
99 else if (
params.node_tree().typeinfo->validate_link(
104 params.connect_available_socket(
node,
"Count");
110 params.connect_available_socket(
node,
"Resolution");
114 params.connect_available_socket(
node,
"Start Location");
118 params.connect_available_socket(
node,
"Offset");
124 params.connect_available_socket(
node,
"Offset");
141 const float3 total_delta = end - start;
145 const float resolution =
std::max(
params.extract_input<
float>(
"Resolution"), 0.0001f);
151 const int count =
params.extract_input<
int>(
"Count");
163 const int count =
params.extract_input<
int>(
"Count");
189 for (const int i : range) {
190 copy_v3_v3(verts[i].co, start + delta * i);
196 for (const int i : range) {
199 edges[i].flag |= ME_LOOSEEDGE;
typedef float(TangentPoint)[2]
General operations, lookup, etc. for materials.
void BKE_id_material_eval_ensure_default_slot(struct ID *id)
struct Mesh * BKE_mesh_new_nomain(int verts_len, int edges_len, int tessface_len, int loops_len, int polys_len)
void node_type_update(struct bNodeType *ntype, void(*updatefunc)(struct bNodeTree *ntree, struct bNode *node))
#define NODE_STORAGE_FUNCS(StorageT)
void nodeSetSocketAvailability(struct bNodeTree *ntree, struct bNodeSocket *sock, bool is_available)
void node_type_init(struct bNodeType *ntype, void(*initfunc)(struct bNodeTree *ntree, struct bNode *node))
#define NODE_CLASS_GEOMETRY
#define GEO_NODE_MESH_PRIMITIVE_LINE
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))
void nodeRegisterType(struct bNodeType *ntype)
GeometryNodeMeshLineCountMode
@ GEO_NODE_MESH_LINE_COUNT_RESOLUTION
@ GEO_NODE_MESH_LINE_COUNT_TOTAL
@ GEO_NODE_MESH_LINE_MODE_END_POINTS
@ GEO_NODE_MESH_LINE_MODE_OFFSET
void uiLayoutSetPropSep(uiLayout *layout, bool is_sep)
void uiItemR(uiLayout *layout, struct PointerRNA *ptr, const char *propname, int flag, const char *name, int icon)
void uiLayoutSetPropDecorate(uiLayout *layout, bool is_sep)
Span< SocketDeclarationPtr > outputs() const
StringRefNull description() const
T length(const vec_base< T, Size > &a)
vec_base< T, Size > normalize(const vec_base< T, Size > &v)
static void node_layout(uiLayout *layout, bContext *UNUSED(C), PointerRNA *ptr)
static void node_init(bNodeTree *UNUSED(ntree), bNode *node)
static void node_geo_exec(GeoNodeExecParams params)
static void node_declare(NodeDeclarationBuilder &b)
static void node_update(bNodeTree *ntree, bNode *node)
static void node_gather_link_searches(GatherLinkSearchOpParams ¶ms)
Mesh * create_line_mesh(const float3 start, const float3 delta, int count)
void search_link_ops_for_declarations(GatherLinkSearchOpParams ¶ms, Span< SocketDeclarationPtr > declarations)
void parallel_for(IndexRange range, int64_t grain_size, const Function &function)
void parallel_invoke(Functions &&...functions)
vec_base< float, 3 > float3
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_mesh_primitive_line()
void geo_node_type_base(bNodeType *ntype, int type, const char *name, short nclass)
void node_sock_label(bNodeSocket *sock, const char *name)
void node_copy_standard_storage(bNodeTree *UNUSED(dest_ntree), bNode *dest_node, const bNode *src_node)
void node_free_standard_storage(bNode *node)
int RNA_enum_get(PointerRNA *ptr, const char *name)
static GeometrySet create_with_mesh(Mesh *mesh, GeometryOwnershipType ownership=GeometryOwnershipType::Owned)
struct bNodeSocket * next
NodeGeometryExecFunction geometry_node_execute
NodeGatherSocketLinkOperationsFunction gather_link_search_ops
void(* draw_buttons)(struct uiLayout *, struct bContext *C, struct PointerRNA *ptr)
NodeDeclareFunction declare