Commit Graph

481 Commits

Author SHA1 Message Date
Józef Kucia b62aa91758 wined3d: Pass fully initialized shader objects to CS.
It shouldn't matter right now, but it might be an issue when we start to
precompile other shader types than compute shaders.

Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-03-26 21:04:11 +02:00
Henri Verbeet 9cdc8876b0 wined3d: Use upper-case enum elements in the vertexprocessing_mode enum.
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-03-23 14:02:41 +01:00
Henri Verbeet f08342f573 wined3d: Use the global memory allocation helpers.
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-02-14 09:06:58 +01:00
Józef Kucia 87f823ad91 wined3d: Simplify shader_calculate_clip_or_cull_distance_mask().
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-02-08 21:07:12 +01:00
Józef Kucia f2e614b1f8 wined3d: Implement ld2dms instruction.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2018-02-05 16:24:50 +01:00
Józef Kucia 4a55ddce47 wined3d: Recognize SM5 eval_sample_index instruction.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-12-11 18:21:15 +01:00
Józef Kucia 72ecfb0ae4 wined3d: Fix relative addressing for SM4+ vertex shader inputs.
Relative addressing doesn't necessarily work for SM3.

Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-12-07 19:14:11 +01:00
Józef Kucia 429e0c9130 wined3d: Implement SV_CullDistance.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-12-05 20:30:06 +01:00
Józef Kucia 431aa3274c wined3d: Implement SV_ClipDistance.
In D3D10+ all clip distances declared in a shader are always enabled.
In other words, enablement of clip distances is a property of a shader.

Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-12-05 20:30:05 +01:00
Józef Kucia f3e612bf16 wined3d: Fix SM4 discard_z instruction.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-12-01 15:56:54 +01:00
Józef Kucia a063ca2e5b wined3d: Get rid of hull_shader_init().
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-11-06 19:38:18 +01:00
Józef Kucia 86933f9d31 wined3d: Get rid of domain_shader_init().
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-11-06 19:38:14 +01:00
Józef Kucia a1e158971c wined3d: Get rid of compute_shader_init().
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-11-06 19:38:12 +01:00
Józef Kucia 708c337f28 wined3d: Use wined3d_insert_bits().
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-11-06 19:37:27 +01:00
Józef Kucia c11251c188 wined3d: Get rid of unneeded includes.
math.h is included in wined3d_private.h

Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-10-19 16:53:49 +02:00
Józef Kucia 9cb69d91b2 wined3d: Pack interpolation modes.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-10-18 15:38:18 +02:00
Józef Kucia 5189a4f135 wined3d: Implement SM4+ interpolation modifiers for GLSL < 4.40.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-10-18 15:38:16 +02:00
Józef Kucia 46b3a03a97 wined3d: Implement interpolation mode when GLSL 4.40 is available.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-10-18 15:38:13 +02:00
Michael Müller 76783293cf wined3d: Add conservative depth output information to GLSL pixel shaders.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-09-11 18:43:16 +02:00
Michael Müller c95e0ef092 wined3d: Recognize conservative depth output registers.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-09-11 18:43:12 +02:00
Henri Verbeet cc16e0d2de wined3d: Validate vertex shader input signature register indices (AFL).
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-25 16:10:17 +02:00
Józef Kucia a6d26527c6 wined3d: Implement forceEarlyDepthStencil shader global flag.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-07-24 18:58:30 +02:00
Józef Kucia 4597ef6696 wined3d: Avoid barrier() in tessellation control shader if possible.
Synchronization is only needed when output variables are read.

Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-25 20:47:46 +02:00
Sven Hesse 4b376ba7d2 wined3d: Implement SM5 gather4_po_c opcode.
A combination of gather4_c and gather4_po.

Signed-off-by: Sven Hesse <drmccoy@drmccoy.de>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-23 16:28:58 +02:00
Józef Kucia 38d5b29ae1 wined3d: Add support for output registers relative addressing.
Required for tessellation shaders.

Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-22 13:45:10 +02:00
Józef Kucia 1ac5db4fc0 wined3d: Implement temporary registers per phase.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-22 13:45:10 +02:00
Józef Kucia 5666bb8ffa wined3d: Fix wined3d_sysval_semantic values for tessellation factors.
Apparently, dcl_input_* instructions do not use the same values as
sysval semantics in shader signatures.

Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-22 13:45:10 +02:00
Józef Kucia ec46c5beab wined3d: Implement instancing for join phases.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-22 13:45:10 +02:00
Józef Kucia 90c6071d7d wined3d: Implement instancing for fork phases.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-22 13:45:10 +02:00
Józef Kucia 007eb7d869 wined3d: Generate code for hull shaders.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-22 13:45:09 +02:00
Józef Kucia 2b85e49e1b wined3d: Recognize hull shader phases.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-19 14:01:30 +02:00
Józef Kucia 2b6a82d101 wined3d: Fix tracing of continuec instruction.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-19 14:01:19 +02:00
Józef Kucia b0d2cf8e3f wined3d: Handle dcl_output_control_point_count instruction.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-17 16:08:56 +02:00
Józef Kucia ab27a5902d wined3d: Fill whole structure in find_ds_compile_args().
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-17 16:08:54 +02:00
Józef Kucia b45a0d4f15 wined3d: Generate code for domain shaders.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-16 18:58:57 +02:00
Józef Kucia 7b01569e44 wined3d: Recognize SM5+ patch input primitive types.
In D3D11 geometry shaders accept patches as input primitives. This is
forbidden in OpenGL as specified in the ARB_tessellation_shaders spec:
  "we will not allow geometry shaders to receive patches in this
  extension. That limitation may be relaxed in a future extension."

Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-15 20:49:22 +02:00
Sven Hesse a86fee5e20 wined3d: Implement SM4 continuec opcode.
Works just like breakc and retc.

Signed-off-by: Sven Hesse <drmccoy@drmccoy.de>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-15 11:34:58 +02:00
Józef Kucia 487d2e0279 wined3d: Add support for patch constant signatures.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-05-12 16:11:13 +02:00
Józef Kucia 1491151a37 wined3d: Recognize SM5 dcl_gsinstances opcode.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-04-21 13:43:11 +02:00
Józef Kucia 86f9eab8e2 wined3d: Recognize SM5 vGSInstanceID register.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-04-21 13:43:08 +02:00
Sebastian Lackner 9b00f0182b wined3d: Fix double free in geometry_shader_init.
Signed-off-by: Sebastian Lackner <sebastian@fds-team.de>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-04-20 18:58:43 +02:00
Józef Kucia 2fc56cac4c wined3d: Add shader_precompile() to shader_backend_ops.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-04-13 13:05:21 +02:00
Henri Verbeet 6302d5edf8 wined3d: Avoid modifying the device's shader list outside the command stream.
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-04-12 09:46:23 +02:00
Józef Kucia 849b16b820 wined3d: Implement SM4 retc instruction.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-04-11 19:45:23 +02:00
Józef Kucia 14dd2026f6 wined3d: Implement SM5 gather4_po instruction.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-04-11 19:45:21 +02:00
Józef Kucia 6fec723c9d wined3d: Implement SM5 gather4_c instruction.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-04-11 19:45:17 +02:00
Józef Kucia 2fad01e59d wined3d: Implement SM4.1 gather4 instruction.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-04-11 19:45:15 +02:00
Józef Kucia 18e5bbe6f0 wined3d: Store stream index in shader signature elements.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-04-06 12:43:03 +02:00
Józef Kucia 132b3d4dce wined3d: Recognize SM5 ibfe opcode.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-04-04 14:54:56 +02:00
Józef Kucia 16ab203342 wined3d: Specify geometry shader outputs to record in stream output buffers.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2017-03-28 22:11:33 +02:00