Fix #19426: loop select with occlude background geometry did not
authorBrecht Van Lommel <brechtvanlommel@pandora.be>
Mon, 21 Sep 2009 17:32:25 +0000 (17:32 +0000)
committerBrecht Van Lommel <brechtvanlommel@pandora.be>
Mon, 21 Sep 2009 17:32:25 +0000 (17:32 +0000)
work after subdivide operator, needed a check for valid backbuf.

source/blender/editors/mesh/editmesh_mods.c

index 09ea9088a166d85b57762306d871caff7db008b3..3135863d57130b343787fb6fcacc32e8677bdb26 100644 (file)
@@ -2033,6 +2033,9 @@ static void mouse_mesh_loop(bContext *C, short mval[2], short extend, short ring
        vc.mval[0]= mval[0];
        vc.mval[1]= mval[1];
        em= vc.em;
+
+       /* no afterqueue (yet), so we check it now, otherwise the em_xxxofs indices are bad */
+       view3d_validate_backbuf(&vc);
        
        eed= findnearestedge(&vc, &dist);
        if(eed) {
@@ -2110,6 +2113,9 @@ static void mouse_mesh_shortest_path(bContext *C, short mval[2])
        vc.mval[1]= mval[1];
        em= vc.em;
        
+       /* no afterqueue (yet), so we check it now, otherwise the em_xxxofs indices are bad */
+       view3d_validate_backbuf(&vc);
+       
        eed= findnearestedge(&vc, &dist);
        if(eed) {
                Mesh *me= vc.obedit->data;