Unknown W. Brackets
941988cde4
Correct prescale issues with render-to-texture.
...
Still need to apply the scaling of the texture coordinates here (or
somewhere, maybe we prescale that as well? Except it's figured later on
in the process...)
2015-12-20 21:13:43 -08:00
Henrik Rydgard
f4248cb550
Remove a whole lot of flipping special cases
2015-11-02 20:07:30 +01:00
Unknown W. Brackets
6b905e8e18
d3d9: Remove the old shader id gen.
2015-10-24 21:26:40 -07:00
Henrik Rydgard
85229efef4
D3D9: Generate shaders directly from shader IDs, just like we do in GL.
2015-10-25 00:34:23 +02:00
Henrik Rydgard
92389a4966
Use a common ShaderId class. Start moving shader ID code to GPU/Common
2015-10-24 23:24:06 +02:00
Henrik Rydgard
b07b002040
Introduce "Compatibility Flags".
...
These should be used very restrictively, see comment in Compatibility.h.
Should help #8004 , by disabling depth rounding in Fight Night round 3.
2015-09-27 01:23:20 +02:00
Henrik Rydgard
08b340f423
More D3D hackery: Take inverted Z in proj matrix into account.
...
Also, *2 breaks it for no good reason so don't do that.
2015-08-30 22:45:24 +02:00
Henrik Rydgard
7b0a31ade5
Adjust D3D depth calculations to get them to match OpenGL as close as I can get it.
2015-08-29 17:43:09 +02:00
Henrik Rydgard
bf6aef44cd
Oops, didn't finish the D3D code
2015-08-26 17:45:21 +02:00
Henrik Rydgard
d89da71057
Get rid of a division in the vertex shader by precomputing the inverse.
2015-08-26 17:40:06 +02:00
Henrik Rydgard
44ce0c8dee
Implement vertex shader depth rounding in DX9
2015-08-26 16:07:40 +02:00
Unknown W. Brackets
04eb83002c
Assume lmode does nothing in throughmode.
2015-03-08 18:03:17 -07:00
Unknown W. Brackets
fb071a066d
d3d9: Change vertex attribute logic to match gles.
2015-03-08 18:01:00 -07:00
Unknown W. Brackets
83e4edbc7c
Oops, don't affect hardware transform.
2015-03-08 14:19:44 -07:00
Unknown W. Brackets
39cb74a8d3
Simplify transform in throughmode/sw (rectangles.)
...
This should make it a bit faster, a bit less work.
2015-03-08 13:12:13 -07:00
The Dax
3239e27e84
Update GE_TEXMAP_ENVIRONMENT_MAP in Direct3D9 so it matches OpenGL's behaviour.
...
Improves the car colours in Outrun 2006, but like OpenGL, it's still got some areas with the wrong blue hue.
2015-02-17 02:17:24 -05:00
Henrik Rydgard
df62bc42b7
D3D shader generator: Fix an issue with 4x3 vs 4x4 matrices that caused warnings to be reported (I think).
...
Make the GL code for this case (skinning without normal) more similar.
2015-01-12 20:37:33 +01:00
Henrik Rydgard
e2d2950865
Add a sanity check for shader linking, active in debug mode
2014-12-14 20:17:29 +01:00
Unknown W. Brackets
9355322824
d3d9: Fix shader compile error X3014.
2014-09-21 09:05:47 -07:00
Unknown W. Brackets
a62f88d1f8
d3d9: Oops, don't need this, no prescale.
...
Hmm, trying to reduce differences, though...
2014-09-21 00:09:38 -07:00
Unknown W. Brackets
6f38c21ccc
d3d9: Make the vertex shaders more similar.
2014-09-20 23:55:48 -07:00
Henrik Rydgard
9bb5bd6fb3
Of course have to update these as well.
2014-09-19 00:39:34 +02:00
Henrik Rydgard
9c625a79a1
DX9: Use 4x3 matrices for bones too. Compact shader constants.
2014-09-18 23:14:53 +02:00
Henrik Rydgard
6304d60b40
Convert 4x4 to 4x3 matrices where possible (except bones)
2014-09-18 23:08:46 +02:00
Henrik Rydgard
1407648b59
D3D vtxdec: Convert weights and normals to float
2014-09-12 02:00:33 +02:00
Henrik Rydgard
7b66059ae0
D3D: Assorted cleanup. Add a missing register specification.
2014-09-10 15:20:57 +02:00
Henrik Rydgard
bf7a4f9097
D3D: Use fixed constant registers for vertex shaders too.
2014-09-10 13:43:35 +02:00
Henrik Rydgard
6fa1872163
DX9: Disable an annoying warning in vertex shader generator to clean up our reports
...
warning X3571: pow(f, e) will not work for negative f, use abs(f) or conditionally handle negative values if you expect them
2014-09-10 11:04:37 +02:00
Henrik Rydgard
8ef326e531
D3D: Remove now-redundant texture coord scaling now that we decode the 8-bit and 16-bit formats in the vertex decoder
2014-09-09 22:32:59 +02:00
Unknown W. Brackets
1b12ad1b91
d3d: Fix a shader warning from sw transform.
2014-09-08 22:18:34 -07:00
Unknown W. Brackets
375e102647
d3d: Fix some shader issues with tex projection.
2014-09-08 19:33:12 -07:00
Henrik Rydgard
01a1438dce
Improve depth buffering in D3D by computing a depth-flipped proj matrix but only when needed.
2014-09-08 23:10:23 +02:00
Unknown W. Brackets
5639b056b3
d3d: Use 0 texcoord when not specified.
2014-09-06 23:01:04 -07:00
Unknown W. Brackets
a29c2f4f2f
d3d: Use 2.0 vertex and pixel shaders.
2014-09-06 23:01:03 -07:00
Unknown W. Brackets
a34bf158e3
d3d: Clean up some normal handling.
...
So hardware and software transform match gles.
2014-08-25 07:43:19 -07:00
Unknown W. Brackets
170036e171
d3d: Fix another shader compile error.
2014-08-25 07:31:10 -07:00
Unknown W. Brackets
5e829f06e8
d3d: Fix a shader compiler error.
2014-08-25 01:39:04 -07:00
Ced2911
ef54989598
[Gpu] update code, cleanup shaders generation: fixes rr2 lighting !
...
Conflicts:
GPU/Directx9/PixelShaderGeneratorDX9.cpp
GPU/Directx9/ShaderManagerDX9.cpp
GPU/Directx9/VertexDecoderDX9.cpp
2014-08-24 13:43:09 +02:00
Unknown W. Brackets
25bc394284
Ignore the material update flag w/o vertex color.
...
Instead of using materialambient for all of them.
Fixes #3918 , and seems to match tests with 3dstudio.
2013-12-29 12:57:30 -08:00
Henrik Rydgard
01def3b6cc
Missed these
2013-09-21 23:44:11 +02:00
Henrik Rydgard
82e5787bbe
Preparation for proper spline/bez: Convert control points to a simple format.
...
The bezier/spline code will no longer need to handle morph and splines,
when it's finally written. This is done by pre-skinning in software and
pre-decoding to get rid of the morph.
2013-09-21 23:37:14 +02:00
Unknown W. Brackets
f55b6a0dbc
Put the DirectX9 stuff into a namespace.
...
This makes it almost build on Windows, but not quite. Some required files
excluded from build, still.
2013-09-15 08:56:12 -07:00
Henrik Rydgard
cc6681cd0b
Compile Ced's DX9 GPU on Windows. Not hooked up yet.
...
This needs work, has several problems that must be fixed to run on Windows.
Ced, you'll have to fix up your xb project file a bit, sorry.
2013-09-15 12:52:44 +02:00