diff options
Diffstat (limited to 'mwe/resource-manager/resource_converter.cpp')
-rw-r--r-- | mwe/resource-manager/resource_converter.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/mwe/resource-manager/resource_converter.cpp b/mwe/resource-manager/resource_converter.cpp index 63b7491..0477dc2 100644 --- a/mwe/resource-manager/resource_converter.cpp +++ b/mwe/resource-manager/resource_converter.cpp @@ -13,9 +13,8 @@ ResourceConverter::ResourceConverter() { IMG_Init(IMG_INIT_PNG); } ResourceConverter::~ResourceConverter() { IMG_Quit(); } -SDL_Surface * -ResourceConverter::FromStringToImage(const Texture& resource) { - const std::string& content = resource.getContent(); +SDL_Surface * ResourceConverter::FromStringToImage(const Texture & resource) { + const std::string & content = resource.getContent(); SDL_RWops * rw = SDL_RWFromConstMem(content.data(), content.size()); if (!rw) { std::cerr << "Failed to create SDL_RWops: " << SDL_GetError() @@ -30,8 +29,7 @@ ResourceConverter::FromStringToImage(const Texture& resource) { return surface; } - -TiledMap ResourceConverter::FromStringToMap(const Map& resource){ - const std::string& content = resource.getContent(); +TiledMap ResourceConverter::FromStringToMap(const Map & resource) { + const std::string & content = resource.getContent(); return TiledMap(content); } |