diff options
author | Clément Foucault <foucault.clem@gmail.com> | 2019-08-26 19:43:46 +0300 |
---|---|---|
committer | Clément Foucault <foucault.clem@gmail.com> | 2019-08-26 19:43:53 +0300 |
commit | 7273dbd47b7ab7ae0016f17f95e71221fb8773d2 (patch) | |
tree | 7d4d86275c8bbb6161bacc40a6355e3ada659d61 /source/blender/draw/intern/draw_cache_impl_mesh.c | |
parent | 1a6491639a8b14ec59aa8b54e9d46d7b0cb7f5ff (diff) |
Fix T69051 Vertex Paint: Selection not show in vertex select mode.
Diffstat (limited to 'source/blender/draw/intern/draw_cache_impl_mesh.c')
-rw-r--r-- | source/blender/draw/intern/draw_cache_impl_mesh.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/draw/intern/draw_cache_impl_mesh.c b/source/blender/draw/intern/draw_cache_impl_mesh.c index 884d39343c6..456e21db6ed 100644 --- a/source/blender/draw/intern/draw_cache_impl_mesh.c +++ b/source/blender/draw/intern/draw_cache_impl_mesh.c @@ -549,6 +549,7 @@ void DRW_mesh_batch_cache_dirty_tag(Mesh *me, int mode) { GPU_INDEXBUF_DISCARD_SAFE(mbufcache->ibo.lines_paint_mask); GPU_VERTBUF_DISCARD_SAFE(mbufcache->vbo.pos_nor); + GPU_VERTBUF_DISCARD_SAFE(mbufcache->vbo.lnor); } GPU_BATCH_DISCARD_SAFE(cache->batch.surface); GPU_BATCH_DISCARD_SAFE(cache->batch.wire_loops); @@ -1140,6 +1141,8 @@ void DRW_mesh_batch_cache_create_requested( } if (DRW_batch_requested(cache->batch.wire_loops, GPU_PRIM_LINES)) { DRW_ibo_request(cache->batch.wire_loops, &mbufcache->ibo.lines_paint_mask); + /* Order matters. First ones override latest vbos' attribs. */ + DRW_vbo_request(cache->batch.wire_loops, &mbufcache->vbo.lnor); DRW_vbo_request(cache->batch.wire_loops, &mbufcache->vbo.pos_nor); } if (DRW_batch_requested(cache->batch.wire_edges, GPU_PRIM_LINES)) { |