Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrecht Van Lommel <brechtvanlommel@pandora.be>2012-02-21 18:39:59 +0400
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2012-02-21 18:39:59 +0400
commitd47b018f8d63b4ec68428011aba0c1f04c63ca73 (patch)
treeafb5e27b8b288ca3c3d947b4f6c53899d1676023 /source/blender/makesrna/intern/rna_object_api.c
parent6a5b34bdb55c430622ec88afc9bbd79ffe85d502 (diff)
Fix #30270, #30265: cycles not displaying textured objects, and not rendering
text/curve objects after the bmesh merge. Also removed a debug print.
Diffstat (limited to 'source/blender/makesrna/intern/rna_object_api.c')
-rw-r--r--source/blender/makesrna/intern/rna_object_api.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/source/blender/makesrna/intern/rna_object_api.c b/source/blender/makesrna/intern/rna_object_api.c
index d736a18068d..78c3c665797 100644
--- a/source/blender/makesrna/intern/rna_object_api.c
+++ b/source/blender/makesrna/intern/rna_object_api.c
@@ -116,7 +116,7 @@ Mesh *rna_Object_to_mesh(Object *ob, ReportList *reports, Scene *sce, int apply_
copycu->editnurb = NULL;
nurbs_to_mesh( tmpobj );
-
+
/* nurbs_to_mesh changes the type to a mesh, check it worked */
if (tmpobj->type != OB_MESH) {
free_libblock_us( &(G.main->object), tmpobj );
@@ -239,11 +239,14 @@ Mesh *rna_Object_to_mesh(Object *ob, ReportList *reports, Scene *sce, int apply_
break;
} /* end copy materials */
+ /* cycles and exporters rely on this still */
+ BKE_mesh_tessface_ensure(tmpmesh);
+
/* we don't assign it to anything */
tmpmesh->id.us--;
/* make sure materials get updated in objects */
- test_object_materials( ( ID * ) tmpmesh );
+ test_object_materials(&tmpmesh->id);
return tmpmesh;
}