sliders - blossommerz/locus-hub GitHub Wiki
Home > Sliders & number inputs
< Previous: Adding & connecting nodes | Next: Keeping the node graph tidy >
The Nodes Window
Sliders & number inputs
Feed numbers into the node graph with sliders, constants, and range shorthand.
Most patterns are driven by numbers - counts, angles, offsets. Locus gives you two ways to supply them, plus shortcuts for setting a slider's range fast.
[!IMPORTANT] Every number on the node side is in millimeters. The working unit relabels the modeling window only; it does not reach the node graph, so a
25typed into a node input is 25 mm whatever unit you are drawing in. When your working unit is not mm, Locus shows a warning stripe across the top of the node pane so the two panes cannot be confused. See the node graph is always millimeters, and Constants & unit conversions for theintomm/mmtoinfamily that moves a value across units inside the node graph.
The Slider node
A Slider is a draggable value with a configurable range. Drag its handle to sweep a number, and everything downstream updates live - perfect for dialling in a count or an offset by eye. Its single output can fan out to as many inputs as you like, so one slider can drive several nodes at once.
Double-click the slider's value to open a small panel where you set the exact Value (the field is focused first - type a number and press Return), along with its Min, Max, and Step.
The Number node
A Number is the simplest source: a fixed numeric constant with one output and no range or stepping. Double-click its field and type the value. Use it when you want a set figure that won't move, rather than something to drag.
[!NOTE] Many node inputs accept a number typed straight into the socket, no separate node needed. Reach for a Slider or Number node when you want to reuse a value across the node graph or drag it live.
A source names itself
Wire a Slider, Number, or Color into an input and it renames itself after what it drives - a bare "Slider" feeding a Grid's Count X relabels itself Grid Count X, so a node graph full of sources reads as what they do rather than a row of identical "Slider" boxes. Drive several inputs of one node and it takes their shared name: Count X and Count Y together read Grid Count. Rename it yourself and Locus leaves your name alone; disconnecting never renames it. (Sources whose output is geometry are left as they are.)
Range shorthand: min, default, max
Instead of placing a slider and opening its config, type three comma-separated numbers into the node search - for example 0,0.05,1. Locus reads them as min, default, max and creates a slider already set to that range. It's the quickest way to spin up a ready-to-use slider.
The number of decimal places you type in the default sets the step:
0.05has two decimals, so the step is0.015has none, so the step is10.050has three, so the step is0.001
If you enter the range backward (min larger than max) Locus swaps them, and it clamps the default into range.
Snap to step
A slider only ever lands on values in its own series - starting at the minimum and stepping up by the step size (min, min + step, min + 2 x step, and so on). Whether you drag, type a value, or set it in the config dialog, the result snaps to a real series member.
Two things follow from this:
- A slider with min 1, step 2 produces 1, 3, 5, 7, 9: measured from its minimum, not from zero.
- If the maximum isn't itself on the series, the slider stops at the largest step below it. With min 1, step 2, max 10 it tops out at 9, not 10.
[!TIP] Because a default typed with N decimals always lines up with a step of that size, the
min,default,maxshorthand always produces a default that's already on the series.
< Previous: Adding & connecting nodes | Next: Keeping the node graph tidy >