AnimationToPNG

Author Brad Nelson (playemgames) based on scripts from Twinfox and bitbutter's Render Particle to Animated Texture Scripts from the Unity3D forums.

Description
AnimationToPNG is based on Twinfox and bitbutter's Render Particle to Animated Texture Scripts, this script will render out an animation that is played when "Play" is pressed in the editor to a series of PNG image files in a directory of your choosing.

Usage
Basically this is a script you can attach to any gameobject in the scene.

If you have Unity Pro, you can use Render Textures, which can accurately render the transparent background for your animations easily in full resolution of the camera. The script will autodetect if you have Unity Pro and use Render Textures automatically. If you are using Unity Free, then the screen will have a split area using half of the screen width to render the animations.

You can change the "animationName" to a string of your choice for a prefix for the output file names, if it is left empty then no filename will be added.

The destination folder is relative to the Project Folder root, so you can change the string to a folder name of your choice and it will be created. If it already exists, it will simply create a new folder with a number incremented as to how many of those named folders exist.

Choose how many frames per second the animation will run by changing the "frameRate" variable, and how many frames of the animation you wish to capture by changing the "framesToCapture" variable.

Once "Play" is pressed in the Unity Editor, it should output all the animation frames to PNGs output in the folder you have chosen, and will stop capturing after the number of frames you wish to capture is completed.

Use with Unity Free and Pro. This file and page can be edited and improved to suit the community better. Free for non-commercial and commercial use.