DRW: Fix State tracking being off when calling GPU_framebuffer_clear
State tracking works in pretty much all cases but calling the clear command does change the write mask outside the draw manager. For now we just reset the write mask before each pass. Fix T62203 The selected bone is not highlighted inside the other bone.
This commit is contained in:
parent
18e5540a48
commit
af72fc7555
Notes:
blender-bot
2023-02-14 03:29:37 +01:00
Referenced by issue #62203, The selected bone is not highlighted inside the other bone.
|
@ -1315,6 +1315,10 @@ static void drw_draw_pass_ex(DRWPass *pass, DRWShadingGroup *start_group, DRWSha
|
|||
|
||||
drw_update_view();
|
||||
|
||||
/* GPU_framebuffer_clear calls can change the state outside the DRW module.
|
||||
* Force reset the affected states to avoid problems later. */
|
||||
drw_state_set(DST.state | DRW_STATE_WRITE_DEPTH | DRW_STATE_WRITE_COLOR);
|
||||
|
||||
drw_state_set(pass->state);
|
||||
|
||||
DRW_stats_query_start(pass->name);
|
||||
|
|
Loading…
Reference in New Issue