forked from bartvdbraak/blender
Bug report (IRC)
Knife cut with long mouse trails failed, increased max amount of input points 4 fold (1024).
This commit is contained in:
parent
ca2c319649
commit
5918521959
@ -608,9 +608,12 @@ static float seg_intersect(EditEdge *e, CutCurve *c, int len, char mode, struct
|
||||
return(perc);
|
||||
}
|
||||
|
||||
|
||||
/* for multicut */
|
||||
#define MAX_CUTS 256
|
||||
|
||||
/* for amount of edges */
|
||||
#define MAX_CUT_EDGES 1024
|
||||
|
||||
static int knife_cut_exec(bContext *C, wmOperator *op)
|
||||
{
|
||||
Object *obedit= CTX_data_edit_object(C);
|
||||
@ -618,7 +621,7 @@ static int knife_cut_exec(bContext *C, wmOperator *op)
|
||||
ARegion *ar= CTX_wm_region(C);
|
||||
EditEdge *eed;
|
||||
EditVert *eve;
|
||||
CutCurve curve[MAX_CUTS];
|
||||
CutCurve curve[MAX_CUT_EDGES];
|
||||
struct GHash *gh;
|
||||
float isect=0.0;
|
||||
float *scr, co[4];
|
||||
@ -642,7 +645,7 @@ static int knife_cut_exec(bContext *C, wmOperator *op)
|
||||
|
||||
RNA_float_get_array(&itemptr, "loc", (float *)&curve[len]);
|
||||
len++;
|
||||
if(len>= MAX_CUTS) break;
|
||||
if(len>= MAX_CUT_EDGES) break;
|
||||
}
|
||||
RNA_END;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user