Skip to content
Snippets Groups Projects
Commit 9f0fd056 authored by Mike Blumenkrantz's avatar Mike Blumenkrantz :lifter: Committed by Eric Engestrom
Browse files

zink: store drm format as internal_format for imported resources

internal_format is the "real" format of a resource, and the "real" format
of imported resources is the external-facing format, not the pipe format

this ensures the correct format is available for internal ops, such as nplanes queries

Fixes: 2e2775c1 ("zink: fix PIPE_RESOURCE_PARAM_NPLANES with format modifier")
Part-of: <mesa/mesa!20753>
(cherry picked from commit 072e29a2)
parent a6292889
No related branches found
No related tags found
Loading
......@@ -2875,7 +2875,7 @@
"description": "zink: store drm format as internal_format for imported resources",
"nominated": true,
"nomination_type": 1,
"resolution": 0,
"resolution": 1,
"main_sha": null,
"because_sha": "2e2775c11b0d17472afd53b1398a3af7d9086a75"
},
......
......@@ -1541,6 +1541,7 @@ zink_resource_from_handle(struct pipe_screen *pscreen,
res->valid = true;
else
tc_buffer_disable_cpu_storage(pres);
res->internal_format = whandle->format;
}
return pres;
#else
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment