summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/video_core/texture_cache/texture_cache.h10
-rw-r--r--src/video_core/texture_cache/texture_cache_base.h6
2 files changed, 16 insertions, 0 deletions
diff --git a/src/video_core/texture_cache/texture_cache.h b/src/video_core/texture_cache/texture_cache.h
index 179f37526..ae74a6ecf 100644
--- a/src/video_core/texture_cache/texture_cache.h
+++ b/src/video_core/texture_cache/texture_cache.h
@@ -120,6 +120,16 @@ typename P::ImageView& TextureCache<P>::GetImageView(ImageViewId id) noexcept {
120} 120}
121 121
122template <class P> 122template <class P>
123const typename P::Image& TextureCache<P>::GetImage(ImageId id) const noexcept {
124 return slot_images[id];
125}
126
127template <class P>
128typename P::Image& TextureCache<P>::GetImage(ImageId id) noexcept {
129 return slot_images[id];
130}
131
132template <class P>
123void TextureCache<P>::MarkModification(ImageId id) noexcept { 133void TextureCache<P>::MarkModification(ImageId id) noexcept {
124 MarkModification(slot_images[id]); 134 MarkModification(slot_images[id]);
125} 135}
diff --git a/src/video_core/texture_cache/texture_cache_base.h b/src/video_core/texture_cache/texture_cache_base.h
index deddf0d30..0d2d9ec2e 100644
--- a/src/video_core/texture_cache/texture_cache_base.h
+++ b/src/video_core/texture_cache/texture_cache_base.h
@@ -95,6 +95,12 @@ public:
95 /// Return a reference to the given image view id 95 /// Return a reference to the given image view id
96 [[nodiscard]] ImageView& GetImageView(ImageViewId id) noexcept; 96 [[nodiscard]] ImageView& GetImageView(ImageViewId id) noexcept;
97 97
98 /// Return a constant reference to the given image id
99 [[nodiscard]] const Image& GetImage(ImageId id) const noexcept;
100
101 /// Return a reference to the given image id
102 [[nodiscard]] Image& GetImage(ImageId id) noexcept;
103
98 /// Mark an image as modified from the GPU 104 /// Mark an image as modified from the GPU
99 void MarkModification(ImageId id) noexcept; 105 void MarkModification(ImageId id) noexcept;
100 106