raygeo.ops
Command sequence (Ops) manipulation for laser cutter motion control.
Ops is a container of ordered commands (move, line, arc, bezier, state changes like power/speed) that defines a complete laser engraving or cutting job. It supports building sequences programmatically (move_to, line_to, arc_to, etc.), transforming them (translate, rotate, scale, transform with 4x4 matrices), clipping to rectangles or regions, linearizing curves, estimating processing time, and serializing to dict or numpy arrays for persistence.
The module also provides command-type enumerations (CommandType, CommandCategory, SectionType), machine State tracking (power, speed, air assist, frequency), and an Axis bitflag for multi-axis machines.
CommandInfo
Detailed information about a single command in an Ops sequence.
Returned by Ops.inspect and provides the full set of parameters for any command type in a structured form.
center_offset
center_offset: Optional[tuple[float, float]]
clockwise
clockwise: Optional[bool]
control
control: Optional[tuple[float, float, float]]
control1
control1: Optional[tuple[float, float, float]]
control2
control2: Optional[tuple[float, float, float]]
duration_ms
duration_ms: Optional[float]
end
end: Optional[tuple[float, float, float]]