Fix T48323: VRML2 tessellation fails in some cases

Apply tessellation before transformation, patch from @anpaza.
This commit is contained in:
Campbell Barton
2016-05-03 16:27:07 +10:00
parent 984d093930
commit 08eb51821c

View File

@ -178,8 +178,9 @@ def save_object(fw, global_matrix,
bm = bmesh.new() bm = bmesh.new()
bm.from_mesh(me) bm.from_mesh(me)
bm.transform(global_matrix * obj.matrix_world) # triangulate first so tessellation matches the view-port.
bmesh.ops.triangulate(bm, faces=bm.faces) bmesh.ops.triangulate(bm, faces=bm.faces)
bm.transform(global_matrix * obj.matrix_world)
# default empty # default empty
material_colors = [] material_colors = []