mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2025-09-12 18:50:22 -07:00
vkd3d: Get rid of the default fragment shader from d3d12_pipeline_state_init_graphics().
Vulkan does support rendering without a fragment shader, and this seems to work fine on current drivers. This commit gets rid of the last embedded shader binary in libvkd3d, and may have a slight performance advantage on hardware/drivers able to take advantage of the absence of a fragment shader.
This commit is contained in:
Notes:
Henri Verbeet
2025-07-16 18:16:36 +02:00
Approved-by: Henri Verbeet (@hverbeet) Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/1617
@@ -3232,17 +3232,6 @@ static HRESULT d3d12_pipeline_state_init_graphics(struct d3d12_pipeline_state *s
|
|||||||
uint32_t mask;
|
uint32_t mask;
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
|
|
||||||
static const DWORD default_ps_code[] =
|
|
||||||
{
|
|
||||||
#if 0
|
|
||||||
ps_4_0
|
|
||||||
ret
|
|
||||||
#endif
|
|
||||||
0x43425844, 0x19cbf606, 0x18f562b9, 0xdaeed4db, 0xc324aa46, 0x00000001, 0x00000060, 0x00000003,
|
|
||||||
0x0000002c, 0x0000003c, 0x0000004c, 0x4e475349, 0x00000008, 0x00000000, 0x00000008, 0x4e47534f,
|
|
||||||
0x00000008, 0x00000000, 0x00000008, 0x52444853, 0x0000000c, 0x00000040, 0x00000003, 0x0100003e,
|
|
||||||
};
|
|
||||||
static const D3D12_SHADER_BYTECODE default_ps = {default_ps_code, sizeof(default_ps_code)};
|
|
||||||
static const struct
|
static const struct
|
||||||
{
|
{
|
||||||
enum VkShaderStageFlagBits stage;
|
enum VkShaderStageFlagBits stage;
|
||||||
@@ -3405,12 +3394,6 @@ static HRESULT d3d12_pipeline_state_init_graphics(struct d3d12_pipeline_state *s
|
|||||||
{
|
{
|
||||||
graphics->blend_attachments[i].colorWriteMask = 0;
|
graphics->blend_attachments[i].colorWriteMask = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (FAILED(hr = create_shader_stage(device, &graphics->stages[graphics->stage_count],
|
|
||||||
VK_SHADER_STAGE_FRAGMENT_BIT, &default_ps, NULL)))
|
|
||||||
goto fail;
|
|
||||||
|
|
||||||
++graphics->stage_count;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user