Fix select engine buffer having wrong vertex size

The theme used was wrong and the vertex size is twice as set in the theme.
This commit is contained in:
Germano Cavalcante 2021-08-03 13:32:18 -03:00
parent 57281b73c4
commit 39e914cee7
2 changed files with 2 additions and 1 deletions

View File

@ -193,7 +193,7 @@ static void select_cache_init(void *vedata)
if (e_data.context.select_mode & SCE_SELECT_VERTEX) {
DRW_PASS_CREATE(psl->select_id_vert_pass, state);
pd->shgrp_vert = DRW_shgroup_create(sh->select_id_flat, psl->select_id_vert_pass);
DRW_shgroup_uniform_float_copy(pd->shgrp_vert, "sizeVertex", G_draw.block.sizeVertex);
DRW_shgroup_uniform_float_copy(pd->shgrp_vert, "sizeVertex", 2 * G_draw.block.sizeVertex);
}
}

View File

@ -2682,6 +2682,7 @@ void DRW_draw_select_id(Depsgraph *depsgraph, ARegion *region, View3D *v3d, cons
drw_viewport_var_init();
/* Update UBO's */
UI_SetTheme(SPACE_VIEW3D, RGN_TYPE_WINDOW);
DRW_globals_update();
/* Init Select Engine */