diff --git a/include/eepp/graphics/image.hpp b/include/eepp/graphics/image.hpp index 2680bd693..fafc24ca5 100644 --- a/include/eepp/graphics/image.hpp +++ b/include/eepp/graphics/image.hpp @@ -318,7 +318,7 @@ class EE_API Image { Sizei getSize(); /** Save the Image to a new File in a specific format */ - virtual bool saveToFile( const std::string& filepath, const SaveType& Format ) const; + virtual bool saveToFile( const std::string& filepath, const SaveType& Format ); /** Create an Alpha mask from a Color */ virtual void createMaskFromColor( const Color& ColorKey, Uint8 Alpha ); diff --git a/include/eepp/graphics/texture.hpp b/include/eepp/graphics/texture.hpp index 6a9123cab..a33de3484 100644 --- a/include/eepp/graphics/texture.hpp +++ b/include/eepp/graphics/texture.hpp @@ -90,7 +90,7 @@ class EE_API Texture : public DrawableResource, public Image, private NonCopyabl const Filter& getFilter() const; /** Save the Texture to a new File */ - bool saveToFile( const std::string& filepath, const Image::SaveType& Format ); + virtual bool saveToFile( const std::string& filepath, const Image::SaveType& Format ); /** Replace a color on the texture */ void replaceColor( const Color& ColorKey, const Color& NewColor ); diff --git a/src/eepp/graphics/image.cpp b/src/eepp/graphics/image.cpp index 5bf6f5f91..a3605bd40 100644 --- a/src/eepp/graphics/image.cpp +++ b/src/eepp/graphics/image.cpp @@ -770,7 +770,7 @@ unsigned int Image::getChannels() const { return mChannels; } -bool Image::saveToFile( const std::string& filepath, const SaveType& Format ) const { +bool Image::saveToFile( const std::string& filepath, const SaveType& Format ) { bool Res = false; std::string fpath( FileSystem::fileRemoveFileName( filepath ) );