diff options
author | Peter Kim <pk15950@gmail.com> | 2022-02-11 14:51:27 +0300 |
---|---|---|
committer | Peter Kim <pk15950@gmail.com> | 2022-02-11 14:51:27 +0300 |
commit | 2d231f837a48933c0e819cdc6e78d977152bdd69 (patch) | |
tree | 9d0b9c0bd9fe2d2724af866ace830d74d13090cf /source/blender/draw | |
parent | fd98241cb80c63ed0b3515cb4976ad786d7540c8 (diff) | |
parent | 675f38aca7073234a2ce0b36597d95f8a153ef7c (diff) |
Merge branch 'blender-v3.1-release'
Diffstat (limited to 'source/blender/draw')
-rw-r--r-- | source/blender/draw/intern/draw_manager.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/source/blender/draw/intern/draw_manager.c b/source/blender/draw/intern/draw_manager.c index b4b92acbb56..440f74af64b 100644 --- a/source/blender/draw/intern/draw_manager.c +++ b/source/blender/draw/intern/draw_manager.c @@ -1750,6 +1750,8 @@ void DRW_draw_render_loop_offscreen(struct Depsgraph *depsgraph, GPUOffScreen *ofs, GPUViewport *viewport) { + const bool is_xr_surface = ((v3d->flag & V3D_XR_SESSION_SURFACE) != 0); + /* Create temporary viewport if needed or update the existing viewport. */ GPUViewport *render_viewport = viewport; if (viewport == NULL) { @@ -1759,7 +1761,7 @@ void DRW_draw_render_loop_offscreen(struct Depsgraph *depsgraph, drw_notify_view_update_offscreen(depsgraph, engine_type, region, v3d, render_viewport); } - GPU_viewport_bind_from_offscreen(render_viewport, ofs); + GPU_viewport_bind_from_offscreen(render_viewport, ofs, is_xr_surface); /* Just here to avoid an assert but shouldn't be required in practice. */ GPU_framebuffer_restore(); |