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:
authorTon Roosendaal <ton@blender.org>2007-03-27 00:35:56 +0400
committerTon Roosendaal <ton@blender.org>2007-03-27 00:35:56 +0400
commit469f3e87561aa73b612c87584da415a84d49d9f9 (patch)
tree02593f37eae799b7528d0c712635087fd07a567b /source/blender/src/meshtools.c
parent2b8bed8598004683bb20efad6e9bd15243ad2d24 (diff)
Bugfix #6293
Multires Meshes crashed badly when joined. Added check in join code to escape with a warning.
Diffstat (limited to 'source/blender/src/meshtools.c')
-rw-r--r--source/blender/src/meshtools.c14
1 files changed, 10 insertions, 4 deletions
diff --git a/source/blender/src/meshtools.c b/source/blender/src/meshtools.c
index ec42c93355b..e61cfd12a86 100644
--- a/source/blender/src/meshtools.c
+++ b/source/blender/src/meshtools.c
@@ -126,7 +126,7 @@ int join_mesh(void)
MFace *mface = NULL, *mfacemain;
float imat[4][4], cmat[4][4];
int a, b, totcol, totedge=0, totvert=0, totface=0, ok=0, vertofs, map[MAXMAT];
- int i, j, index, haskey=0, edgeofs, faceofs;
+ int i, j, index, haskey=0, hasmulti=0, edgeofs, faceofs;
bDeformGroup *dg, *odg;
MDeformVert *dvert;
CustomData vdata, edata, fdata;
@@ -157,7 +157,7 @@ int join_mesh(void)
}
#endif
- /* count */
+ /* count & check */
base= FIRSTBASE;
while(base) {
if TESTBASELIB(base) {
@@ -172,6 +172,10 @@ int join_mesh(void)
haskey= 1;
break;
}
+ if(me->mr) {
+ hasmulti= 1;
+ break;
+ }
}
}
base= base->next;
@@ -181,12 +185,14 @@ int join_mesh(void)
error("Can't join meshes with vertex keys");
return 0;
}
+ if(hasmulti) {
+ error("Can't join meshes with Multires");
+ return 0;
+ }
/* that way the active object is always selected */
if(ok==0) return 0;
if(totvert==0 || totvert>MESH_MAX_VERTS) return 0;
-
-
/* if needed add edges to other meshes */
for(base= FIRSTBASE; base; base= base->next) {