Feature: allow custom width/height of screenshot via console

Reworked how the screenshot command works while keeping it backwards
compatible. It can now more freely understand arguments, and has
the ability to make SC_DEFAULTZOOM screenshots.
This commit is contained in:
Patric Stout
2021-01-22 16:16:33 +01:00
committed by Patric Stout
parent 879eb9c348
commit ac5e77ea3b
3 changed files with 85 additions and 36 deletions

View File

@@ -25,10 +25,10 @@ enum ScreenshotType {
SC_MINIMAP, ///< Minimap screenshot.
};
void SetupScreenshotViewport(ScreenshotType t, struct Viewport *vp);
void SetupScreenshotViewport(ScreenshotType t, struct Viewport *vp, uint32 width = 0, uint32 height = 0);
bool MakeHeightmapScreenshot(const char *filename);
void MakeScreenshotWithConfirm(ScreenshotType t);
bool MakeScreenshot(ScreenshotType t, const char *name);
bool MakeScreenshot(ScreenshotType t, const char *name, uint32 width = 0, uint32 height = 0);
bool MakeMinimapWorldScreenshot();
extern char _screenshot_format_name[8];