diff options
author | Subv <subv2112@gmail.com> | 2018-04-16 02:53:15 +0200 |
---|---|---|
committer | Subv <subv2112@gmail.com> | 2018-04-18 19:52:51 +0200 |
commit | 6b63aaa5b4f55621117e27c6b80979908c255e75 (patch) | |
tree | 14ea1f2ecd3c195867f22a4ae6e68626d13e2dd7 /src/video_core/textures/texture.h | |
parent | GPU/TIC: Added the pitch and block height fields to the TIC structure. (diff) | |
download | yuzu-6b63aaa5b4f55621117e27c6b80979908c255e75.tar yuzu-6b63aaa5b4f55621117e27c6b80979908c255e75.tar.gz yuzu-6b63aaa5b4f55621117e27c6b80979908c255e75.tar.bz2 yuzu-6b63aaa5b4f55621117e27c6b80979908c255e75.tar.lz yuzu-6b63aaa5b4f55621117e27c6b80979908c255e75.tar.xz yuzu-6b63aaa5b4f55621117e27c6b80979908c255e75.tar.zst yuzu-6b63aaa5b4f55621117e27c6b80979908c255e75.zip |
Diffstat (limited to '')
-rw-r--r-- | src/video_core/textures/texture.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/video_core/textures/texture.h b/src/video_core/textures/texture.h index 58cbb2115..09d2317e0 100644 --- a/src/video_core/textures/texture.h +++ b/src/video_core/textures/texture.h @@ -105,6 +105,13 @@ struct TICEntry { return height_minus_1 + 1; } + u32 BlockHeight() const { + ASSERT(header_version == TICHeaderVersion::BlockLinear || + header_version == TICHeaderVersion::BlockLinearColorKey); + // The block height is stored in log2 format. + return 1 << block_height; + } + bool IsTiled() const { return header_version == TICHeaderVersion::BlockLinear || header_version == TICHeaderVersion::BlockLinearColorKey; |