summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/resources/resourcemanager/resourcemanager.cpp16
-rw-r--r--src/resources/resourcemanager/resourcemanager.h7
2 files changed, 0 insertions, 23 deletions
diff --git a/src/resources/resourcemanager/resourcemanager.cpp b/src/resources/resourcemanager/resourcemanager.cpp
index 1e8b3cdb7..49a59b832 100644
--- a/src/resources/resourcemanager/resourcemanager.cpp
+++ b/src/resources/resourcemanager/resourcemanager.cpp
@@ -650,22 +650,6 @@ void ResourceManager::deleteInstance()
delete2(instance);
}
-SDL_Surface *ResourceManager::loadSDLSurface(const std::string &filename) const
-{
- if (SDL_RWops *const rw = MPHYSFSRWOPS_openRead(filename.c_str()))
- {
- if (!IMG_isPNG(rw))
- {
- reportAlways("Error, image is not png: %s", filename.c_str());
- return nullptr;
- }
- SDL_Surface *const surface = MIMG_LoadPNG_RW(rw);
- SDL_RWclose(rw);
- return surface;
- }
- return nullptr;
-}
-
void ResourceManager::scheduleDelete(SDL_Surface *const surface)
{
deletedSurfaces.insert(surface);
diff --git a/src/resources/resourcemanager/resourcemanager.h b/src/resources/resourcemanager/resourcemanager.h
index ee70cb768..c1e55355b 100644
--- a/src/resources/resourcemanager/resourcemanager.h
+++ b/src/resources/resourcemanager/resourcemanager.h
@@ -138,13 +138,6 @@ class ResourceManager final : public MemoryCounter
*/
void moveToDeleted(Resource *const res);
- /**
- * Loads the given filename as an SDL surface. The returned surface is
- * expected to be freed by the caller using SDL_FreeSurface.
- */
- SDL_Surface *loadSDLSurface(const std::string &filename)
- const A_WARN_UNUSED;
-
void scheduleDelete(SDL_Surface *const surface);
void clearScheduled();