Fix T71379: Even edge slide shows random points on screen

This commit is contained in:
Campbell Barton 2019-11-09 09:58:06 +11:00
parent 8c695404a4
commit 0a0d735acd
Notes: blender-bot 2023-02-14 06:05:22 +01:00
Referenced by issue #71496, Voronoi Texture difference
Referenced by issue #71440, Automatic bug form is reporting the wrong hash
Referenced by issue #71379, Offset Edge Slide with Even option: random points on screen
1 changed files with 19 additions and 12 deletions

View File

@ -7576,20 +7576,27 @@ static void drawEdgeSlide(TransInfo *t)
}
immEnd();
immUniformThemeColorShadeAlpha(TH_SELECT, -30, alpha_shade);
GPU_point_size(ctrl_size);
immBegin(GPU_PRIM_POINTS, 1);
if (slp->flipped) {
if (curr_sv->v_side[1]) {
immVertex3fv(pos, curr_sv->v_side[1]->co);
{
float *co_test = NULL;
if (slp->flipped) {
if (curr_sv->v_side[1]) {
co_test = curr_sv->v_side[1]->co;
}
}
else {
if (curr_sv->v_side[0]) {
co_test = curr_sv->v_side[0]->co;
}
}
if (co_test != NULL) {
immUniformThemeColorShadeAlpha(TH_SELECT, -30, alpha_shade);
GPU_point_size(ctrl_size);
immBegin(GPU_PRIM_POINTS, 1);
immVertex3fv(pos, co_test);
immEnd();
}
}
else {
if (curr_sv->v_side[0]) {
immVertex3fv(pos, curr_sv->v_side[0]->co);
}
}
immEnd();
immUniformThemeColorShadeAlpha(TH_SELECT, 255, alpha_shade);
GPU_point_size(guide_size);