Create screenshot folder it it does not yet exist

This commit is contained in:
Jonas Herzig
2018-01-16 21:52:05 +01:00
parent 22e4ce4584
commit ea2427a73c

View File

@@ -43,6 +43,7 @@ public class ScreenshotWriter implements FrameConsumer<RGBFrame> {
} }
} }
outputFile.getParentFile().mkdirs();
ImageIO.write(img, "PNG", outputFile); ImageIO.write(img, "PNG", outputFile);
} catch (OutOfMemoryError e) { } catch (OutOfMemoryError e) {
e.printStackTrace(); e.printStackTrace();