Rounded Rectangle¶
Functionality¶
This node generates a Curve object, which represents a rectangle with rounded corners.
Inputs¶
This node has the following inputs:
Size X. Size of the rectangle along the X axis (rectangle width). The default value is 10.
Size Y. Size of the rectangle along the Y axis (rectangle height). The default value is 10.
Radius. Corner rounding radius. This input can consume lists of nesting level 2 or 3. If the input data have nesting level 3, then it is supposed that the input defines separate radius for each of 4 corners of each rectangle. If the radius is zero, then there will be no rounding arc generated at the corresponding corner of the rectangle. The default value is 1.0.
Parameters¶
This node has the following parameters:
Center. If checked, then the generated curve will be centered around world’s origin; in other words, the center of the rectangle will be at
(0, 0, 0)
. If not checked, the left-down corner of the rectangle will be at the origin. Unchecked by default.
Even domains. If checked, give each segment a domain of length 1. Otherwise, each arc will have a domain of length
pi/2
, and each straight line segment will have a domain of length equal to the segment’s length. Unchecked by default.
NURBS output. This parameter is available in the N panel only. If checked, the node will output a NURBS curve. Built-in NURBS maths implementation will be used. If not checked, the node will output generic concatenated curve from several straight segments and circular arcs. In most cases, there will be no difference; you may wish to output NURBS if you want to use NURBS-specific API methods with generated curve, or if you want to output the result in file format that understands NURBS only. Unchecked by default.
Outputs¶
This node has the following outputs:
Curve. The generated Curve object. The curve always lies in the XOY plane.
Centers. Center points of generated arc segments.
Text-> Stethoscope
Examples of usage¶
Simple example:
Curves-> Evaluate Curve
Matrix-> Matrix In
Matrix Multiply: Matrix-> Matrix Math
Viz-> Viewer Draw
Viz-> Viewer Index+
Vectorization example 1 - sizes only:
Curves-> Evaluate Curve
Number-> A Number
Number-> Number Range
Vector-> Vector In
Viz-> Viewer Draw
Vectorization example 2 - sizes and radiuses per rectangle:
Curves-> Evaluate Curve
Number-> A Number
Number-> Number Range
Number-> List Input
Vector-> Vector In
Viz-> Viewer Draw
Vectorization example 3 - sizes and radiuses per rectangle corner:
Curves-> Evaluate Curve
Number-> A Number
Number-> List Input
Number-> Number Range
Vector-> Vector In
List->List Struct-> List Repeater
Viz-> Viewer Draw
Text-> Stethoscope