Render from command line

Blender 2.63a

You can render a scene without opening the blender interface from command line

in windows – cmd
in linux or mac – terminal

Provided everything is set and ready to be rendered, to render animation type in command

blender -b filename.blend -a

For more advance options, you can use python script to change some settings in the blend file before render.

Create an empty text file with your favorite text editor (or in blender). Copy & paste these example settings.

import bpy

#change scene name to yours
Scenename = 'Scene'

# quality[Scenename].render.resolution_x = 2048[Scenename].render.resolution_y = 1080[Scenename].render.resolution_percentage = 50[Scenename].render.use_antialiasing = True[Scenename].render.use_full_sample = True

# frame range[Scenename].frame_start = 1[Scenename].frame_end = 5

# image format[Scenename].render.image_settings.file_format = 'TIFF'[Scenename].render.image_settings.quality = 80[Scenename].render.image_settings.color_mode = 'RGBA'

# Cycles sampling[Scenename].cycles.samples = 200

# stamp[Scenename].render.use_stamp = 1[Scenename].render.stamp_background = (0,0,0,1)

# output[Scenename].render.filepath = '//render/test_'[Scenename].render.use_placeholder = True[Scenename].render.use_overwrite = False

# start render animation

The important lines are the first and the last. Other lines can be changed to fit your need. The properties names are quite self-explained. The # sign is for comment line, will be ignored by the interpreter. You can hover the mouse over any boxes or buttons in Blender to see the script associated.

More details can be found at blender python api reference :


Save the text as ‘’. You might put it in the same folder as the blend file for convenient.

To start render from command line, type

blender -b filename.blend -P




Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / เปลี่ยนแปลง )

Twitter picture

You are commenting using your Twitter account. Log Out / เปลี่ยนแปลง )

Facebook photo

You are commenting using your Facebook account. Log Out / เปลี่ยนแปลง )

Google+ photo

You are commenting using your Google+ account. Log Out / เปลี่ยนแปลง )

Connecting to %s