PatrickvL
23c1dcf1c9
Merge pull request #2237 from jackchentwkh/3D_mip_map_fix
...
fixing 3D mip-map conversion with volume texture, fix Halo
2021-06-12 10:21:46 +02:00
ergo720
addf4b42fd
Merge pull request #2240 from ergo720/xeloadsection_bug_fix
...
Make XeLoadSection return status_invalid_handle when it cannot find the requested section
2021-06-11 13:05:37 +02:00
ergo720
c4d75368a5
return status_invalid_handle when it cannot find the requested section
2021-06-11 12:17:41 +02:00
Luke Usher
f1e54be515
Merge pull request #2239 from ergo720/XAudioDownloadEffectsImage_from_xbe_section
...
Add support to load dsp images from xbe sections
2021-06-10 18:51:25 +01:00
ergo720
d847580881
Added support to load dsp images from xbe sections
2021-06-10 19:39:42 +02:00
ergo720
c7bf62ce62
Merge pull request #2238 from ergo720/XB_InitializeObjectAttributes_fix
...
Removed unused dwBytesRead variable and unused argument from XB_InitalizeObjectAttributes macro
2021-06-10 12:44:48 +02:00
ergo720
98a44aa47d
Removed unused dwBytesRead variable and unused argument from XB_InitializeObjectAttributes macro
2021-06-10 12:22:22 +02:00
jackchentwkh
f003c11260
typo fix
2021-06-10 15:35:56 +08:00
jackchentwkh
55e45e728e
using correct 3D mip map dimention sizes in all 3 dimensions, and calculate correct source size.
...
this fix Halo, get in game.
2021-06-10 11:37:27 +08:00
Luke Usher
ba9ee5fd2f
Merge pull request #2234 from jackchentwkh/DSoundBufferResizeSetSize_fix
...
Implement ImageDesc, fix vector iterator in DSStream packet, this fixs Otogi1, PGR2.
2021-06-08 07:16:37 +01:00
jackchentwkh
fa1f4d4c50
Make sure packet iterator is validate after DSStream_Packet_Clear() calls erase().
...
this fixs debug builds with PGR2
2021-06-08 07:14:11 +08:00
jackchentwkh
ea55dfa45d
remove extra space in end of line, replace tabs with spaces.
2021-06-08 07:14:11 +08:00
jackchentwkh
6bb0234dc8
Fix DSoundBufferResizeSetSize with DSBuffer creation failure when remained hos buffer bytes is less then DSBSIZE_MIN, also correct a wrongly used argument with call to DSound3DBufferCreate. add more sanity checks. this fixs PGR2, now release build can enter the race. but debug build has different issue with vector/iterator.
2021-06-08 07:14:11 +08:00
PatrickvL
8b9b26b56e
Merge pull request #2136 from Cxbx-Reloaded/hlsl_ps
...
Pixel shader hlsl
2021-06-07 16:04:18 +02:00
Anthony
fa0a114e0c
Fix passthru not passing through all components
...
Previous behaviour aligned with ps_1_3 texcoord, where alpha = 1
but appears to be incorrect.
Note ps_1_4 texcrd leaves alpha undefined
Fixes Metal Arms menu clouds
2021-06-07 10:59:36 +02:00
PatrickvL
a8fae55299
Fix HLSL PS bump environment mapping (most of the research done by medieval, thanks!)
2021-06-07 10:59:35 +02:00
PatrickvL
c03b2ed151
Fix DolphinClassic sample, by not making fogDepth absolute (thanks NZJenkins!)
...
(This bug was introduced with PR #2163 , based on some misleading code in xqemu, to cater for what now appear to be non-supported fog modes on NV2A.)
2021-06-07 10:59:35 +02:00
PatrickvL
061e38af6f
HLSL Pixel Shader tweaks;
...
Fully declare stages, to avoid "error X4000: variable 'stages' used without having been completely initialized"
Add alphakill support to fixed function
Use macro-based alphakill declaration in template (same as in fixed function)
Updated comments to differentiate between texture stage and combiner stage
Rename st into ts (texture stage) where appropriate
Fixed a typo in Brdf macro (was s1, must be ts now)
Updated Reflect to use C0 (uppercase, instead of lowercase host c0)
Initialized stage to zero for use in the C0 macro, now used Reflect
Fixed type of CombinerOutputMapping to actualle be PS_COMBINEROUTPUT_OUTPUTMAPPING
Introduced and used varios PS_*_MASK defines
Added some comments on pixel shader verification and test-case discovery.
2021-06-07 10:59:35 +02:00
Anthony
d46abef9a1
Redefine undefined ALPHAOP behaviour for Crash WoC
...
To aid debugging add a LOG_TEST_CASE , and include ALPHAARGs when ALPHAOP is disabled
2021-06-07 10:59:34 +02:00
Anthony
3da5b9f5d9
Include debug comment about how the final combiner hlsl was generated
...
Make hasFinalCombiner correspond to DecodedHasFinalCombiner
2021-06-07 10:59:34 +02:00
Anthony
a29c2f7d62
Force VS to write to oFog.x
...
Default fog factor to 1 (no fog)
2021-06-07 10:59:33 +02:00
Anthony
d8c18cf268
Mask flags when detecting colorarg1 + missing texture case
2021-06-07 10:59:33 +02:00
Anthony
6bf2a1f44f
Reuse colorOp variable
...
And additional comments
2021-06-07 10:59:32 +02:00
Anthony
ce7a5f6e40
Fix GTA III logos
...
Depending on ALPHAOP == DISABLE
2021-06-07 10:59:32 +02:00
Anthony
5aaadd026c
Implement missing texture behaviour
2021-06-07 10:59:32 +02:00
Anthony
990a24292d
Fix reflection equation
...
Improve BumpDemo
2021-06-07 10:59:31 +02:00
Anthony
85f792d2b2
Fix DOTPRODUCT3 texture op
...
Improves PerPixelLighting
2021-06-07 10:59:31 +02:00
Anthony
2f9558d307
Use SAMPLE_NONE instead of IsTextureSet
2021-06-07 10:59:30 +02:00
Anthony
814b040ff1
Normalize the values returned by the texture state converter
2021-06-07 10:59:30 +02:00
Anthony
657a8ef7c3
Disable lighting for point sprites
2021-06-07 10:59:30 +02:00
Anthony
5ea12636ee
Passthrough fogging and generate fog factor for fixed function mode
2021-06-07 10:59:29 +02:00
Anthony
3ea3cdc1a8
Fix implicitly extern shader variable
...
So the hardcoded values are used,
as values were unintuitively being read from constant registers
2021-06-07 10:59:29 +02:00
Anthony
6f2460c70a
Fixed function pixel shader
...
Placeholder shader until we are able to directly load the pixel shader program used on the Xbox
A shader is generated for each texture op and argument combination
2021-06-07 10:59:28 +02:00
Anthony
03200fdcd3
Re-enable texture stage swap hack
2021-06-07 10:59:28 +02:00
medievil1
90bdeac904
fix up fog mode ( #2163 )
...
fix up fog mode
2021-06-07 10:59:26 +02:00
Anthony
726d6ff4f3
Improve scaling of depth buffer texture coordinates
...
- GetZScale accepts a PixelContainer rather than a surface
- Fix accidental call to CxbxGetPixelContainerDepth instead of GetZScale
- Assume we should scale the z component for all depth buffers, not just linear ones
2021-06-07 10:58:46 +02:00
Anthony
512502ce36
Fix Azurik render issue
...
Remove #ifndef blocks that were driven by the opposite define than they should have been
Also provide the opposite flag as a comment, next to where the 'driver' define
2021-06-07 10:58:45 +02:00
Anthony
ad1652f050
Fix array index out-of-range crash
...
Remove PS_REGISTER_ONE usage since its not a register, but a combination of PS_REGISTER_ZERO and an INPUT_MAPPING
2021-06-07 10:58:45 +02:00
Anthony
fe6de7c621
Fix fog when xfc is undefined
...
* flip fog factor lerp. fog factor 1 = no fog
* ensure RC is zero initialized
2021-06-07 10:58:44 +02:00
Anthony
6373ba58bb
fixup typo VXSH instead of PXSH
2021-06-07 10:58:44 +02:00
Anthony
3c96e3236b
use vs_3_0
2021-06-07 10:58:43 +02:00
Anthony
b565d39ffe
fix abs instead of clamp
2021-06-07 10:58:43 +02:00
Anthony
7745515588
Fix front/back colour usage
2021-06-07 10:58:43 +02:00
PatrickvL
55f3c60ef2
Include Pixel Shader HLSL in output artifacts (and fixed a few typos in FixedFunction HLSL)
2021-06-07 10:58:42 +02:00
PatrickvL
b5cc970d7e
Corrected fixed-function formula's in final combiner
2021-06-07 10:58:42 +02:00
Anthony
7f89e72b2b
fixup enable complement in final combiner
...
(cherry picked from commit 71df0a3a5af94f550c2ecc25a47f78e54e74ee4a)
2021-06-07 10:58:41 +02:00
Anthony
e3c0b7287c
fixup FC0 and FC1 constant mapping
...
(cherry picked from commit 45cd7f72f07a5528b83bdadb24b46a934a7bfc50)
2021-06-07 10:58:41 +02:00
Anthony
cb4bbc17ee
Calculate the fog factor in the vertex shader
...
(cherry picked from commit 3c3ede07da1f0829697cc1635058b5dc4ec610d2)
2021-06-07 10:58:41 +02:00
Anthony
3216931da6
fixup fog colour constant register
...
(cherry picked from commit b99e63d944d2ceb474761ae88c8c90246071f0bc)
2021-06-07 10:58:40 +02:00
Anthony
9480bea9c0
Use sampler state
...
(cherry picked from commit ab2064ef690179560761d29eed53fd5b756b5dc7)
2021-06-07 10:58:39 +02:00