Created
February 22, 2017 12:18
-
-
Save brendandawes/a3d42249471e4acbd8739bf8cba49dd8 to your computer and use it in GitHub Desktop.
exporting frames for video
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
final int VIDEO_FRAME_RATE = 60; | |
final int SECONDS_TO_CAPTURE = 60; | |
int videoFramesCaptured = 0; | |
boolean recordVideo = false; | |
if (recordVideo){ | |
saveFrame("export/####-video.tga"); | |
if (videoFramesCaptured > VIDEO_FRAME_RATE * SECONDS_TO_CAPTURE){ | |
recordVideo = false; | |
} | |
videoFramesCaptured++; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment