Merge branch 'master' into blender2.8
authorCampbell Barton <ideasman42@gmail.com>
Thu, 1 Mar 2018 05:48:13 +0000 (16:48 +1100)
committerCampbell Barton <ideasman42@gmail.com>
Thu, 1 Mar 2018 05:48:13 +0000 (16:48 +1100)
1  2 
source/blender/gpu/intern/gpu_select.c
source/blender/gpu/intern/gpu_select_pick.c

index 9aff708d32a8c2ae5981c74f90d21e5e6cd3ba08,3e65e2987e6e87ee786ef04a0c68a6194654f8be..4aef80934ade798889fada2ba83b4b7a35c762cf
@@@ -552,11 -538,11 +536,11 @@@ uint gpu_select_pick_end(void
  #endif
  
        if (ps->is_cached == false) {
-               if (ps->gl.is_finalized == false) {
-                       gpu_select_pick_finalize();
+               if (ps->gl.is_init) {
+                       /* force finishing last pass */
+                       gpu_select_pick_load_id(ps->gl.prev_id);
                }
 -              glPopAttrib();
 +              gpuPopAttrib();
                glColorMask(GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE);
        }