From fcaae0500d5c6fa842babe37450c435e4178547a Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Thu, 3 Nov 2016 10:29:08 +0200 Subject: [PATCH] Fix Texture2D::get_data_size to use get_pixel_size --- source/texture2d.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/texture2d.cpp b/source/texture2d.cpp index 75b84ec7..e15f9a33 100644 --- a/source/texture2d.cpp +++ b/source/texture2d.cpp @@ -171,7 +171,7 @@ Resource::AsyncLoader *Texture2D::load(IO::Seekable &io, const Resources *res) UInt64 Texture2D::get_data_size() const { - return id ? width*height*get_component_count(ifmt) : 0; + return id ? width*height*get_pixel_size(ifmt) : 0; } void Texture2D::unload() -- 2.43.0