/** * Cleanup and flush selection results to buffer. * Return number of hits and hits in buffer. * if \a dopass is true, we will do a second pass with occlusion queries to get the closest hit. */ uint GPU_select_end(void) { uint hits = 0; switch (g_select_state.algorithm) { case ALGO_GL_LEGACY: { glPopName(); hits = glRenderMode(GL_RENDER); break; } case ALGO_GL_QUERY: { hits = gpu_select_query_end(); break; } default: /* ALGO_GL_PICK */ { hits = gpu_select_pick_end(); break; } } g_select_state.select_is_active = false; return hits; }
/** * Cleanup and flush selection results to buffer. * Return number of hits and hits in buffer. * if \a dopass is true, we will do a second pass with occlusion queries to get the closest hit. */ uint GPU_select_end(void) { uint hits = 0; switch (g_select_state.algorithm) { case ALGO_GL_QUERY: { hits = gpu_select_query_end(); break; } default: /* ALGO_GL_PICK */ { hits = gpu_select_pick_end(); break; } } g_select_state.select_is_active = false; return hits; }