Cleanup: GPUState: Remove GPU_state_init()

This commit is contained in:
Clément Foucault 2020-08-18 21:23:15 +02:00
parent e5796233c7
commit 33fde699e2
4 changed files with 0 additions and 17 deletions

View File

@ -1755,8 +1755,6 @@ void DRW_render_to_image(RenderEngine *engine, struct Depsgraph *depsgraph)
BLI_rcti_init(&render_rect, 0, size[0], 0, size[1]);
}
/* Set the default Blender draw state */
GPU_state_init();
/* Reset state before drawing */
DRW_state_reset();
@ -2785,8 +2783,6 @@ void DRW_opengl_context_create(void)
if (!G.background) {
immActivate();
}
/* Set default Blender OpenGL state */
GPU_state_init();
/* So we activate the window's one afterwards. */
wm_window_reset_drawable();
}

View File

@ -104,12 +104,6 @@ typedef enum eGPUProvokingVertex {
extern "C" {
#endif
/* Initialize
* - sets the default Blender opengl state, if in doubt, check
* the contents of this function
* - this is called when starting Blender, for opengl rendering. */
void GPU_state_init(void);
void GPU_blend(eGPUBlend blend);
void GPU_face_culling(eGPUFaceCullTest culling);
void GPU_front_facing(bool invert);

View File

@ -345,8 +345,4 @@ GPUStateManager::GPUStateManager(void)
mutable_state.stencil_reference = 0x00;
}
void GPU_state_init(void)
{
}
/** \} */

View File

@ -658,9 +658,6 @@ static void wm_window_ghostwindow_add(wmWindowManager *wm,
wm_window_swap_buffers(win);
// GHOST_SetWindowState(ghostwin, GHOST_kWindowStateModified);
/* standard state vars for window */
GPU_state_init();
}
else {
wm_window_set_drawable(wm, prev_windrawable, false);