19e945c733
Apply possible HLSL compiler optimization for pow() function with literal 1 as exponent
...
Signed-off-by: Kai Blaschke <kai.blaschke@kb-dev.net >
2025-11-20 10:57:11 +01:00
fdd9428927
Fix a constant's type in float acos(float) overload in HLSL transpiler
...
Signed-off-by: Kai Blaschke <kai.blaschke@kb-dev.net >
2025-11-19 13:04:33 +01:00
ae4246c8b7
Add missing "fwidth" intrinsic in HLSL transpiler
...
Signed-off-by: Kai Blaschke <kai.blaschke@kb-dev.net >
2025-11-19 13:04:33 +01:00
961ed473b6
Add additional row-access functions for matrices in HLSL transpiler
...
Fixes "martin - mayday (shifters escape retouched).milk" and probably some others.
Signed-off-by: Kai Blaschke <kai.blaschke@kb-dev.net >
2025-11-19 11:54:02 +01:00
0f026e0734
Add additional alternates for the mult() function with int as arguments
...
Required to propagate NaNs as SM3/DX9 does.
Signed-off-by: Kai Blaschke <kai.blaschke@kb-dev.net >
2025-11-02 15:09:38 +01:00
5912f74273
Convert HLSL array subscript operator operand to int
2025-10-28 17:54:02 +01:00
0a1a71fbd9
Add missing "distance" intrinsic to HLSLparser
...
Signed-off-by: Kai Blaschke <kai.blaschke@kb-dev.net >
2025-10-28 17:54:02 +01:00
18c3ad764c
hlslparser: Add missing "faceforward" HLSL intrinsic.
2024-12-16 17:46:39 +01:00
4ad657c161
hlslparser: Add missing "ldexp" HLSL intrinsic.
...
Had to simulate it with the "x * exp2(exp)" expression in GLSL, as GLSL only supports integer types as exponents in its native ldexp implementation, while HLSL solely uses floats.
2024-12-16 17:46:36 +01:00
03b4c071a2
Properly cast argument types when adding abs to shader functions
2024-02-28 17:03:37 +01:00
07c9a8a660
Re-add native matrix multiplication
2024-02-21 14:36:35 +01:00
3aa48a3f99
Modify NaN propagation for multiplication
2024-02-21 14:36:35 +01:00
db89e54109
Add mat3x4 and mat4x3 indexing functions
2024-02-21 14:12:12 +01:00
04be6f40d0
Fix pow domain on some drivers
2024-02-21 14:11:37 +01:00
7d97baffcd
Match math function behavior to DX9 implementation
2024-02-21 14:11:37 +01:00
6e93c1f624
Consolidate USE_GLES define usage.
2024-01-19 11:57:06 +01:00
484c3579d7
Fix a memory leak in HLSLMacro class due to use of std::string.
...
The HLSLMacro struct is manually malloc'd, not using new/delete, so the std::string destructor is never called on the instance stored in the class.
Fixed by using a char* allocated by HLSLTree, which will then properly take care of deleting it after parsing is complete.
2024-01-19 11:57:06 +01:00
7cb79fe5b5
Improve robustness and fix leaking of hlslparser's Array memory management.
2024-01-19 11:57:06 +01:00
ce0e5853b2
More work on shader stuff, warp/comp shaders now compile properly.
...
Fixed a transpile issue with a hack used by some preset authors to set a texture sampler to a different filter/wrap mode, removing the "sampler_state" block entirely now as there's no GLSL equivalent (samplers are solely configured on the application side).
Also consolidated a few vertex types into RenderItem and fixed a few old-school effects like DarkenCenter.
2023-09-11 10:19:47 +02:00
e7094aa190
Remove "Pipeline" classes and temp fix all compilation issues.
2023-09-11 10:19:46 +02:00
b9f1c16f58
Move third-party libraries to "vendor" dir.
2023-03-03 14:30:24 +01:00