Simplifying 3D Printing with OpenSCAD by Colin Dow

Simplifying 3D Printing with OpenSCAD by Colin Dow

Author:Colin Dow
Language: eng
Format: epub
Publisher: Packt Publishing Pvt Ltd
Published: 2022-02-25T00:00:00+00:00


This code will check the length of display_text and multiply it by the size of a single character (8.3). Change the value of display_text back to the original text. Our completed code should look as follows:display_text="Good Job!";

linear_extrude(5)

text(display_text, font="Courier New:style=Regular");

echo(len(display_text));

cube([len(display_text)*8.3,9,2]);

Hit F6 or click the Render button. Verify that the backing plate covers all the text:

Figure 5.15 – Dynamic backing plate

To use our dynamic backing plate code with different text, we can simply change the value of display_text and render our design. Let's do just that. Change the value of display_text to the following:display_text="Best in Class!";



Download



Copyright Disclaimer:
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.