Commit Graph

744 Commits

Author SHA1 Message Date
Józef Kucia 1f680c52fe wined3d: Implement vertex blending in glsl_vertex_pipe. 2015-07-03 16:51:34 +09:00
Józef Kucia 1fc4a17175 wined3d: Show fixme about unimplemented vertex processing once. 2015-07-03 16:51:29 +09:00
Matteo Bruni 498e55a182 wined3d: Make use of the EXT_BLEND_SUBTRACT flag.
MSDN mentions a fallback to D3DBLENDOP_ADD if the selected blendop
is not supported. In theory it would be nice to write a test for that but
I don't think this is particularly important and moreover hardware
without that cap seems hard to come by (i.e. I have none)...
2015-06-17 20:01:20 +09:00
Matteo Bruni 35a2406900 wined3d: Drop WINED3D_RS_TEXTUREPERSPECTIVE handling.
The hint is not supported on core profiles. It's not guaranteed to do
anything on compatibility profile either: "The interpretation of hints is
implementation dependent. An implementation may ignore them entirely."

This state was only available on D3D 7 and below (and not guaranteed to
do anything there either, according to older DX SDK docs).
If necessary we could implement it via the GLSL 1.50 "noperspective"
interpolation qualifier, which is what we need to use for the equivalent
D3D10 feature anyway.
2015-06-17 20:01:20 +09:00
Matteo Bruni 4189d29776 wined3d: Avoid the builtin GLSL vertex attributes. 2015-06-12 21:23:12 +09:00
Matteo Bruni b02a166cc8 wined3d: Introduce a get_fog_start_end() function. 2015-06-05 16:53:16 +09:00
Matteo Bruni 92fbe333d0 wined3d: Handle point sprites with PS 3.0. 2015-06-05 16:52:29 +09:00
Matteo Bruni e8cb3bdba5 wined3d: Always enable GL_PROGRAM_POINT_SIZE in the GLSL backend.
Core contexts don't support clamping the point size to GL_POINT_SIZE_MIN
/ GL_POINT_SIZE_MAX.  Incidentally this mostly fixes per-vertex point
sizes for vertex shader version 1 and 2.
2015-06-03 19:52:14 +09:00
Matteo Bruni 953a45303c wined3d: Introduce a get_pointsize() function. 2015-05-29 16:44:18 +09:00
Matteo Bruni 36520c3e9d wined3d: Introduce a get_pointsize_minmax() function. 2015-05-29 16:44:13 +09:00
Matteo Bruni b551da8eef wined3d: Remove point size scaling hack.
Not sure how this was supposed to work, according to the GL spec the
clamping to POINT_SIZE_RANGE happens after the scaling is applied.
2015-05-29 16:44:05 +09:00
Matteo Bruni 28343db208 wined3d: Don't use the builtin FFP uniforms for the lights.
While at it, use D3D-like uniforms for the light parameters and
(consequently) implement range and proper D3D spotlights support.
2015-04-28 20:02:23 +09:00
Matteo Bruni e226e7593a wined3d: Use struct wined3d_vec4 to store the light position and direction. 2015-04-28 20:02:21 +09:00
Matteo Bruni 540130bfa9 wined3d: Store the directional light direction in the lightDirn field.
It's only an implementation detail that the direction needs to be passed
to the fixed function GL pipeline as GL_POSITION.
2015-04-28 20:02:18 +09:00
Matteo Bruni 6984ca7f46 wined3d: Don't use the builtin FFP uniforms for texture transformation matrices. 2015-04-27 15:07:06 +09:00
Stefan Dösinger 4fbaab2020 wined3d: Shadow format flags in wined3d_rendertarget_view. 2015-04-23 20:43:20 +09:00
Stefan Dösinger 9076612e2d wined3d: Shadow format flags in the resource. 2015-04-22 23:24:41 +09:00
Henri Verbeet a37099e132 wined3d: Bind sampler objects to the correct texture stage.
On current hardware this generally only makes a difference for vertex
textures. This fixes a regression introduced by commit
c6232e1d11.
2015-04-15 22:21:58 +09:00
Stefan Dösinger 382fa588a9 wined3d: Handle color key dirtification in wined3d_cs_exec_set_texture. 2015-04-15 22:21:57 +09:00
Stefan Dösinger c5c7137212 wined3d: Simplify alpha test and color keying in GLSL. 2015-04-10 21:44:13 +09:00
Stefan Dösinger 5c7707dc77 wined3d: Move alpha test states to the fragment pipeline.
This will allow some color keying cleanups. For Core Contexts we'll have
to emulate alpha testing in shaders anyway.
2015-04-10 21:44:01 +09:00
Stefan Dösinger 5d51c97d07 wined3d: Implement color keying in the glsl fragment pipeline. 2015-04-10 21:43:31 +09:00
Stefan Dösinger 82db5954c4 wined3d: Set color keys through the command stream. 2015-04-10 21:42:41 +09:00
Matteo Bruni 05757794a0 wined3d: Don't use the builtin FFP uniform for the projection matrix. 2015-03-27 20:40:38 +09:00
Stefan Dösinger 239e8cad7c wined3d: Add per-context private data for fragment pipelines. 2015-03-24 20:06:15 +09:00
Henri Verbeet 1b08196c5a wined3d: Implement d3d10 style instance data step rates. 2015-03-24 17:41:06 +09:00
Matteo Bruni 74cda79ac3 wined3d: Introduce a get_texture_matrix() function. 2015-03-23 22:59:20 +09:00
Matteo Bruni 2d270f31c6 wined3d: Introduce a get_projection_matrix() function.
Notice that I'm using floats instead of doubles in the new function,
mostly to be able to use struct wined3d_matrix and multiply_matrix().
At a rough estimate the precision should still be good enough.
2015-03-23 22:59:19 +09:00
Matteo Bruni 65c8c40b18 wined3d: Use a separate STATE_VIEWPORT state handler in the GLSL pipeline. 2015-03-23 22:59:18 +09:00
Henri Verbeet ba396e4212 wined3d: Simplify the wined3d_matrix structure. 2015-03-20 21:32:46 +09:00
Matteo Bruni 9811d85141 wined3d: Don't use the builtin FFP uniform for the modelview matrix. 2015-03-19 20:56:59 +09:00
Matteo Bruni 425dc69fef wined3d: Use a separate STATE_TRANSFORM(WINED3D_TS_VIEW) state handler in the GLSL pipeline. 2015-03-19 20:56:56 +09:00
Matteo Bruni 99f3e835ac wined3d: Use a separate STATE_VDECL state handler in the GLSL pipeline.
It's mostly a copy of vertexdeclaration() from state.c, with a few
differences due to the new function being private to the GLSL backend
(e.g. d3d_info.vs_clipping is known to be TRUE) and the fragment fog
update part being split out.
2015-03-19 20:56:50 +09:00
Matteo Bruni 50861156e2 wined3d: Introduce a get_modelview_matrix() function. 2015-03-19 20:56:45 +09:00
Matteo Bruni 2f804307bd wined3d: Drop a few unnecessary &x[0]. 2015-03-02 13:47:52 +09:00
Matteo Bruni aca8ab91eb wined3d: Use the core version of the INCR_WRAP and DECR_WRAP tokens. 2015-02-25 20:35:28 +09:00
Stefan Dösinger 9b3ab8a6f4 wined3d: Set z = 0.0 via the projection matrix instead of depth clamping.
This works on cards that don't implement ARB_depth_clamp like r500
cards. Note that texturing is influenced by position.w, not position.z.
2015-02-12 22:20:05 +09:00
Matteo Bruni e192939652 wined3d: Use the core version of GL vertex attribute functions where possible. 2015-01-23 12:02:33 +01:00
Matteo Bruni 584892b692 wined3d: Properly initialize the last two components of R16G16_SINT attributes. 2015-01-23 12:02:28 +01:00
Matteo Bruni 270431c220 wined3d: Don't normalize R8G8B8A8_UINT attributes. 2015-01-22 13:37:55 +01:00
Matteo Bruni 8ddb7e32f8 wined3d: Add separate stencil state setup via GL 2.0+ core functions. 2015-01-22 13:37:53 +01:00
Matteo Bruni 915e0ef0cf wined3d: Always use the core version of the glPointParameteri function.
The state function depends on GL 2.0+ so it's unnecessary to
check for NV_POINT_SPRITE.
2015-01-20 16:09:01 +01:00
Henri Verbeet ca06f960ed wined3d: Use the same flags for wined3d_texture_set_color_key() and the "color_key_flags" field it sets.
This fixes a regression introduced by commit a8ab569415.
2015-01-19 14:31:51 +01:00
Henri Verbeet 2e5abc156a wined3d: Implement WINED3DSIH_SAMPLE in the GLSL shader backend. 2015-01-19 14:31:32 +01:00
Henri Verbeet c6232e1d11 wined3d: Create GL sampler objects for wined3d sampler objects. 2015-01-15 17:24:43 +01:00
Henri Verbeet 5231113fc7 wined3d: Replace wined3d_texture_apply_state_changes() with wined3d_texture_apply_sampler_desc(). 2015-01-15 17:24:38 +01:00
Matteo Bruni 7e169d43c5 wined3d: Use the core glColorMaski function. 2015-01-15 11:44:22 +01:00
Matteo Bruni 79a0dece8b wined3d: Use the core version of the gl*Buffer* functions. 2015-01-15 11:44:20 +01:00
Matteo Bruni 3ccb66f472 wined3d: Use the core version of the glBlend* functions. 2015-01-09 11:49:37 +01:00
Matteo Bruni 6eb242a275 wined3d: Handle half-float attributes in load_numbered_arrays().
Fixes a bunch of graphic glitches in WildStar on Nvidia.
2014-08-28 15:30:23 +02:00