ArtiSynth User Interface Guide

11 Making Movies

ArtiSynth includes a panel to aid in capturing simulations as movies. This panel is opened from the main viewer window by navigating through View > Show movie panel. When capturing a movie, pictures are saved to ARTISYNTH_HOME/tmp periodically as frameXXXXX.ext, where XXXXX represents the sequential number of the frame (with each X representing a digit), and the .ext represents the file extension (determined by the Frame File selection in the encoder panel). Because the frame files aren’t unique, recordings will overwrite frames from prior movies, and if Remove temporary files is selected, only the final products are left. When the recording is stopped, these pictures are then compressed into a movie file using either mencoder, or an internal algorithm. The resulting movie is saved to the $ARTISYNTH_HOME/tmp with the file name specified at the bottom of the recorder panel.

Figure 31: Movie options panel (recorder tab).
Figure 32: Movie options panel (encoder tab).

11.1 Region to capture options

These options define the area of the desktop recorded. The default capture area is the main viewer of ArtiSynth. Viewer sets the capture area exclusively and strictly to the main viewer, and excludes the toolbar and window. This is useful for recording model demonstrations. The Window option includes the main viewer and the toolbar and window surrounding it. The Custom option allows the user to manually set the coordinates, width and height of the region to capture through the given fields. It also displays the capture frame, which can be stretched and moved to adjust what is recorded.

When the Viewer mode is selected, there are additional options available in the Output Size section. This allows you to create higher (or lower) resolution videos, independent of the viewer’s visible resolution. The # samples specifies the size of the multi-sample buffer, which is used for anti-aliasing. This is the only mode that continues to work correctly when a screen-saver is activated.

11.2 Record options

These options determine how the movie recorder works with ArtiSynth, and how it deals with the frame files.

Begin playing on start

When the start button is clicked, the simulation will begin to run.

End playing on stop

When the stop button is clicked, the simulation stops running.

Automatic frame capture

Frames are automatically captured according to the movie’s frame-rate while the model is run. If this is disabled, it is up to the user to click on the Frame button to capture the next frame.

Remove temporary files

When selected, the temporary frames are deleted after the movie is made.

Save first image

This saves the first frame taken. These frames are useful for representing the movie in websites.

Show capture frame

Opens a transparent window that reveals what will be captured. The window is stretchable and movable when the capture option is set to Custom and provides a method to graphically modify the capture area’s X coordinate, Y coordinate, width, and height.

11.3 Output options

These options control the frequency of the frames and how they are combined into a movie.

Frame rate

This is the number of frames recorded per second of movie.

Speed

This is the ratio of the movie’s speed to reality’s speed. While the demo is recording, the calculations may slow down the simulation, but the movie will not be affected.

Important:
If the Frame Rate or Speed is set so that the increments between the frames is smaller than the calculation steps used in the, then ArtiSynth will decrease the calculation increments in order to capture the frames, slowing the simulation.

Frame File

This is the format the frames will be stored in. If the internal method (see below) is used, then the frames must be stored as jpegs.

Method

This is the algorithm used to compress the temporary pictures into a movie.

  • internal Use ArtiSynth’s built in algorithm to compress the pictures into an animated jpeg.

  • mencoder Use Mencoder to compress pictures into a divx movie (can be played on MediaPlayer with a plugin).

  • mencoder_osx This option is specific for use on MacOS.

  • ffmpeg Use the FFMPEG command-line utility to generate the movie.

  • animated_gif Uses an algorithm built into ArtiSynth to generate an animated gif. By hitting the Customize Method button, you can set the number of times to loop (-1 for infinity) and the frame rate (defaults to capture frame rate).

  • avconv Uses the avconv utility that has replaced FFMPEG on some linux systems to generate the movie.

The customize button right of the method box opens a window where the specific command calling mencoder can be edited. The variables identified with the ’$’ are the input parameters for the mencoder, and are based on information provided to the movie panel.

$FMT

Controls the format of the frames. Modifying this is the same as changing Frame File.

$OUT

The name of the output file. Modifying this is the same as changing the name field.

$FPS

Determines the frame rate mencoder uses when it compiles the movie. By default, this is the same as the Frame Rate option.

11.4 Output size options

These options are only used when the capture area is set to Viewer and control the size of the output video, allowing the contents of the viewer to be magnified.

Same to original size

The output video is created at the original size.

Constrain proportions

The output video is created with constrained proportions, such that the ratio between height and width are maintained.

Width

Defines the width of the output video.

Height

Defines the height of the output video.

# samples

Sets the number of samples to use for the multi-sample buffer. This only applies in Viewer mode, and is used to perform anti-aliasing.

Note: If your movie comes out black or only shows a section of the viewer correctly in Viewer mode, then it is likely your graphics card does not support multi-sample buffers. On machines with multiple graphics cards (e.g. laptops with both discrete and integrated graphics), make sure the java process is set to use the discrete card. Otherwise, set # samples = 1 to disable the multi-sample buffer.