A small parametric text-on-top-of-SVG plate for 3D printing, written in OpenSCAD.
Both the SVG icon and the text start at Z=0 (build plate). The text extrudes higher than the SVG, so it stands out nicely.
Features
- Text and SVG start from the build plate (no floating).
- Text height and SVG height are independent.
- SVG can be anchored to the text box (C, N, NE, E, SE, S, SW, W, NW).
- Optional offset for precise placement.
- Aspect ratio preserved via “fit by width/height”.
- Clean, readable, fully commented code.
How to use
- Replace svg_path with your own SVG (convert any shapes to paths for best results).
- Set text_str, text_size, text_thickness, font_name.
- Choose icon_fit = "width" or "height" to avoid squashing (recommended).
- Use svg_anchor and svg_offset to position the SVG relative to the text box.
- (Optional) If you know your exact text bounding box, set text_box_override = [width, height] for perfect anchoring.
Print tips
- 0.2 mm layer height works well; drop to 0.12–0.16 mm for crisp text edges.
- If your text is thin/italic, increase wall count or text_thickness for strength.
- PLA or PETG both fine. For a two-tone look, pause and filament-swap before the text starts (Z ≈ svg_thickness).