forked from FreeCAD/FreeCAD
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[OpenSCAD] Reimplement surface() to match OpenSCAD
The original implementation of the surface() function used a simple B-spline representation for the surface, which generated degenerate surface with several of OpenSCAD's demo input files. This commit modifies the algorithm to generate a discrete surface identical to the one generated within OpenSCAD itself. It also adds several units tests to identify future regressions. Note that PNG input is not yet supported for the surface() function.
- Loading branch information
Showing
6 changed files
with
186 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
10 9 8 7 6 5 5 5 5 5 | ||
9 8 7 6 6 4 3 2 1 0 | ||
8 7 6 6 4 3 2 1 0 0 | ||
7 6 6 4 3 2 1 0 0 0 | ||
6 6 4 3 2 1 1 0 0 0 | ||
6 6 3 2 1 1 1 0 0 0 | ||
6 6 2 1 1 1 1 0 0 0 | ||
6 6 1 0 0 0 0 0 0 0 | ||
3 1 0 0 0 0 0 0 0 0 | ||
3 0 0 0 0 0 0 0 0 0 |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
# Example comment | ||
1.0 1.1 1.3 1.7 2.5 | ||
1.1 1.3 1.7 2.5 2.7 | ||
1.3 1.7 2.5 2.7 2.9 | ||
1.7 2.5 2.7 2.9 3.0 |