changeset 50:8a091a5f48fa

documentation for basic use case
author Robert McIntyre <rlm@mit.edu>
date Sat, 03 Dec 2011 13:35:13 -0600
parents 121b6d7e4d3f
children 6a1b28f060e6
files src/com/aurellem/capture/examples/Advanced.java src/com/aurellem/capture/examples/HelloAudioRecording.java src/com/aurellem/capture/examples/HelloVideoRecording.java
diffstat 3 files changed, 32 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
     1.1 --- a/src/com/aurellem/capture/examples/Advanced.java	Sat Dec 03 13:22:27 2011 -0600
     1.2 +++ b/src/com/aurellem/capture/examples/Advanced.java	Sat Dec 03 13:35:13 2011 -0600
     1.3 @@ -35,7 +35,6 @@
     1.4  import com.jme3.system.AppSettings;
     1.5  import com.jme3.system.JmeSystem;
     1.6  
     1.7 -
     1.8  /**
     1.9   * 
    1.10   * Demonstrates advanced use of the audio capture and recording features.
    1.11 @@ -57,7 +56,6 @@
    1.12  
    1.13  public class Advanced extends SimpleApplication {
    1.14  
    1.15 -
    1.16  	private Geometry bell;
    1.17  	private Geometry ear1;
    1.18  	private Geometry ear2;
    1.19 @@ -66,7 +64,6 @@
    1.20  	private MotionTrack motionControl;
    1.21  		
    1.22  	public static void main(String[] args) {
    1.23 -		//Logger.getLogger("com.jme3").setLevel(Level.OFF); 
    1.24  		Advanced app = new Advanced();
    1.25  		AppSettings settings = new AppSettings(true);
    1.26  		settings.setAudioRenderer(AurellemSystemDelegate.SEND);
     2.1 --- a/src/com/aurellem/capture/examples/HelloAudioRecording.java	Sat Dec 03 13:22:27 2011 -0600
     2.2 +++ b/src/com/aurellem/capture/examples/HelloAudioRecording.java	Sat Dec 03 13:35:13 2011 -0600
     2.3 @@ -9,6 +9,22 @@
     2.4  import com.aurellem.capture.IsoTimer;
     2.5  import com.jme3.app.Application;
     2.6  
     2.7 +/** Recording audio from your Application is simple.  If all you 
     2.8 + *  want to do is record Audio, then follow the following steps.
     2.9 + * 
    2.10 + *  1.) Set the Application's timer to an IsoTimer.  The framerate is
    2.11 + *  irrelevant for sound, but must evenly divide 44,100Hz, which is the
    2.12 + *  frequency at which sound will be recorded.  For example
    2.13 + *  IsoTimer(60) is ok, but IsoTimer(61) is not.
    2.14 + * 
    2.15 + *  2.) Call Capture.captureAudio(yourApplication, target-file) before
    2.16 + *  calling yourApplication.start()
    2.17 + *  
    2.18 + *  That's it!  If you have any comments/problems, please PM me on the
    2.19 + *  jMonkeyEngine forms.  My username is bortreb.
    2.20 + * 
    2.21 + * @author Robert McIntyre
    2.22 + */
    2.23  public class HelloAudioRecording {
    2.24  
    2.25  	public static void main(String[] ignore) throws IOException{
    2.26 @@ -19,5 +35,4 @@
    2.27  		app.start();
    2.28  		System.out.println(audio.getCanonicalPath());		
    2.29  	}
    2.30 -	
    2.31  }
     3.1 --- a/src/com/aurellem/capture/examples/HelloVideoRecording.java	Sat Dec 03 13:22:27 2011 -0600
     3.2 +++ b/src/com/aurellem/capture/examples/HelloVideoRecording.java	Sat Dec 03 13:35:13 2011 -0600
     3.3 @@ -9,6 +9,22 @@
     3.4  import com.aurellem.capture.IsoTimer;
     3.5  import com.jme3.app.Application;
     3.6  
     3.7 +/** Recording Video from your Application is simple.  If all you
     3.8 + *  want to do is record Video, then follow the following steps.
     3.9 + * 
    3.10 + *  1.) Set the Application's timer to an IsoTimer.  The framerate of
    3.11 + *  the IsoTimer will determine the framerate of the resulting video.
    3.12 + * 
    3.13 + *
    3.14 + * 
    3.15 + *  2.) Call Capture.captureVideo(yourApplication, target-file) before
    3.16 + *  calling yourApplication.start()
    3.17 + *  
    3.18 + *  That's it!  If you have any comments/problems, please PM me on the
    3.19 + *  jMonkeyEngine forms.  My username is bortreb.
    3.20 + * 
    3.21 + * @author Robert McIntyre
    3.22 + */
    3.23  public class HelloVideoRecording {
    3.24  
    3.25  	public static void main(String[] ignore) throws IOException {