summaryrefslogtreecommitdiff
path: root/src/video_core/texture_cache
diff options
context:
space:
mode:
authorGravatar liamwhite2023-01-19 14:58:53 -0500
committerGravatar GitHub2023-01-19 14:58:53 -0500
commit475370c8f89002e3b508eb152b981a5b89049d68 (patch)
tree79a145e24f2bf5ab5baca6824cae6cd525a8d170 /src/video_core/texture_cache
parentMerge pull request #9623 from liamwhite/wp-oops (diff)
parentAddress feedback (diff)
downloadyuzu-475370c8f89002e3b508eb152b981a5b89049d68.tar.gz
yuzu-475370c8f89002e3b508eb152b981a5b89049d68.tar.xz
yuzu-475370c8f89002e3b508eb152b981a5b89049d68.zip
Merge pull request #9556 from vonchenplus/draw_texture
video_core: Implement maxwell3d draw texture method
Diffstat (limited to 'src/video_core/texture_cache')
-rw-r--r--src/video_core/texture_cache/texture_cache.h7
-rw-r--r--src/video_core/texture_cache/texture_cache_base.h3
2 files changed, 10 insertions, 0 deletions
diff --git a/src/video_core/texture_cache/texture_cache.h b/src/video_core/texture_cache/texture_cache.h
index 87152c8e9..1b01990a4 100644
--- a/src/video_core/texture_cache/texture_cache.h
+++ b/src/video_core/texture_cache/texture_cache.h
@@ -149,6 +149,13 @@ typename P::ImageView& TextureCache<P>::GetImageView(ImageViewId id) noexcept {
149} 149}
150 150
151template <class P> 151template <class P>
152typename P::ImageView& TextureCache<P>::GetImageView(u32 index) noexcept {
153 const auto image_view_id = VisitImageView(channel_state->graphics_image_table,
154 channel_state->graphics_image_view_ids, index);
155 return slot_image_views[image_view_id];
156}
157
158template <class P>
152void TextureCache<P>::MarkModification(ImageId id) noexcept { 159void TextureCache<P>::MarkModification(ImageId id) noexcept {
153 MarkModification(slot_images[id]); 160 MarkModification(slot_images[id]);
154} 161}
diff --git a/src/video_core/texture_cache/texture_cache_base.h b/src/video_core/texture_cache/texture_cache_base.h
index 4eea1f609..485eaabaa 100644
--- a/src/video_core/texture_cache/texture_cache_base.h
+++ b/src/video_core/texture_cache/texture_cache_base.h
@@ -129,6 +129,9 @@ public:
129 /// Return a reference to the given image view id 129 /// Return a reference to the given image view id
130 [[nodiscard]] ImageView& GetImageView(ImageViewId id) noexcept; 130 [[nodiscard]] ImageView& GetImageView(ImageViewId id) noexcept;
131 131
132 /// Get the imageview from the graphics descriptor table in the specified index
133 [[nodiscard]] ImageView& GetImageView(u32 index) noexcept;
134
132 /// Mark an image as modified from the GPU 135 /// Mark an image as modified from the GPU
133 void MarkModification(ImageId id) noexcept; 136 void MarkModification(ImageId id) noexcept;
134 137