-
Notifications
You must be signed in to change notification settings - Fork 675
DYN-9099 Voronoi Delaunay nodes fix #16862
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
RobertGlobant20
merged 36 commits into
DynamoDS:master
from
RobertGlobant20:DYN-9099-VoronoiDelaunayNodes-Fix
Mar 12, 2026
Merged
Changes from all commits
Commits
Show all changes
36 commits
Select commit
Hold shift + click to select a range
c4db4c5
DYN-9099 Voronoi Dealunay nodes Fix
RobertGlobant20 4a8fd36
DYN-9099 Voronoi Dealunay nodes Fix
RobertGlobant20 6023e86
DYN-9099 Voronoi Dealunay nodes Fix
RobertGlobant20 d032533
Merge branch 'master' into DYN-9099-VoronoiDelaunayNodes-Fix
RobertGlobant20 399c222
DYN-9099 Voronoi Dealunay nodes Code Review
RobertGlobant20 7bc648b
DYN-9099 Voronoi Dealunay nodes Code Review
RobertGlobant20 fddd922
DYN-9099 Voronoi Dealunay nodes Code Review
RobertGlobant20 258da45
DYN-9099 Voronoi Dealunay nodes Unit Tests
RobertGlobant20 84127c2
Merge branch 'master' into DYN-9099-VoronoiDelaunayNodes-Fix
RobertGlobant20 f28a5a3
DYN-9099 Voronoi Dealunay nodes Fix
RobertGlobant20 a3dc003
DYN-9099 Voronoi Dealunay nodes RefactorCode
RobertGlobant20 2a7edbb
Merge branch 'master' into DYN-9099-VoronoiDelaunayNodes-Fix
RobertGlobant20 22de43e
DYN-9099 Voronoi Dealunay nodes Conflicts
RobertGlobant20 5df02ca
Merge branch 'master' into DYN-9099-VoronoiDelaunayNodes-Fix
RobertGlobant20 c6b2c32
Merge branch 'master' into DYN-9099-VoronoiDelaunayNodes-Fix
RobertGlobant20 464c5be
DYN-9099-VoronoiDelaunayNodes-Fix
RobertGlobant20 c263a2a
DYN-9099 Voronoi Dealunay nodes Code Review
RobertGlobant20 e581e66
DYN-9099 VoronoiDelaunay Nodes Fix
RobertGlobant20 dcfa5df
DYN-9099 Voronoi Dealunay nodes Code Review
RobertGlobant20 18d03ab
Merge branch 'master' into DYN-9099-VoronoiDelaunayNodes-Fix
RobertGlobant20 c754244
Update Tessellation.csproj
RobertGlobant20 525e8f3
Update Tessellation.csproj
RobertGlobant20 c4140ba
Update Tessellation.csproj
RobertGlobant20 5d130cc
Update Tessellation.csproj
RobertGlobant20 3453020
Merge branch 'master' into DYN-9099-VoronoiDelaunayNodes-Fix
RobertGlobant20 e0c9607
Merge branch 'master' into DYN-9099-VoronoiDelaunayNodes-Fix
RobertGlobant20 10d29f2
Fixing the ComputeDelaunayTrianglesInScaledUvSpace method
RobertGlobant20 51b1a83
Fixing the tests
RobertGlobant20 f80ed6f
DYN-9099 VoronoiDelaunayNodes Fix Code Review
RobertGlobant20 a3044aa
Merge branch 'master' into DYN-9099-VoronoiDelaunayNodes-Fix
RobertGlobant20 79c5b0a
Merge branch 'master' into DYN-9099-VoronoiDelaunayNodes-Fix
RobertGlobant20 eee84f6
Merge Fixes
RobertGlobant20 e3727d6
Merge Fixes
RobertGlobant20 951f995
DYN-9099-VoronoiDelaunay-CodeReview
RobertGlobant20 c7b7f48
Merge branch 'master' into DYN-9099-VoronoiDelaunayNodes-Fix
RobertGlobant20 4235b3d
Merge branch 'master' into DYN-9099-VoronoiDelaunayNodes-Fix
RobertGlobant20 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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,43 @@ | ||
| using Autodesk.DesignScript.Geometry; | ||
|
|
||
| namespace Tessellation | ||
| { | ||
| /// <summary> | ||
| /// Utility functions for UV scaling on surfaces. | ||
| /// </summary> | ||
| internal static class UvScalingUtilities | ||
| { | ||
| /// <summary> | ||
| /// Computes normalized UV scaling factors for a surface to handle anisotropic parameter spaces. | ||
| /// The scaling preserves the aspect ratio while keeping values in a reasonable numerical range. | ||
| /// </summary> | ||
| /// <param name="face">Surface to compute scaling factors for.</param> | ||
| /// <returns>Tuple containing normalized U and V scale factors.</returns> | ||
| internal static (double normU, double normV) GetNormalizedUvScales(Surface face) | ||
| { | ||
| // Physical scale per unit U/V based on iso-curve lengths along surface edges. | ||
| double scaleU; | ||
| double scaleV; | ||
| using (var uCurveV0 = face.GetIsoline(0, 0)) | ||
| using (var uCurveV1 = face.GetIsoline(0, 1)) | ||
| using (var vCurveU0 = face.GetIsoline(1, 0)) | ||
| using (var vCurveU1 = face.GetIsoline(1, 1)) | ||
| { | ||
| scaleU = (uCurveV0.Length + uCurveV1.Length) / 2.0; | ||
| scaleV = (vCurveU0.Length + vCurveU1.Length) / 2.0; | ||
| } | ||
|
|
||
| // Normalize scales to keep values in a reasonable range, preserve aspect ratio | ||
| var max = System.Math.Max(scaleU, scaleV); | ||
| if (max <= 1e-9) max = 1.0; | ||
|
|
||
| var normU = scaleU / max; | ||
| var normV = scaleV / max; | ||
|
|
||
| if (normU <= 1e-9) normU = 1.0; | ||
| if (normV <= 1e-9) normV = 1.0; | ||
|
|
||
| return (normU, normV); | ||
| } | ||
| } | ||
| } |
This file contains hidden or 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
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@RobertGlobant20 have you explored updating the StarMath library as well? It's used specifically in this project for Voronoi and Delaunay computations.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
StarMath is used as a small linear-algebra helper for circumcenter calculations. I can see that inside Cell2 class we are calling StarMath.determinant to compute triangle circumcenters from determinant formulas.
