Library for working with toolpath data
The library consists of the following modules:
| Module | Description |
|---|---|
| GCode | class to represent toolpath data and provide functions to work with path data |
| GCodeParser | read in GCode |
| GCodeTransform | shift or rotate toolpath data |
| GCodeAnalysis | calculate or extract data from toolpath data |
| GCodeInterpolation | interpolate path equidistantly |
| GCodeModify | tbd |
| vtkWriter | write toolpath as .vtk file and generatescalar fields |
| FFFGCodeCompiler | compile toolpath data to FFF format (RepRap) |
| LPBFGCodeCompiler | compile toolpath data to LPBF format (ORlas) |
The library functions are build around the data structures and functions existent in the GCode class.
A printing trajectory is held in a datastructure in a GCode object and consists of SubPaths which themselves consist of PathPoints.
A PathPoint is defined by its position and several machine or trajectory related values, which are:
(X, Y, Z, layerID, dX, dY, dZ, distance, feedrate, extrusion/beam expander, nozzle temp/laser power)
A SubPath is a bead or extrusion line that is printed without interruption (e.g. by travel moves) and comprises of PathPoints that define it.
Internally, a SubPath is a vector containing the coordinates of each point and several other information obtained from the GCode file. The Path is a vector containing all SubPath vectors in printing order.