yuzu-mainline/src/video_core/shader/decode
ReinUsesLisp 5b2b6d594c shader/texture: Join separate image and sampler pairs offline
Games using D3D idioms can join images and samplers when a shader
executes, instead of baking them into a combined sampler image. This is
also possible on Vulkan.

One approach to this solution would be to use separate samplers on
Vulkan and leave this unimplemented on OpenGL, but we can't do this
because there's no consistent way of determining which constant buffer
holds a sampler and which one an image. We could in theory find the
first bit and if it's in the TIC area, it's an image; but this falls
apart when an image or sampler handle use an index of zero.

The used approach is to track for a LOP.OR operation (this is done at an
IR level, not at an ISA level), track again the constant buffers used as
source and store this pair. Then, outside of shader execution, join
the sample and image pair with a bitwise or operation.

This approach won't work on games that truly use separate samplers in a
meaningful way. For example, pooling textures in a 2D array and
determining at runtime what sampler to use.

This invalidates OpenGL's disk shader cache :)

- Used mostly by D3D ports to Switch
2020-06-05 00:24:51 -03:00
..
arithmetic_half_immediate.cpp
arithmetic_half.cpp decode/arithmetic_half: Fix HADD2 and HMUL2 absolute and negation bits 2020-04-23 18:29:38 -03:00
arithmetic_immediate.cpp
arithmetic_integer_immediate.cpp
arithmetic_integer.cpp shader/arithmetic_integer: Fix tracking issue in temporary 2020-04-28 17:14:53 -03:00
arithmetic.cpp shader/arithmetic: Add FCMP_CR variant 2020-04-14 19:11:04 -03:00
bfe.cpp
bfi.cpp
conversion.cpp shader/conversion: Implement I2I sign extension, saturation and selection 2020-04-07 02:19:44 -03:00
ffma.cpp
float_set_predicate.cpp
float_set.cpp
half_set_predicate.cpp
half_set.cpp
hfma2.cpp
image.cpp shader_ir: Turn classes into data structures 2020-04-23 18:00:06 -03:00
integer_set_predicate.cpp
integer_set.cpp
memory.cpp shader/memory: Implement non-addition operations in RED 2020-05-21 23:19:46 -03:00
other.cpp Merge pull request #4016 from ReinUsesLisp/invocation-info 2020-06-02 09:47:53 -04:00
predicate_set_predicate.cpp
predicate_set_register.cpp
register_set_predicate.cpp decode/register_set_predicate: Implement CC 2020-04-25 22:54:42 -03:00
shift.cpp decode/shift: Remove unused variable within Shift() 2020-04-16 00:16:06 -04:00
texture.cpp shader/texture: Join separate image and sampler pairs offline 2020-06-05 00:24:51 -03:00
video.cpp shader/video: Partially implement VMNMX 2020-04-12 00:34:42 -03:00
warp.cpp
xmad.cpp shader_ir: Separate float-point comparisons in ordered and unordered 2020-05-09 04:55:15 -03:00