[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [38896] branches/bmesh/blender/source/ blender/editors/mesh/mesh_data.c: fixed meshes added via python api have no faces
Howard Trickey
howard.trickey at gmail.com
Mon Aug 1 13:53:56 CEST 2011
Revision: 38896
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=38896
Author: howardt
Date: 2011-08-01 11:53:55 +0000 (Mon, 01 Aug 2011)
Log Message:
-----------
fixed meshes added via python api have no faces
Modified Paths:
--------------
branches/bmesh/blender/source/blender/editors/mesh/mesh_data.c
Modified: branches/bmesh/blender/source/blender/editors/mesh/mesh_data.c
===================================================================
--- branches/bmesh/blender/source/blender/editors/mesh/mesh_data.c 2011-08-01 11:44:20 UTC (rev 38895)
+++ branches/bmesh/blender/source/blender/editors/mesh/mesh_data.c 2011-08-01 11:53:55 UTC (rev 38896)
@@ -613,6 +613,9 @@
if(calc_edges || (mesh->totface && mesh->totedge == 0))
BKE_mesh_calc_edges(mesh, calc_edges);
+ if(mesh->totface > 0 && mesh->totpoly == 0)
+ convert_mfaces_to_mpolys(mesh);
+
mesh_calc_normals(mesh->mvert, mesh->totvert, mesh->mloop, mesh->mpoly, mesh->totloop, mesh->totpoly, NULL, NULL, 0, NULL, NULL);
DAG_id_tag_update(&mesh->id, 0);
More information about the Bf-blender-cvs
mailing list