Skip to main content

Crate geop_ops_extrude_revolve

Crate geop_ops_extrude_revolve 

Source
Expand description

Extrude, revolve, sweep and loft as operations of a program: a sketch’s areas swept into a solid — along its plane’s normal, around an axis, along another sketch’s curves, or through other sketches’ profiles — kept as a new body or combined with one the model has; or its curves swept into a sheet, faces standing on their own. Which of these, each says by an Output.

Extrude and revolve say how far they go the same way, by an Extents: one side, both sides alike, or each side its own way — a length (an angle), up to the next face of the solid they are combined with, or through all of it.

The operations resolve what their arguments refer to — the sketch, the axis, the path — into geometry, and sweep it with geop_lib_sweep.

examples are the programs an editor offers that exercise them.

With the testing feature — which only other crates’ tests turn on — testing draws the sketches and pushes the steps their programs start from.

Modules§

examples
The examples of extruding, revolving and sweeping: programs written in Rust against the operation types, which an editor offers to load (set).

Structs§

Extents
How far an extrude or revolve goes, from its sketch’s plane: side1 along its direction — the plane’s normal, the turn’s, or against it if reversed — and, if symmetric, as far again the other way, half of a length each way; or else side2, if any, the other way on its own terms.
Extrude
Extrudes the areas of a sketch — each a lump, as a text’s letters are — along the sketch plane’s normal, into a solid named extrude(E) for the operation E — kept as a new body, or combined with another solid, see Combine; the result is extrude(E) either way. Or, as faces (Output::Faces), sweeps the sketch’s curves into faces standing on their own — the area’s outline, or a chain of curves enclosing nothing.
ExtrudeArgs
Loft
Lofts through the profiles of two or more sketches, in order, into a solid named loft(L) for the operation L — each sketch’s one area, a single loop — kept as a new body or combined with another solid (see Combine). Or, as faces (Output::Faces), into faces standing on their own: through the sketches’ loops, or through open chains of curves — between two curves, the ruled surface joining them.
LoftArgs
Revolve
Revolves the areas of a sketch around a line in its plane, into a solid named revolve(R) for the operation R — or combines that with another solid (see Combine), the result named revolve(R) all the same. Or, as faces (Output::Faces), sweeps the sketch’s curves into faces standing on their own — the area’s outline, or a chain of curves enclosing nothing.
RevolveArgs
Sweep
Sweeps the areas of a sketch — the profile — along the curves of another sketch or of a 3-D sketch — the path — into a solid named sweep(W) for the operation W, kept as a new body or combined with another solid (see Combine). Or, as faces (Output::Faces), sweeps the profile’s curves into faces standing on their own — the area’s outline, or a chain of curves enclosing nothing.
SweepArgs

Enums§

Extent
How far one side of a tool goes: a length — an angle, in degrees, for a revolve — plain or a formula of the part’s parameters, or as far as the solid it is combined with: up to its next face, or through all of it. Serialized as {"blind": 20.0}, {"blind": {"formula": "height - 2"}}, "up_to_next" or "through_all".
Output
What a step sweeping a profile makes of it: a solid — kept as a new body, or combined with another solid as Combine says — or faces standing on their own, swept from its curves: the area’s outline, or a chain of curves enclosing nothing. Faces going as far as a solid (see Extent) go as far as the solid named up_to — or, if none, every solid of the model — and leave it as it is.
PathRef
Curves a sweep runs along: the model’s (see geop_ops_model::PathRef). Curves a sweep runs along, a rail or a guide follows, or a pattern lays its instances along: a sketch’s or a 3-D sketch’s one chain of curves, or one loop, or an edge of a face.
RevolveAxis
A line a revolve turns around: a line of a sketch — its own, or another’s — a datum axis or a frame’s, a straight edge.

Functions§

register
Adds what this crate offers an editor to r: extrusions, revolutions, sweeps and lofts, and the examples of them.