mrWheel / YAPP_Box

Yet Another Parametric Projectbox Box
https://willem.aandewiel.nl/index.php/2022/01/02/yet-another-parametric-projectbox-generator/
MIT License
279 stars 47 forks source link

Fix light tubes wall & rib rendering for rectangular shapes #86

Closed aeburriel closed 7 months ago

aeburriel commented 8 months ago

Fixes light tubes code to properly render rectangular shapes. Current code can only render properly squared & circular shapes.

Example: 27 x 14 opening for an OLED display:

lightTubes =
[
    [10.0, 10.0, 27, 14, 1, 5, yappRectangle],
    [20.0, 10.0, 27, 14, 1, 5, yappRectangle, yappNoFillet],
];

The only "missing feature", compared to circular shapes, is the ability to specify different outer and inner diameters, when tubeLength > tubeWidth. A new parameter should be added for this.