Module: Mesa Branch: staging/21.0 Commit: 156edb5fea0d857f373979d43491e2628ed73823 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=156edb5fea0d857f373979d43491e2628ed73823
Author: Erik Faye-Lund <erik.faye-l...@collabora.com> Date: Fri Jan 22 09:09:03 2021 +0100 zink: respect feature-cap for independent blending Vulkan has a cap to enable this, we should check that one rather than always claiming support. Fixes: 8d46e35d16e ("zink: introduce opengl over vulkan") Reviewed-by: Hoe Hao Cheng <haochengho12...@gmail.com> Reviewed-By: Mike Blumenkrantz <michael.blumenkra...@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8640> (cherry picked from commit 612169859a3300879fa890a03a8693ab3c718d2c) --- .pick_status.json | 2 +- src/gallium/drivers/zink/zink_screen.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.pick_status.json b/.pick_status.json index 77a95f9483f..ece27f42cad 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -67,7 +67,7 @@ "description": "zink: respect feature-cap for independent blending", "nominated": true, "nomination_type": 1, - "resolution": 0, + "resolution": 1, "master_sha": null, "because_sha": "8d46e35d16e3936968958bcab86d61967a673305" }, diff --git a/src/gallium/drivers/zink/zink_screen.c b/src/gallium/drivers/zink/zink_screen.c index 3db568c182f..342f3bd0f35 100644 --- a/src/gallium/drivers/zink/zink_screen.c +++ b/src/gallium/drivers/zink/zink_screen.c @@ -157,15 +157,15 @@ zink_get_param(struct pipe_screen *pscreen, enum pipe_cap param) case PIPE_CAP_MAX_TEXTURE_CUBE_LEVELS: return 1 + util_logbase2(screen->info.props.limits.maxImageDimensionCube); - case PIPE_CAP_BLEND_EQUATION_SEPARATE: case PIPE_CAP_FRAGMENT_SHADER_TEXTURE_LOD: case PIPE_CAP_FRAGMENT_SHADER_DERIVATIVES: case PIPE_CAP_VERTEX_SHADER_SATURATE: return 1; + case PIPE_CAP_BLEND_EQUATION_SEPARATE: case PIPE_CAP_INDEP_BLEND_ENABLE: case PIPE_CAP_INDEP_BLEND_FUNC: - return 1; + return screen->info.feats.features.independentBlend; case PIPE_CAP_MAX_STREAM_OUTPUT_BUFFERS: return screen->info.have_EXT_transform_feedback ? screen->info.tf_props.maxTransformFeedbackBuffers : 0; _______________________________________________ mesa-commit mailing list mesa-commit@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-commit