wiki:CommandLine

Version 1 (modified by leo, 10 years ago) (diff)

--

Command Line options

Below is a summary of all of the options that LeoCAD accepts. Most options have two equivalent names, one of which is a single letter preceded by -, and the other of which is a long name preceded by --. Brackets ([ and ]) indicate that an option takes an optional argument.

  • infile

Loads the project file infile.

  • -i [ outfile.ext ]
  • --image [ outfile.ext ]

Saves a picture to outfile.ext in the image format specified by ext and exits. If outfile is not given then the program will use a file name based on infile. The file format is selected by ext and can be one of gif, bmp, png or jpg (if ext is not present then the default preferences format will be used).

  • -w width
  • --width width

Sets the width of the picture to width.

  • -h height
  • --height height

Sets the height of the picture to height.

  • -f time
  • --from time

Start saving pictures at the step or frame time.

  • -t time
  • --to time

Save pictures until the step or frame time.

  • --animation

Tells the program to save animations instead of instructions.

  • --instructions

Tells the program to save instructions instead of animations (default).

  • --highlight

Adds a border around the pieces in the step or frame where they first appear when saving pictures.

  • -l path
  • --libpath path

Load the pieces library from path.

  • --libgl library

Sets the name of the OpenGL dynamic library used by the program to library.

Examples

  • leocad car.lcd -i car.png -w 640 -h 480

This will start LeoCAD, load the file "car.lcd," create a png called "car.png" with a resolution of 640x480 and exit when done.