mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-08 13:28:06 +02:00
iris: Fall back to 1x1x1 null surface if no framebuffer supplied
If the state tracker never gave us the framebuffer dimensions via a set_framebuffer_state() call, just fall back to the unbound texture null surface, which is 1x1x1. Otherwise we'd use a NULL resource (no pun intended).
This commit is contained in:
parent
5d1a9db720
commit
927c4a21bd
1 changed files with 4 additions and 0 deletions
|
|
@ -3354,6 +3354,10 @@ use_null_surface(struct iris_batch *batch, struct iris_context *ice)
|
|||
static uint32_t
|
||||
use_null_fb_surface(struct iris_batch *batch, struct iris_context *ice)
|
||||
{
|
||||
/* If set_framebuffer_state() was never called, fall back to 1x1x1 */
|
||||
if (!ice->state.null_fb.res)
|
||||
return use_null_surface(batch, ice);
|
||||
|
||||
struct iris_bo *state_bo = iris_resource_bo(ice->state.null_fb.res);
|
||||
|
||||
iris_use_pinned_bo(batch, state_bo, false);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue