diff options
author | Erik Faye-Lund <[email protected]> | 2020-05-05 21:59:22 +0200 |
---|---|---|
committer | Marge Bot <[email protected]> | 2020-05-07 22:38:03 +0000 |
commit | 947bb04fcc03c9c1b8a04a6b3cd7f86825e6f244 (patch) | |
tree | b69b88e3a16fc54c440466ae2d87abe704a5e1da /src/gallium/state_trackers/wgl | |
parent | 808eb20186a23be1a1917668e374243151e6699e (diff) |
st/wgl: pass st_context_iface into stw_st_framebuffer_present_locked
We're going to need this to be able to resolve MSAA buffers.
Acked-by: Dave Airlie <[email protected]>
Reviewed-by: Roland Scheidegger <[email protected]>
Reviewed-by: Jose Fonseca <[email protected]>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4926>
Diffstat (limited to 'src/gallium/state_trackers/wgl')
-rw-r--r-- | src/gallium/state_trackers/wgl/stw_framebuffer.c | 2 | ||||
-rw-r--r-- | src/gallium/state_trackers/wgl/stw_st.c | 8 | ||||
-rw-r--r-- | src/gallium/state_trackers/wgl/stw_st.h | 3 |
3 files changed, 8 insertions, 5 deletions
diff --git a/src/gallium/state_trackers/wgl/stw_framebuffer.c b/src/gallium/state_trackers/wgl/stw_framebuffer.c index 15d46dbb61e..4078d95287b 100644 --- a/src/gallium/state_trackers/wgl/stw_framebuffer.c +++ b/src/gallium/state_trackers/wgl/stw_framebuffer.c @@ -656,7 +656,7 @@ DrvSwapBuffers(HDC hdc) wait_swap_interval(fb); } - return stw_st_swap_framebuffer_locked(hdc, fb->stfb); + return stw_st_swap_framebuffer_locked(hdc, ctx->st, fb->stfb); } diff --git a/src/gallium/state_trackers/wgl/stw_st.c b/src/gallium/state_trackers/wgl/stw_st.c index 2f686a1d6ad..63f582a28b1 100644 --- a/src/gallium/state_trackers/wgl/stw_st.c +++ b/src/gallium/state_trackers/wgl/stw_st.c @@ -175,6 +175,7 @@ stw_st_framebuffer_validate(struct st_context_iface *stctx, */ static bool stw_st_framebuffer_present_locked(HDC hdc, + struct st_context_iface *stctx, struct st_framebuffer_iface *stfb, enum st_attachment_type statt) { @@ -212,7 +213,7 @@ stw_st_framebuffer_flush_front(struct st_context_iface *stctx, hDC = GetDC(stwfb->fb->hWnd); - ret = stw_st_framebuffer_present_locked(hDC, &stwfb->base, statt); + ret = stw_st_framebuffer_present_locked(hDC, stctx, &stwfb->base, statt); ReleaseDC(stwfb->fb->hWnd, hDC); @@ -268,7 +269,8 @@ stw_st_destroy_framebuffer_locked(struct st_framebuffer_iface *stfb) * Swap the buffers of the given framebuffer. */ bool -stw_st_swap_framebuffer_locked(HDC hdc, struct st_framebuffer_iface *stfb) +stw_st_swap_framebuffer_locked(HDC hdc, struct st_context_iface *stctx, + struct st_framebuffer_iface *stfb) { struct stw_st_framebuffer *stwfb = stw_st_framebuffer(stfb); unsigned front = ST_ATTACHMENT_FRONT_LEFT, back = ST_ATTACHMENT_BACK_LEFT; @@ -293,7 +295,7 @@ stw_st_swap_framebuffer_locked(HDC hdc, struct st_framebuffer_iface *stfb) stwfb->texture_mask = mask; front = ST_ATTACHMENT_FRONT_LEFT; - return stw_st_framebuffer_present_locked(hdc, &stwfb->base, front); + return stw_st_framebuffer_present_locked(hdc, stctx, &stwfb->base, front); } diff --git a/src/gallium/state_trackers/wgl/stw_st.h b/src/gallium/state_trackers/wgl/stw_st.h index 6bc218285a7..20d491fa609 100644 --- a/src/gallium/state_trackers/wgl/stw_st.h +++ b/src/gallium/state_trackers/wgl/stw_st.h @@ -47,7 +47,8 @@ void stw_st_destroy_framebuffer_locked(struct st_framebuffer_iface *stfb); bool -stw_st_swap_framebuffer_locked(HDC hdc, struct st_framebuffer_iface *stfb); +stw_st_swap_framebuffer_locked(HDC hdc, struct st_context_iface *stctx, + struct st_framebuffer_iface *stfb); struct pipe_resource * stw_get_framebuffer_resource(struct st_framebuffer_iface *stfb, |