diff --git a/Project.toml b/Project.toml index 77d925ba..2bf3902a 100644 --- a/Project.toml +++ b/Project.toml @@ -1,7 +1,7 @@ name = "GeometryBasics" uuid = "5c1252a2-5f33-56bf-86c9-59e7332b4326" authors = ["SimonDanisch "] -version = "0.2.13" +version = "0.2.14" [deps] IterTools = "c8e1da08-722c-5040-9ed9-7db0dc04731e" diff --git a/src/interfaces.jl b/src/interfaces.jl index 427c61f1..46997f84 100644 --- a/src/interfaces.jl +++ b/src/interfaces.jl @@ -18,7 +18,7 @@ function faces(f::AbstractVector{<:AbstractFace}) return f end -function normals(primitive, nvertices=nothing) +function normals(primitive, nvertices=nothing; kw...) # doesn't have any specific algorithm to generate normals # so will be generated from faces + positions # which we indicate by returning nothing! @@ -27,7 +27,7 @@ function normals(primitive, nvertices=nothing) return nothing end -function faces(primitive, nvertices=nothing) +function faces(primitive, nvertices=nothing; kw...) # doesn't have any specific algorithm to generate faces # so will try to triangulate the coordinates! return nothing diff --git a/test/runtests.jl b/test/runtests.jl index 6600d169..6ea81c9b 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -362,7 +362,11 @@ end @test coordinates(m) === points end - +@testset "convert mesh + meta" begin + m = uv_normal_mesh(Circle(Point2f0(0), 1f0)) + # for 2D primitives we dont actually calculate normals + @test !hasproperty(m, :normals) +end @testset "convert mesh + meta" begin m = uv_normal_mesh(FRect3D(Vec3f0(-1), Vec3f0(1, 2, 3)))