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
path: root/source
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2013-05-08 16:53:52 +0400
committerCampbell Barton <ideasman42@gmail.com>2013-05-08 16:53:52 +0400
commit6b1b20ef0d17156c82a68d39142c41a24c1c5d47 (patch)
treedf8b794e052eeea3d6f40eef42c423c21b4b0c70 /source
parent67ec36a615655917a6c97deaaacdddc9fe43de19 (diff)
code cleanup: BKE_mesh_nurbs_displist_to_mdata(), use const bool for
'conv_polys'
Diffstat (limited to 'source')
-rw-r--r--source/blender/blenkernel/intern/mesh.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/source/blender/blenkernel/intern/mesh.c b/source/blender/blenkernel/intern/mesh.c
index 3c4900e8a6a..96417cdf44c 100644
--- a/source/blender/blenkernel/intern/mesh.c
+++ b/source/blender/blenkernel/intern/mesh.c
@@ -1301,8 +1301,8 @@ int BKE_mesh_nurbs_displist_to_mdata(Object *ob, ListBase *dispbase,
MLoopUV **alluv,
int *_totloop, int *_totpoly)
{
+ Curve *cu = ob->data;
DispList *dl;
- Curve *cu;
MVert *mvert;
MPoly *mpoly;
MLoop *mloop;
@@ -1311,13 +1311,8 @@ int BKE_mesh_nurbs_displist_to_mdata(Object *ob, ListBase *dispbase,
float *data;
int a, b, ofs, vertcount, startvert, totvert = 0, totedge = 0, totloop = 0, totvlak = 0;
int p1, p2, p3, p4, *index;
- int conv_polys = 0;
-
- cu = ob->data;
-
-
- conv_polys |= cu->flag & CU_3D; /* 2d polys are filled with DL_INDEX3 displists */
- conv_polys |= ob->type == OB_SURF; /* surf polys are never filled */
+ const bool conv_polys = ((cu->flag & CU_3D) || /* 2d polys are filled with DL_INDEX3 displists */
+ (ob->type == OB_SURF)); /* surf polys are never filled */
/* count */
dl = dispbase->first;