ParaShape

Producers

Steps that create geometry or records. A producer starts a chain or replaces the stream with new data.

30 methods: linearDimension, leader, centerMark, radialDimension, angularDimension, image, textCurve, polyline, curveFromFace, curveFunction, rectangle, polygon, arcCenterStartEnd, arcThreePoints, arcTangentEnd, circle, ellipseArc, cubicBezier, quadraticBezier, nurbsCurve, spline, revisionCloud, mesh, straightSkeleton, hatch, clone, placeComponent, curveFrom, pointCloud, section.

linearDimension - Linear Dimension

Distances along start–end, split by ratios, drawn on a line offset from it.

role producer, type step, valid on curve, mesh, block, returns linearDimensionData[], default key dimension.

ArgTypeDefaultMinMaxOptionsDescription
startpoint[0,0,0]The first measured point.
endpoint[100,0,0]The last measured point.
offsetvector[0,-10,0]From the start–end line to the dimension line; must be perpendicular to end − start.
ratiosnumber[][1]Relative weights start–end is split by, one segment each: [1, 2, 1] = quarter, half, quarter.
styleobjectInline style object (fontSize, endpoint, endpointSize, decimals, rounding, textSuffix, extensionOffset, extensionOvershoot, lineOvershoot); no lane to name a style by — a string value fails loud.
textstring''Override label text; empty draws the measured distance instead.

leader - Leader

An arrow from target to landing, carrying text.

role producer, type step, valid on curve, mesh, block, returns leaderData[], default key leader.

ArgTypeDefaultMinMaxOptionsDescription
targetspoint[][[0,0,0]]Points the arrow(s) reach; one arrow per point, all landing at landing.
landingpoint[20,10,0]Point [x, y, z] in mm every arrow converges to and the text sits at.
textstring''Label text drawn at the landing; empty draws no text.
styleobjectInline style object (fontSize, endpoint, endpointSize); no lane to name a style by — a string value fails loud.

centerMark - Center Mark

The cross at a circle's centre; plain linework, measures nothing.

role producer, type step, valid on curve, returns curveData[], default key centerMark.

ArgTypeDefaultMinMaxOptionsDescription
centerpoint[0,0,0]Point [x, y, z] in mm the cross is centered on.
styleobjectInline style object ({ centerMarkSize } in mm); no lane to name a style by — a string value fails loud.

radialDimension - Radial Dimension

A leader from a circle/arc's rim, labelled with its radius.

role producer, type step, valid on curve, mesh, block, returns radialDimensionData[], default key dimension.

ArgTypeDefaultMinMaxOptionsDescription
curvecurveData | point[]Circle/arc to measure (a curve, a sibling object, or point rows [x,y,z]) — its centre, radius and plane are recovered by fitting.
angleangle45Where around the circle the leader points, degrees.
styleobjectInline style object (fontSize, endpoint, endpointSize, decimals, rounding, textSuffix); no lane to name a style by — a string value fails loud.
textstring''Override label text; empty draws the measured radius instead.

angularDimension - Angular Dimension

The angle at vertex between point1 and point2; arcPoint sets the arc's radius and which side it sweeps.

role producer, type step, valid on curve, mesh, block, returns angularDimensionData[], default key dimension.

ArgTypeDefaultMinMaxOptionsDescription
vertexpoint[0,0,0]The angle's vertex point [x, y, z] in mm.
point1point[100,0,0]A point [x, y, z] in mm on the angle's first ray, measured from vertex.
point2point[0,100,0]A point [x, y, z] in mm on the angle's second ray, measured from vertex.
arcPointpoint[12,12,0]Point [x, y, z] in mm whose distance from vertex sets the arc's radius and whose side of point1's ray picks the sweep direction.
styleobjectInline style object (fontSize, endpoint, endpointSize, decimals, rounding, textSuffix); no lane to name a style by — a string value fails loud.
textstring''Override label text; empty draws the measured angle instead.

image - Image

A picture placed on a rectangle, plus its border frame.

role producer, type step, valid on curve, mesh, block, returns imageData[], default key image.

ArgTypeDefaultMinMaxOptionsDescription
urlurl''A url-method parameter key or a direct URI.
atpoint[0, 0, 0]The rectangle's local bottom-left corner; width runs along +x, height along +y.
widthlength80Rectangle width in mm.
heightlength00 or negative falls back to width * 3/4.

textCurve - Text

Glyph outline curves, width-wrapped and placed on a plane.

role producer, type step, valid on curve, returns curveData[], default key text.

ArgTypeDefaultMinMaxOptionsDescription
positionpoint[0,0,0]The text's local origin [x, y, z] in mm, on the plane spanned by normal/xAxis.
textstring''The string to render as glyph outlines; empty produces no geometry.
fontfontA font's url, registered via engine_add_font; not yet loaded fails soft with a pending font request. Empty resolves to the host's own default font.
widthlength0Wrap width in mm; 0 or absent means no width-wrapping (only newlines break lines).
styleobjectInline style object ({ height } in mm, the glyph height); no lane to name a style by — a string value fails loud. Absent uses the 3.5mm builtin.
normalvector[0,0,1]Unit plane normal in object-local space the text is drawn on; zero-length fails loud.
xAxisvector[1,0,0]In-plane direction for the text's local +X, re-orthogonalized against normal; parallel to normal fails loud.

polyline - Polyline

A straight-sided chain through the given points.

role producer, type step, valid on curve, returns curveData[], default key polyline.

ArgTypeDefaultMinMaxOptionsDescription
pointspoint[][[0,0,0],[100,0,0],[100,0,100]]Ordered vertices.
closedbooleanfalseClose the loop back to the first point.

curveFromFace - Curves From Face

Every boundary loop of the referenced mesh's faces, outer and holes alike.

role producer, type step, valid on curve, returns curveData[], default key outline.

ArgTypeDefaultMinMaxOptionsDescription
sourcemeshData[]Node whose face boundaries to outline.

curveFunction - Curve From Function

Sample a formula (t) => [x,y,z] into a raw sampled polyline.

role producer, type step, valid on curve, returns curveData[], default key curve.

ArgTypeDefaultMinMaxOptionsDescription
pointfunction(t) => [50 * Math.cos(t * 6 * Math.PI), 50 * Math.sin(t * 6 * Math.PI), t * 300]Callback (t) => [x,y,z], t in [0,1].
samplesnumber642Points sampled along t.
closedbooleanfalseJoin the end back to the start.

rectangle - Rectangle

A closed 4-vertex rectangle in the plane of least spread.

role producer, type step, valid on curve, returns curveData[], default key rectangle.

ArgTypeDefaultMinMaxOptionsDescription
point1point[0,0,0]One corner.
point2point[100,100,0]Opposite corner; the smallest-spread axis is the plane normal.

polygon - Polygon

A regular polygon in the XY plane.

role producer, type step, valid on curve, returns curveData[], default key polygon.

ArgTypeDefaultMinMaxOptionsDescription
centerpoint[0,0]Polygon center; the plane normal is fixed to +Z, so the polygon lies flat at this point's own Z height.
radiuslength50Circumradius, mm — distance from center to each vertex.
sidesinteger63Minimum 3.

arcCenterStartEnd - Arc (Center)

Circular arc from center, start on the rim, and end direction.

role producer, type step, valid on curve, returns curveData[], default key arc.

ArgTypeDefaultMinMaxOptionsDescription
centerpoint[0,0]Arc center; radius is the distance to startPoint.
startPointpoint[10,0]Where the arc begins; sets the radius.
endPointpoint[0,10]Sweep direction, snapped onto the radius.
segmentsinteger321Edges sampled along this curve. Closed curves need at least 3.

arcThreePoints - Arc (3 Points)

Circular arc through three points.

role producer, type step, valid on curve, returns curveData[], default key arc.

ArgTypeDefaultMinMaxOptionsDescription
startPointpoint[0,0]First endpoint the arc passes through.
middlePointpoint[5,5]Point on the arc between start and end.
endPointpoint[10,0]Last endpoint the arc passes through.
segmentsinteger321Edges sampled along this curve. Closed curves need at least 3.

arcTangentEnd - Arc (Tangent)

Arc leaving an axis and ending at a point.

role producer, type step, valid on curve, returns curveData[], default key arc.

ArgTypeDefaultMinMaxOptionsDescription
axisline{ origin: [0,0,0], direction: [0,1,0] }Start point plus leaving tangent ({ origin, direction }).
endPointpoint[10,0]Where the arc ends.
segmentsinteger321Edges sampled along this curve. Closed curves need at least 3.

circle - Circle

Closed circle in the plane of center + normal.

role producer, type step, valid on curve, returns curveData[], default key circle.

ArgTypeDefaultMinMaxOptionsDescription
centerpoint[0,0]Circle center.
radiuslength10Circle radius.
normalvector[0,0,1]Plane normal; default Z-up.
segmentsinteger321Edges sampled along this curve. Closed curves need at least 3.

ellipseArc - Ellipse Arc

Elliptical arc (or full ellipse at 360°) from two axis vectors.

role producer, type step, valid on curve, returns curveData[], default key ellipse.

ArgTypeDefaultMinMaxOptionsDescription
centerpoint[0,0]Ellipse center.
xAxisvector[10,0]Major-axis vector; its length is the X radius.
yAxisvector[0,5]Minor-axis vector; its length is the Y radius. The plane is xAxis × yAxis.
angleangle360Sweep in degrees: 360 = full closed ellipse, under 360 = open arc.
segmentsinteger321Edges sampled along this curve. Closed curves need at least 3.

cubicBezier - Cubic Bezier

Cubic Bezier through start/end with two tangent controls.

role producer, type step, valid on curve, returns curveData[], default key bezier.

ArgTypeDefaultMinMaxOptionsDescription
startpoint[0,0,0]Start point (on curve).
control1point[3,10,0]First tangent control point.
control2point[7,10,0]Second tangent control point.
endpoint[10,0,0]End point (on curve).
segmentsinteger321Edges sampled along this curve. Closed curves need at least 3.

quadraticBezier - Quadratic Bezier

Quadratic Bezier through start/end with one control.

role producer, type step, valid on curve, returns curveData[], default key bezier.

ArgTypeDefaultMinMaxOptionsDescription
startpoint[0,0,0]Start point (on curve).
controlpoint[5,10,0]Tangent control (pulled toward, not on curve).
endpoint[10,0,0]End point (on curve).
segmentsinteger321Edges sampled along this curve. Closed curves need at least 3.

nurbsCurve - NURBS Curve

NURBS curve from a control net, then baked to a polyline.

role producer, type step, valid on curve, returns curveData[], default key nurbs.

ArgTypeDefaultMinMaxOptionsDescription
pointspoint[][[0,0,0],[3,5,0],[7,5,0],[10,0,0]]Control points of the hull; the curve is pulled toward them, not through.
degreenumber3Polynomial degree; must be >= 1 and <= points.length-1.
knotsnumber[][]Knot vector (length = points.length + degree + 1). Empty = clamped-uniform.
weightsnumber[][]Per-point weight > 0. Empty = uniform 1.
segmentsinteger321Edges sampled along this curve. Closed curves need at least 3.

spline - Spline

Interpolating spline through the given points, then baked.

role producer, type step, valid on curve, returns curveData[], default key spline.

ArgTypeDefaultMinMaxOptionsDescription
pointspoint[][[0,0,0],[40,0,40],[80,0,20],[120,0,60]]Points the spline interpolates through.
degreenumber3Polynomial degree; must be >= 1 and <= points.length-1. A closed spline must be degree 3, or the step fails.
segmentsinteger321Edges sampled along this curve. Closed curves need at least 3.
closedbooleanfalseClose into a loop, tangent-continuous where it closes (cubic).

revisionCloud - Revision Cloud

Chain of small outward-bulging arcs, baked to segments per bump.

role producer, type step, valid on curve, returns curveData[], default key revisionCloud.

ArgTypeDefaultMinMaxOptionsDescription
boundarypoint[][[0,0,0],[100,0,0],[100,100,0],[0,100,0]]Ordered polygon vertices to bulge, implicitly closed back to the first point.
bumpRadiuslength15Clamped to 45% of the bump chord.
bumpSpacinglength40Target arc length between bump centers along each edge, mm; every non-degenerate edge still gets at least one bump.

mesh - Mesh

Starts the stream with exactly this Mesh.

role producer, type step, valid on -, returns meshData[], default key mesh.

ArgTypeDefaultMinMaxOptionsDescription
dataobject{"vertices":[],"edges":[],"faces":[]}The Mesh itself: { vertices, edges, faces }; a closed shell (every edge used by exactly two faces) or empty for no mesh.

straightSkeleton - Straight Skeleton

Straight skeleton of a simple polygon, as lifted roof faces thickened into a closed solid.

role producer, type step, valid on mesh, returns meshData[], default key skeleton.

ArgTypeDefaultMinMaxOptionsDescription
boundarypoint[][[0,0,0],[6000,0,0],[6000,4000,0],[0,4000,0]]Simple polygon outline in object space, implicitly closed (last point connects back to the first).
pitchangle30Roof slope from horizontal, degrees; zero or negative fails loud, and any positive value is otherwise unclamped (90 drives the rafters to tan(90°), effectively vertical).
thicknesslength0Roof thickness, mm, measured perpendicular to every roof face and offset below the roof surface (Blender even thickness, MeshBuild::thicken); must be > 0, the default 0 fails loud because no thickness is a surface, never a solid.

hatch - Hatch

A region filled by a named pattern, a solid/gradient fill, or both.

role producer, type step, valid on curve, mesh, block, returns hatchData[], default key hatch.

ArgTypeDefaultMinMaxOptionsDescription
regioncurveData | point[]The filled region: a closed world-space ring, or point rows [x,y,z] with the first row repeated last.
patternpatternpatterns[] record key.
angleangle0Pattern rotation within the region's own plane (hatch-local x/y axes), degrees.
scalenumber1Multiplier on the pattern's authored line spacing; 1 = as authored.
originpointPattern origin offset [x, y] in the region's own plane, mm (hatch-local, not world). Only x and y are read; a third component, if given, is ignored.
colorcolorCSS color overriding the pattern's own stroke color; absent uses the pattern's own.
fillobjectSolid or gradient fill under the pattern ({ type: 'solid'|'linearGradient'|'radialGradient', ... }); at least one of pattern or fill is required.

clone - Clone

Starts the chain with another object as it exists — content and placements — by key.

role producer, type step, valid on curve, mesh, block, returns objectData[], default key clone.

ArgTypeDefaultMinMaxOptionsDescription
sourceobjectData[][]Node to copy — an independent deep copy.

placeComponent - Place Component

Starts the chain with a components[] entry evaluated under parameters, as one block.

role producer, type step, valid on curve, mesh, block, returns objectData[], default key component.

ArgTypeDefaultMinMaxOptionsDescription
componentcomponentA component of the enclosing scope's components lane.
parametersobjectOverrides the component's own parameter values for this placement. An arrow (copy) => ({ ... }) is called once per copy of the carrying object (copies + 1) and must return an object; it must be the object's only step, and the object's copies and scalar placement properties (translateX..pivotZ, each may be an arrow (i) => number) then place each copy's block; name/material/layer/visible/attributes are evaluated per copy on that copy's block.

curveFrom - Curve From

Bakes point rows, a curve value, a raw { vertices, edges } Curve, or a sibling object's curve into document geometry.

role producer, type step, valid on curve, returns curveData[], default key curveFrom.

ArgTypeDefaultMinMaxOptionsDescription
curvepoint[] | curveData | blockData | object[[0,0,0],[100,0,0],[100,100,0]]Point rows [x,y,z] in mm (closed when the first row is repeated last), an existing curve value, a sibling object's placed curve, or a raw { vertices, edges } Curve object.
degreenumber1For point rows: 1 bakes a polyline (any other value fails loud). For an analytic curve value (Arc/Ellipse/Bezier/Nurbs/Spline): a minimum tessellation segment count, auto-increased for a 0.5mm chord deflection.

pointCloud - Render Points

Render-only markers, not construction geometry.

role producer, type step, valid on pointCloud, returns pointCloudData[], default key point.

ArgTypeDefaultMinMaxOptionsDescription
positionspoint[][[0,0,0]]Marker positions to visualize.

section - Section Plane

A cutting plane a section view reads.

role producer, type step, valid on curve, mesh, block, returns sectionData[], default key section.

ArgTypeDefaultMinMaxOptionsDescription
pointpoint[0,0,0]A point on the cutting plane.
normalvector[1,0,0]Section views look along -normal.
activeobject | functiontruetrue cuts in every view including the free camera, false cuts in none, a non-empty list names exactly the views it cuts in, or an arrow (i, camera) => boolean (i = 0) cuts for every camera the function returns true for (the free camera included; see the view type for the record it receives).

Edit on GitHub