Skip to content

Commit

Permalink
Test new parametrics that don't require constrain
Browse files Browse the repository at this point in the history
  • Loading branch information
mikeingold committed Nov 11, 2024
1 parent 1067043 commit 762b4bb
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions src/specializations/Tetrahedron.jl
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,15 @@ function _parametric(tetrahedron::Meshes.Tetrahedron, t1, t2, t3)
@assert (0 <= t3 <= 1)

# Take a triangular cross-section at t3
#=
rem = _constrain(1 - t3)
a = tetrahedron(0, 0, t3)
b = tetrahedron(0, rem, t3)
c = tetrahedron(rem, 0, t3)
=#
a = tetrahedron(t3, 0, 0)
b = tetrahedron(0, t3, 0)
c = tetrahedron(0, 0, t3)
cross_section = Meshes.Triangle(a, b, c)

return _parametric(cross_section, t1, t2)
Expand Down
2 changes: 1 addition & 1 deletion src/specializations/Triangle.jl
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ function _parametric(triangle::Meshes.Triangle, t1, t2)

# Form a horizontal line segment at t2
a = triangle(0, t2)
b = triangle(_constrain(1 - t2), t2)
b = triangle(t2, 0)
segment = Meshes.Segment(a, b)

return segment(t1)
Expand Down

0 comments on commit 762b4bb

Please sign in to comment.