diff options
| author | 2020-01-13 20:35:43 -0300 | |
|---|---|---|
| committer | 2020-01-13 20:35:43 -0300 | |
| commit | 2b2712fa95b99d1761270131b2604b7c9e99eac5 (patch) | |
| tree | 07993cc6cb7d5bbecdb1b1fb415cae856922fd82 | |
| parent | Merge pull request #3283 from ReinUsesLisp/vk-compute-pass (diff) | |
| download | yuzu-2b2712fa95b99d1761270131b2604b7c9e99eac5.tar.gz yuzu-2b2712fa95b99d1761270131b2604b7c9e99eac5.tar.xz yuzu-2b2712fa95b99d1761270131b2604b7c9e99eac5.zip | |
texture_cache/surface_params: Make GetNumLayers public
| -rw-r--r-- | src/video_core/texture_cache/surface_params.h | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/video_core/texture_cache/surface_params.h b/src/video_core/texture_cache/surface_params.h index 992b5c022..9256fd6d9 100644 --- a/src/video_core/texture_cache/surface_params.h +++ b/src/video_core/texture_cache/surface_params.h | |||
| @@ -209,6 +209,11 @@ public: | |||
| 209 | return target == VideoCore::Surface::SurfaceTarget::TextureBuffer; | 209 | return target == VideoCore::Surface::SurfaceTarget::TextureBuffer; |
| 210 | } | 210 | } |
| 211 | 211 | ||
| 212 | /// Returns the number of layers in the surface. | ||
| 213 | std::size_t GetNumLayers() const { | ||
| 214 | return is_layered ? depth : 1; | ||
| 215 | } | ||
| 216 | |||
| 212 | /// Returns the debug name of the texture for use in graphic debuggers. | 217 | /// Returns the debug name of the texture for use in graphic debuggers. |
| 213 | std::string TargetName() const; | 218 | std::string TargetName() const; |
| 214 | 219 | ||
| @@ -287,10 +292,6 @@ private: | |||
| 287 | /// Returns the size of a layer | 292 | /// Returns the size of a layer |
| 288 | std::size_t GetLayerSize(bool as_host_size, bool uncompressed) const; | 293 | std::size_t GetLayerSize(bool as_host_size, bool uncompressed) const; |
| 289 | 294 | ||
| 290 | std::size_t GetNumLayers() const { | ||
| 291 | return is_layered ? depth : 1; | ||
| 292 | } | ||
| 293 | |||
| 294 | /// Returns true if these parameters are from a layered surface. | 295 | /// Returns true if these parameters are from a layered surface. |
| 295 | bool IsLayered() const; | 296 | bool IsLayered() const; |
| 296 | }; | 297 | }; |