diff options
author | Campbell Barton <ideasman42@gmail.com> | 2015-08-01 07:42:14 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2015-08-01 07:42:14 +0300 |
commit | d894fcb79972e5475ec1b301f2be794ef53dda3d (patch) | |
tree | 11fc51ee6e7738b1d76efe18d7eb3f6b6f4c3a67 /source/blender | |
parent | c851d1d04552e02a64b81216099ee01991f168d7 (diff) |
Replace checks for tessface w/ polygons
In these cases we're only checking the mesh has faces.
Diffstat (limited to 'source/blender')
-rw-r--r-- | source/blender/editors/space_view3d/drawobject.c | 4 | ||||
-rw-r--r-- | source/blender/modifiers/intern/MOD_surface.c | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/editors/space_view3d/drawobject.c b/source/blender/editors/space_view3d/drawobject.c index f03b008762f..82acc5863c4 100644 --- a/source/blender/editors/space_view3d/drawobject.c +++ b/source/blender/editors/space_view3d/drawobject.c @@ -4621,7 +4621,7 @@ static bool drawCurveDerivedMesh(Scene *scene, View3D *v3d, RegionView3D *rv3d, glFrontFace((ob->transflag & OB_NEG_SCALE) ? GL_CW : GL_CCW); - if (dt > OB_WIRE && dm->getNumTessFaces(dm)) { + if (dt > OB_WIRE && dm->getNumPolys(dm)) { int glsl = draw_glsl_material(scene, ob, v3d, dt); GPU_begin_object_materials(v3d, rv3d, scene, ob, glsl, NULL); @@ -7322,7 +7322,7 @@ static void drawObjectSelect(Scene *scene, View3D *v3d, ARegion *ar, Base *base, } if (dm) { - has_faces = dm->getNumTessFaces(dm) > 0; + has_faces = (dm->getNumPolys(dm) != 0); } else { has_faces = BKE_displist_has_faces(&ob->curve_cache->disp); diff --git a/source/blender/modifiers/intern/MOD_surface.c b/source/blender/modifiers/intern/MOD_surface.c index abb652c3ea5..ff5e5f643a7 100644 --- a/source/blender/modifiers/intern/MOD_surface.c +++ b/source/blender/modifiers/intern/MOD_surface.c @@ -158,7 +158,7 @@ static void deformVerts(ModifierData *md, Object *ob, else surmd->bvhtree = MEM_callocN(sizeof(BVHTreeFromMesh), "BVHTreeFromMesh"); - if (surmd->dm->getNumTessFaces(surmd->dm)) + if (surmd->dm->getNumPolys(surmd->dm)) bvhtree_from_mesh_looptri(surmd->bvhtree, surmd->dm, 0.0, 2, 6); else bvhtree_from_mesh_edges(surmd->bvhtree, surmd->dm, 0.0, 2, 6); |