diff options
author | ReinUsesLisp <reinuseslisp@airmail.cc> | 2019-11-06 08:32:43 +0100 |
---|---|---|
committer | ReinUsesLisp <reinuseslisp@airmail.cc> | 2019-11-23 01:28:47 +0100 |
commit | 32c1bc6a67820f9df21c8f64f4df078b015aa7da (patch) | |
tree | 141df885726a01fbd7d999d6ee314b4d11c8ce56 /src/video_core/shader/node.h | |
parent | Merge pull request #3142 from ReinUsesLisp/depbar-log (diff) | |
download | yuzu-32c1bc6a67820f9df21c8f64f4df078b015aa7da.tar yuzu-32c1bc6a67820f9df21c8f64f4df078b015aa7da.tar.gz yuzu-32c1bc6a67820f9df21c8f64f4df078b015aa7da.tar.bz2 yuzu-32c1bc6a67820f9df21c8f64f4df078b015aa7da.tar.lz yuzu-32c1bc6a67820f9df21c8f64f4df078b015aa7da.tar.xz yuzu-32c1bc6a67820f9df21c8f64f4df078b015aa7da.tar.zst yuzu-32c1bc6a67820f9df21c8f64f4df078b015aa7da.zip |
Diffstat (limited to '')
-rw-r--r-- | src/video_core/shader/node.h | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/src/video_core/shader/node.h b/src/video_core/shader/node.h index 54217e6a4..44d85d434 100644 --- a/src/video_core/shader/node.h +++ b/src/video_core/shader/node.h @@ -225,14 +225,15 @@ class Sampler { public: /// This constructor is for bound samplers constexpr explicit Sampler(u32 index, u32 offset, Tegra::Shader::TextureType type, - bool is_array, bool is_shadow) - : index{index}, offset{offset}, type{type}, is_array{is_array}, is_shadow{is_shadow} {} + bool is_array, bool is_shadow, bool is_buffer) + : index{index}, offset{offset}, type{type}, is_array{is_array}, is_shadow{is_shadow}, + is_buffer{is_buffer} {} /// This constructor is for bindless samplers constexpr explicit Sampler(u32 index, u32 offset, u32 buffer, Tegra::Shader::TextureType type, - bool is_array, bool is_shadow) + bool is_array, bool is_shadow, bool is_buffer) : index{index}, offset{offset}, buffer{buffer}, type{type}, is_array{is_array}, - is_shadow{is_shadow}, is_bindless{true} {} + is_shadow{is_shadow}, is_buffer{is_buffer}, is_bindless{true} {} constexpr u32 GetIndex() const { return index; @@ -258,6 +259,10 @@ public: return is_shadow; } + constexpr bool IsBuffer() const { + return is_buffer; + } + constexpr bool IsBindless() const { return is_bindless; } @@ -270,6 +275,7 @@ private: Tegra::Shader::TextureType type{}; ///< The type used to sample this texture (Texture2D, etc) bool is_array{}; ///< Whether the texture is being sampled as an array texture or not. bool is_shadow{}; ///< Whether the texture is being sampled as a depth texture or not. + bool is_buffer{}; ///< Whether the texture is a texture buffer without sampler. bool is_bindless{}; ///< Whether this sampler belongs to a bindless texture or not. }; |