diff options
Diffstat (limited to 'gfx/models')
-rw-r--r-- | gfx/models/texture.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gfx/models/texture.cpp b/gfx/models/texture.cpp index 942cedf..ef6d7e7 100644 --- a/gfx/models/texture.cpp +++ b/gfx/models/texture.cpp @@ -48,8 +48,8 @@ Texture::save(const glTexture & texture, GLenum format, GLenum type, const glm:: {
using TGAHead = std::array<short, 9>;
- size_t dataSize = (static_cast<size_t>(size.x * size.y * channels));
- size_t fileSize = dataSize + sizeof(TGAHead);
+ const size_t dataSize = (static_cast<size_t>(size.x * size.y * channels));
+ const size_t fileSize = dataSize + sizeof(TGAHead);
filesystem::fh out {path, O_RDWR | O_CREAT, 0660};
out.truncate(fileSize);
|