As of 4 August 2026, QR64Code parses G0/G1 linear moves, G2/G3 arcs, and absolute or relative positioning and extrusion modes to render the print path in three dimensions. Layer, filament, time, speed, temperature, and model-size analysis runs in the browser. The view represents printable paths in the G-code; it cannot reproduce the exact original STL or 3MF surface that existed before slicing.
What changed in this update?
Layer markers, large-file validation, volumetric filament rendering, and G-code-specific technical guides were added.
How do you use the G-code viewer?
- 1
Choose a .gcode, .gco, .gc, .nc, or text file, or paste G-code directly.
- 2
Orbit the 3D view, scrub through layers, and reveal travel moves when needed.
- 3
Check time, filament, dimensions, speed, and temperature, then export the analysis as JSON or the view as PNG.
How accurate is a G-code preview?
Estimated time comes from motion timing or a slicer's TIME field; acceleration, jerk, heating, firmware macros, and waits can change actual time. Weight uses material density declared in the file and falls back to 1.24 g/cm³ when none is provided. Vendor macros and some non-XY arcs may be approximated. G-code does not preserve the original mesh information discarded during slicing.
How was the G-code viewer tested?
In the 4 August 2026 validation, QR64Code processed a 2,128,750-byte G-code file generated for an original support-free human figure. The viewer rendered all 364 layers across 64,882 lines, measured a toolpath boundary of 84.0 × 42.0 × 72.9 mm, and estimated 6.34 m of filament. Playback started at the first layer and advanced the layer counter with no browser warnings or errors during the test.
What is the difference between a G-code preview and recovered STL?
| View | Data shown | Accuracy |
|---|---|---|
| Toolpath | Actual moves in G-code | High for supported commands |
| Volumetric filament | Approximate nozzle-width path volume | Visual approximation |
| Recovered STL | Pre-slice surface | Cannot be recovered exactly |
Frequently asked questions about G-code viewing
Can G-code be converted back to STL?
A volume resembling the printed shape can be produced, but surface topology and original model details discarded by the slicer cannot be recovered exactly.
Does a G-code viewer show the original 3D model?
A G-code viewer shows nozzle extrusion and movement paths. The result approximates the printed volume, but it is not an exact copy of the original mesh surface.
Is my file uploaded?
No. The File API reads it in the browser, the parser analyzes it locally, and WebGL draws it on your device.
Which G-code modes are supported?
The tool supports G0/G1, G2/G3 in the XY plane, G20/G21, G90/G91, M82/M83, G92, basic temperature commands, and common slicer feature comments.
Why can the time differ from my slicer?
Firmware acceleration, jerk, heating, input shaping, macros, and machine limits cannot be derived completely from motion lines alone.