diff options
| author | Lioncash <mathew1800@gmail.com> | 2020-11-13 22:33:26 -0500 |
|---|---|---|
| committer | Lioncash <mathew1800@gmail.com> | 2020-11-17 21:23:58 -0500 |
| commit | 3d9b2aa0055ded7ee74f6e4a73ff54acecf313a9 (patch) | |
| tree | 0ff92a960d77b6bc8b92bed1c7d61f79206887dc /Source/Core/VideoCommon/ImageWrite.cpp | |
| parent | 8a621c2d5e7722de5148a0a40d4072445cffb361 (diff) | |
VideoCommon: Migrate over to fmt
Migrates off the printf-based formatting where applicable.
Diffstat (limited to 'Source/Core/VideoCommon/ImageWrite.cpp')
| -rw-r--r-- | Source/Core/VideoCommon/ImageWrite.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/Source/Core/VideoCommon/ImageWrite.cpp b/Source/Core/VideoCommon/ImageWrite.cpp index 585ba5e13b..1085e7df24 100644 --- a/Source/Core/VideoCommon/ImageWrite.cpp +++ b/Source/Core/VideoCommon/ImageWrite.cpp @@ -51,8 +51,7 @@ bool TextureToPng(const u8* data, int row_stride, const std::string& filename, i File::IOFile fp(filename, "wb"); if (!fp.IsOpen()) { - PanicAlertT("Screenshot failed: Could not open file \"%s\" (error %d)", filename.c_str(), - errno); + PanicAlertFmtT("Screenshot failed: Could not open file \"{}\" (error {})", filename, errno); goto finalise; } @@ -60,7 +59,7 @@ bool TextureToPng(const u8* data, int row_stride, const std::string& filename, i png_ptr = png_create_write_struct(PNG_LIBPNG_VER_STRING, nullptr, nullptr, nullptr); if (png_ptr == nullptr) { - PanicAlert("Screenshot failed: Could not allocate write struct"); + PanicAlertFmt("Screenshot failed: Could not allocate write struct"); goto finalise; } @@ -68,7 +67,7 @@ bool TextureToPng(const u8* data, int row_stride, const std::string& filename, i info_ptr = png_create_info_struct(png_ptr); if (info_ptr == nullptr) { - PanicAlert("Screenshot failed: Could not allocate info struct"); + PanicAlertFmt("Screenshot failed: Could not allocate info struct"); goto finalise; } @@ -82,7 +81,7 @@ bool TextureToPng(const u8* data, int row_stride, const std::string& filename, i // would need to be volatile). if (setjmp(png_jmpbuf(png_ptr))) { - PanicAlert("Screenshot failed: Error during PNG creation"); + PanicAlertFmt("Screenshot failed: Error during PNG creation"); goto finalise; } |
