Changeset View
Changeset View
Standalone View
Standalone View
source/blender/draw/modes/overlay_mode.c
| Show First 20 Lines • Show All 476 Lines • ▼ Show 20 Lines | static void overlay_draw_scene(void *vedata) | ||||
| if (DRW_state_is_fbo()) { | if (DRW_state_is_fbo()) { | ||||
| GPU_framebuffer_bind(dfbl->default_fb); | GPU_framebuffer_bind(dfbl->default_fb); | ||||
| } | } | ||||
| DRW_draw_pass(psl->face_orientation_pass); | DRW_draw_pass(psl->face_orientation_pass); | ||||
| /* This is replaced by the next code block */ | /* This is replaced by the next code block */ | ||||
| // MULTISAMPLE_SYNC_ENABLE(dfbl, dtxl); | // MULTISAMPLE_SYNC_ENABLE(dfbl, dtxl); | ||||
| if (dfbl->multisample_fb != NULL) { | if (dfbl->multisample_fb != NULL && DRW_state_is_fbo()) { | ||||
| DRW_stats_query_start("Multisample Blit"); | DRW_stats_query_start("Multisample Blit"); | ||||
| GPU_framebuffer_bind(dfbl->multisample_fb); | GPU_framebuffer_bind(dfbl->multisample_fb); | ||||
| GPU_framebuffer_clear_color(dfbl->multisample_fb, (const float[4]){0.0f}); | GPU_framebuffer_clear_color(dfbl->multisample_fb, (const float[4]){0.0f}); | ||||
| /* Special blit: we need the original depth and stencil | /* Special blit: we need the original depth and stencil | ||||
| * in the Multisample buffer. */ | * in the Multisample buffer. */ | ||||
| GPU_framebuffer_blit( | GPU_framebuffer_blit( | ||||
| dfbl->default_fb, 0, dfbl->multisample_fb, 0, GPU_DEPTH_BIT | GPU_STENCIL_BIT); | dfbl->default_fb, 0, dfbl->multisample_fb, 0, GPU_DEPTH_BIT | GPU_STENCIL_BIT); | ||||
| DRW_stats_query_end(); | DRW_stats_query_end(); | ||||
| ▲ Show 20 Lines • Show All 47 Lines • Show Last 20 Lines | |||||