24 .
description(
N_(
"The number of vertices on the top and bottom circles"));
29 .
description(
N_(
"The number of rectangular segments along each side"));
34 .
description(
N_(
"The number of concentric rings used to fill the round faces"));
55 uiItemR(layout,
ptr,
"fill_type", 0,
nullptr, ICON_NONE);
64 node->storage = node_storage;
84 const float radius =
params.extract_input<
float>(
"Radius");
85 const float depth =
params.extract_input<
float>(
"Depth");
86 const int circle_segments =
params.extract_input<
int>(
"Vertices");
87 if (circle_segments < 3) {
89 params.set_default_remaining_outputs();
93 const int side_segments =
params.extract_input<
int>(
"Side Segments");
94 if (side_segments < 1) {
96 params.set_default_remaining_outputs();
101 const int fill_segments = no_fill ? 1 :
params.extract_input<
int>(
"Fill Segments");
102 if (fill_segments < 1) {
104 params.set_default_remaining_outputs();
109 if (
params.output_is_required(
"Top")) {
112 if (
params.output_is_required(
"Bottom")) {
115 if (
params.output_is_required(
"Side")) {
129 if (attribute_outputs.
top_id) {
131 AnonymousAttributeFieldInput::Create<bool>(
132 std::move(attribute_outputs.
top_id),
params.attribute_producer_name()));
137 AnonymousAttributeFieldInput::Create<bool>(std::move(attribute_outputs.
bottom_id),
138 params.attribute_producer_name()));
140 if (attribute_outputs.
side_id) {
142 AnonymousAttributeFieldInput::Create<bool>(
143 std::move(attribute_outputs.
side_id),
params.attribute_producer_name()));
General operations, lookup, etc. for materials.
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_CYLINDER
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)
GeometryNodeMeshCircleFillType
@ GEO_NODE_MESH_CIRCLE_FILL_NGON
@ GEO_NODE_MESH_CIRCLE_FILL_NONE
in reality light always falls off quadratically Particle Info
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)
StringRefNull description() const
OwnedAnonymousAttributeID< true > StrongAnonymousAttributeID
static void node_update(bNodeTree *ntree, bNode *node)
static void node_declare(NodeDeclarationBuilder &b)
static void node_layout(uiLayout *layout, bContext *UNUSED(C), PointerRNA *ptr)
static void node_geo_exec(GeoNodeExecParams params)
static void node_init(bNodeTree *UNUSED(ntree), bNode *node)
Mesh * create_cylinder_or_cone_mesh(float radius_top, float radius_bottom, float depth, int circle_segments, int side_segments, int fill_segments, GeometryNodeMeshCircleFillType fill_type, ConeAttributeOutputs &attribute_outputs)
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_cylinder()
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_mesh(Mesh *mesh, GeometryOwnershipType ownership=GeometryOwnershipType::Owned)
struct bNodeSocket * next
NodeGeometryExecFunction geometry_node_execute
void(* draw_buttons)(struct uiLayout *, struct bContext *C, struct PointerRNA *ptr)
NodeDeclareFunction declare
StrongAnonymousAttributeID bottom_id
StrongAnonymousAttributeID side_id
StrongAnonymousAttributeID top_id