Skip to content

Commit 579691c

Browse files
authored
Merge pull request #195 from ntut-xuan/fix-undefined-reference-missing-font-texture
Fix: Undefined Reference Missing font texture
2 parents d05569e + 54dfe13 commit 579691c

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

include/Util/MissingTexture.hpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,9 @@ static constexpr auto MISSING_IMAGE_TEXTURE_BASE64_DECODE =
2121
DecodeBase64<MISSING_IMAGE_TEXTURE_BASE64_DECODE_LENGTH>(
2222
MISSING_IMAGE_TEXTURE);
2323

24+
namespace Util {
2425
SDL_Surface *GetMissingFontTextureSDLSurface();
2526
SDL_Surface *GetMissingImageTextureSDLSurface();
27+
} // namespace Util
2628

2729
#endif

src/Util/Image.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ std::shared_ptr<SDL_Surface> LoadSurface(const std::string &filepath) {
1616
SDL_FreeSurface);
1717

1818
if (surface == nullptr) {
19-
surface = {GetMissingImageTextureSDLSurface(), SDL_FreeSurface};
19+
surface = {Util::GetMissingImageTextureSDLSurface(), SDL_FreeSurface};
2020
LOG_ERROR("Failed to load image: '{}'", filepath);
2121
LOG_ERROR("{}", IMG_GetError());
2222
}

0 commit comments

Comments
 (0)