@@ -129,7 +129,7 @@ function mesh(primitive::Meshable;
129
129
attrs[:normals ] = decompose (normaltype, primitive_normals)
130
130
else
131
131
# Normals not implemented for primitive, so we calculate them!
132
- n = normals (positions, faces)
132
+ n = normals (positions, faces; normaltype = normaltype )
133
133
if n != = nothing # ok jeez, this is a 2d mesh which cant have normals
134
134
attrs[:normals ] = n
135
135
end
@@ -238,7 +238,7 @@ Attaches metadata to the coordinates of a mesh
238
238
"""
239
239
function pointmeta (mesh:: Mesh ; meta_data... )
240
240
points = coordinates (mesh)
241
- attr = GeometryBasics . attributes (points)
241
+ attr = attributes (points)
242
242
delete! (attr, :position ) # position == metafree(points)
243
243
# delete overlapping attributes so we can replace with `meta_data`
244
244
foreach (k-> delete! (attr, k), keys (meta_data))
@@ -260,7 +260,7 @@ Returns the new mesh, and the property!
260
260
"""
261
261
function pop_pointmeta (mesh:: Mesh , property:: Symbol )
262
262
points = coordinates (mesh)
263
- attr = GeometryBasics . attributes (points)
263
+ attr = attributes (points)
264
264
delete! (attr, :position ) # position == metafree(points)
265
265
# delete overlapping attributes so we can replace with `meta_data`
266
266
m = pop! (attr, property)
@@ -277,5 +277,5 @@ function facemeta(mesh::Mesh; meta_data...)
277
277
end
278
278
279
279
function attributes (hasmeta:: Mesh )
280
- return Dict ((name => getproperty (hasmeta, name) for name in propertynames (hasmeta)))
280
+ return Dict {Symbol, Any} ((name => getproperty (hasmeta, name) for name in propertynames (hasmeta)))
281
281
end
0 commit comments