Cavalry
  • Welcome
  • Getting Started
    • Requirements
    • Installation
    • Sign In
      • Proxy Server
    • Quick Start
    • Example Files
    • Key Concepts
      • Nodes
      • Connections
      • Context
  • User Interface
    • Menus
      • File menu
      • Edit menu
      • View menu
      • Composition menu
      • Create menu
      • Animation menu
      • Shape menu
      • Tool menu
        • Select tool
        • Edit Shape tool
        • Pen tool
        • Pencil tool
        • Line tool
        • Text tool
        • Rectangle tool
        • Ellipse tool
        • Polygon tool
        • Star tool
        • Arc tool
        • Super Ellipse tool
        • Cog tool
        • Arrow tool
        • Capsule tool
      • Window menu
        • Align Window
        • Animation Utilities
        • Assets Window
          • Google Sheets Asset
          • Image Sequences
          • Project Settings
        • Attribute Editor
          • Control Rows
            • Controls Rows - Types
            • Control Rows - Interaction
        • Color window
          • Palettes
        • Control Center
        • Quick Add window
        • Flow Graph
        • Glyph Browser
        • Playback Controls
        • Preferences
        • Render Manager
          • Lottie Export
          • Dynamic Rendering
          • Render Tokens
        • Scene Window
          • Scene Tree
            • Composition Settings
          • Time Editor
          • Graph Editor
          • Keyframe Layers
        • Shelf
        • Tags
        • Toolbar
        • Viewport
          • Rulers
      • Help menu
    • Widgets
      • Gradient
      • Graph Attribute
    • General
      • Aliasing
      • Blend Modes
      • Distribution Types
        • Array Distribution
        • Circle Distribution
        • Fibonacci Distribution
        • Grid Distribution
        • Linear Distribution
        • Mask Distribution
        • Math Distribution
        • Path Distribution
        • Point Distribution
        • Random Distribution
        • Rose Distribution
        • Shape Edges Distribution
        • Shape Points Distribution
        • Shuffle Distribution
        • Sub-Mesh Distribution
        • Voxelize Distribution
      • Color Management
      • Motion Blur
      • Vector artwork support
  • Nodes
    • Shapes
      • Common Attributes (Shapes)
      • Background Shape
      • Basic Line
        • Bézier
        • Line
        • Spiral
      • Basic Shape
        • Arc
        • Arrow
        • Capsule
        • Cogwheel
        • Ellipse
        • Polygon
        • Rectangle
        • Ring
        • Star
        • Super Ellipse
      • Cel Animation Shape
      • Composition
      • Connect Shape
      • Convex Hull
      • Custom Shape
      • Duplicator
      • Editable Shape
      • Footage Shape
      • Group
      • Image to Shapes
      • Layout Shape
        • Grid Layout
        • Horizontal Layout
        • Vertical Layout
      • Outline
      • Points to Curve
      • Quad Tree Shape
      • Rectangle Pattern
      • SVG
      • Spacer
      • Sub-Mesh Bounding Box
      • Text Shape
      • Trails
    • Behaviours
      • Common Attributes (Behaviours)
      • 3D Matrix
      • Add Divisions
      • Align
      • Alpha Material Override
      • Apply Distribution
      • Apply Layout
      • Behaviour Mixer
      • Bevel
      • Blend Shape
      • Blend Sub-Mesh Positions
      • Boolean
      • Clean Up
      • Color Blend
      • Color Material Override
      • Curve to Lines
      • Distance
      • Fill Rule
      • Flare
      • Flatten Shape Layers
      • Frame
      • Get Vector
      • HSV Material Overide
      • Is Within
      • Look At
      • Manipulator
      • Material Sampler
      • Modulate
      • Morph
      • Noise
      • Number Range
      • Number Range to Color
      • Oscillator
      • Path Offset
      • Pathfinder
      • Pinch
      • Position Blend
      • Push Along Vector
      • Random
      • Resample Path
      • Round
      • Rubber Hose Limb
      • Simple Value Solver
      • Simple Value2 Solver
      • Skew
      • Sound
      • Split Path
      • Spring
      • Squetch
      • Stagger
      • Sub-Mesh
      • Subdivide
      • Swap Color Override
      • Value
      • Value 2
      • Value Blend
      • Value2 Blend
      • Visibility Sequence
      • Voxelize
    • Utilities
      • Animation Control
      • Apply Font Size
      • Array Manipulator
      • Asset Array
      • Bounding Box
      • Bounding Box Constraint
      • Color Array
      • Color Info
      • Composition Constraint
      • Component Constraint
      • Context Index
      • Falloff
      • Get Name
      • HSV Color
      • If Else
      • Index to Color
      • JS Math
      • Length Context
      • Local Time
      • Math
      • Math2
      • Math 3
      • Measure
      • Mesh Array
      • Null
      • Path Length
      • Regex
      • Rig Control
      • Sequence
      • Shader Array
      • Spreadsheet
      • Spreadsheet Lookup
      • String
      • String Array
      • String Generator
        • Formatted String Generator
        • Hash Generator
        • Hexadecimal Generator
        • Random Date Generator
        • Random Number Generator
        • Timecode Generator
        • Value Generator
      • String Length
      • String Manipulator
        • Change String Case Manipulator
        • Join String Manipulator
        • Replace String Manipulator
        • Regex String Manipulator
        • Resize String Manipulator
        • Shuffle String Manipulator
        • Sub-String Manipulator
        • Transition String Maniplulator
      • Transform Constraint
      • Typeface
      • Typeface Array
      • Value Array
      • Value 2 Array
      • Value 2 Array
      • Velocity Context
      • Velocity Magnitude Context
    • Effects
      • Blur
      • Color Shader
      • Drop Shadow
      • Fill
      • Gradient Shader
      • Image Shader
      • Invert
      • Levels
      • Linear Wipe
      • Mask Blur
      • Noise Shader
      • Radial Wipe
      • SkSL Shader
      • Shape to Shader
      • Tri Tone
      • Venetian Blinds
  • Tips
    • Shortcuts
  • Applications
    • Cavalry Player
    • Cavalry CLI
  • Technical Information
    • Licencing
    • Logs
    • Mathematical Expressions
    • Release Notes
      • 1.1.1 Release Notes
      • 1.1 Release Notes
      • 1.0.3 Release Notes
      • 1.0.2 Release Notes
      • 1.0.1 Release Notes
    • User Preferences
Powered by GitBook
On this page
  • General
  • Render
  • Version
  • Auth
  • Proxy
  • List
  • Glossary

Was this helpful?

  1. Applications

Cavalry CLI

Command Line Interface

General

Cavalry CLI (Command Line Interface) enables various tasks including rendering without the need to launch Cavalry itself.

To run (assuming you have installed Cavalry to the default locations):

macOS

  • Open Terminal (Applications/Utilities/Terminal).

  • Enter the following (hit enter after the first line).

$ cd /Applications/Cavalry.app/Contents/Applications/CavalryCLI.app/Contents/MacOS/
$ ./cavalry-cli [your command here]

Windows

  • Open Command Prompt.

  • Enter the following (hit enter after the first line)

> cd C:\Program Files\Cavalry
> .\cavalry-cli [your command here]

Typing ./cavalry-cli -h (macOS) or .\cavalry-cli -h (Windows) followed by enter will output the following help information:

Command Line Interface
Usage: Cavalry CLI [OPTIONS] [SUBCOMMAND]

  -h,--help                   Print this help message and exit

Subcommands:
  render                      Render a scene
  version                     Version information
  auth                        Authenticate (Password may be piped or entered when prompted)
  proxy                       Set proxy settings
  list                        List additional information

Render

Rendering via CLI is only available on the Professional plan.

Typing ./cavalry-cli render -h (macOS) or .\cavalry-cli render -h (Windows) followed by enter will output the following help information:

Render a scene
Usage: Cavalry CLI render [OPTIONS] scene

  scene TEXT REQUIRED         The full path to the Scene file.

  -h,--help                   Print this help message and exit
  -p,--padding INT            Frame number padding.
  -f,--frame INT              A single frame to render. If set, startFrame and endFrame will be ignored.
  -s,--startFrame INT         The first frame of a range to render.
  -e,--endFrame INT           The last frame of a range to render.
  -n,--name TEXT              The filename prefix.
  -d,--directory TEXT         The output directory.
  --backend TEXT              The rendering backend. Options: opengl (default), raster.
  --scale FLOAT               The Resolution Scale (unit: percent).
  --composition TEXT          The ID of the composition to render. See the 'list' command for more info.
  --render-item TEXT          The ID of the render item to render. See the 'list' command for more info. Note: All other options will be ignored.
  --dynamicCount INT          The number of Dynamic Renders to perform.
  --dynamicRange INT x 2      Set an inclusive range of Dynamic Renders to perform [start end].
[format]
  Rendering format
    --format TEXT               Sets the output format. Options: png (default), jpeg, svg, gif, apng, prores
  [PNG]
      --compression INT           Compression (0 to 9)
      --filter INT                Filter (1, 2 or 3)
  [JPEG]
      --quality INT               Quality (0 to 100)
  [ProRes]
      --codec TEXT                422HQ, 422, 422LT, 422Proxy, 4444, 4444XQ

You can then use these flags to create your command.

For example, the below will render frames 0-50 of the file sceneName.cv as an animated png with the name outputFileName to your Desktop.

macOS

./cavalry-cli render ~/Desktop/sceneName.cv -n outputFilename -d ~/Desktop/ -s 0 -e 50 --format apng

Windows

.\cavalry-cli render C:\Users\Username\Desktop\sceneName.cv -n outputfilename -d C:\Users\Username\Desktop\ -s 0 -e 50 --format apng

Render Tokens

To use Render Tokens to generate a File Name (-n) with in a command wrap them in single or double quotes. For example the following examples will both work:

-n '<Composition>_Name'
-n "Name_<Resolution>"

Version

To check the version of Cavalry you currently have installed you can run the version command.

Typing ./cavalry-cli version -h (macOS) or .\cavalry-cli version -h (Windows) will output the following help information.

Version information
Usage: Cavalry CLI version [OPTIONS]

  -h,--help                   Print this help message and exit

macOS

./cavalry-cli version

Windows

.\cavalry-cli version

Will return the version of Cavalry installed.

[11:30:29.657 info    ] App Version: 0.15

Auth

You'll need to authenticate in order to use CLI to render. If you have used the main Cavalry application with a Professional licence recently then you will already be authenticated but in the event that you haven't, you can use the auth command to do so.

Typing ./cavalry-cli auth -h (macOS) or .\cavalry-cli auth -h (Windows) followed by enter will output the following help information:

Authenticate (Password may be piped or entered when prompted)
Usage: Cavalry CLI auth [OPTIONS] email

  email TEXT REQUIRED         Email Address

For example, the below will sign in using your email address (the one you use to sign in to Cavalry):

./cavalry-cli auth name@email.com

You will then be asked to enter your password.

Once authenticated, any Render commands will run .

Proxy

Set proxy settings 
[At least 1 of the following options are required]
Usage: Cavalry CLI proxy [OPTIONS]

  -h,--help                   Print this help message and exit
  --address TEXT Excludes: --reset
                              Server Address
  --username TEXT Needs: --address Excludes: --reset
                              Username (Password may be piped or entered when prompted)
  --reset Excludes: --address --username
                              Reset proxy settings

List

Only available on the Professional plan.

You can list additional information about your scene like the Composition and Render Queue item Ids. These can be added to the render command as flags. Typing ./cavalry-cli list -h (macOS) or .\cavalry-cli list -h (Windows) followed by enter will output the following help information:

List additional information
Usage: Cavalry CLI list [OPTIONS] [scene]

  scene TEXT                  The full path to the scene file.

  -h,--help                   Print this help message and exit
  --compositions Needs: scene List all compositions
  --render-items Needs: scene List all render items

For example, the below will output information about all the compositions in that scene.

macOS

./cavalry-cli list ~/Desktop/sceneName.cv --compositions

Windows

.\cavalry-cli list C:\Users\Username\Desktop\sceneName.cv --compositions

Hitting enter will return a list of the compositions in your scene and their IDs.

[11:17:43.468 info    ] Relinked asset: asset#2
[11:17:43.471 info    ] Composition ID                Composition Name              
[11:17:43.471 info    ] compNode#1                    Composition 1                 
[11:17:43.471 info    ] 
[11:17:43.471 debug   ] Saving preferences

The Composition ID can then be used with the --composition flag as part of a render command. For example, if you wanted to render Composition 1 you would add --composition compNode#1 to the render command.

Glossary

INT - an integer is a number without a decimal point. e.g. 4

INT x 2 - a set of two integers to define a range. e.g. 4 8 (4[space]8)

FLOAT - a float is a number that has a decimal place. e.g. 23.5

TEXT - a text string that can include letters, numbers, special characters, the dash symbol, or the number sign. e.g. sceneName-01

PreviousCavalry PlayerNextLicencing

Last updated 4 years ago

Was this helpful?

If your file was saved with a Project set, if you don't set a -d (directory) any output will be saved in the Renders directory defined in the .

settings can be entered/updated using the proxy command. Typing ./cavalry-cli proxy -h (macOS) or .\cavalry-cli proxy -h (Windows) followed by enter will output the following help information:

Project Settings
Proxy Server