rlm@3: package com.aurellem.capture; rlm@3: rlm@3: import java.io.File; rlm@3: import java.io.IOException; rlm@3: rlm@9: import com.aurellem.capture.video.AVIVideoRecorder; rlm@3: import com.jme3.app.Application; rlm@3: import com.jme3.math.ColorRGBA; rlm@3: rlm@3: public class Capture { rlm@3: rlm@3: public static void SimpleCaptureVideo(Application app, File file) throws IOException{ rlm@3: app.getViewPort().setClearFlags(true, true, true); rlm@3: app.getViewPort().setBackgroundColor(ColorRGBA.Black); rlm@3: AVIVideoRecorder videoRecorder = new AVIVideoRecorder(file); rlm@3: app.getStateManager().attach(videoRecorder); rlm@3: app.getViewPort().addFinalProcessor(videoRecorder); rlm@3: } rlm@3: rlm@3: rlm@3: rlm@3: rlm@3: rlm@3: }