AnimationManifest

References
public sealed class AnimationManifest
The record an animation leaves in its output folder. It exists so an interrupted animation can be picked up where it left off, so a resumed animation can tell whether the frames already on disk belong to the same setup, and so a folder full of numbered images can say what it is and where it came from.

A manifest is derived data, not part of the document. It lives with the images it describes, which is what keeps an unrelated edit to the definition from invalidating a half finished render.

Fields

FileName

#
public const string FileName = "_animation.txt"
File name of the manifest inside an output folder.

Properties

Completed

#
public DateTime? Completed { get; }
Gets the moment the animation stopped, or null while it is still running or if it was interrupted before it could record one.

Cyclic

#
public bool Cyclic { get; }
Gets whether the animation is meant to be played as a loop.

Duration

#
public TimeSpan Duration { get; }
Gets how long the run took.

Failed

#
public int Failed { get; }
Gets the number of frames the last run could not write.

Fingerprint

#
public string Fingerprint { get; }
Gets the fingerprint of every setting which affects the written images.

FrameCount

#
public int FrameCount { get; }
Gets the number of frames the animation was supposed to write.

Id

#
public string Id { get; }
Gets the id of the animation which wrote this manifest.

IsComplete

#
public bool IsComplete { get; }
Gets whether the animation ran to the end and left no gaps behind.

Name

#
public string Name { get; }
Gets the name the animation had when it last ran.

Skipped

#
public int Skipped { get; }
Gets the number of frames the last run found already on disk.

Started

#
public DateTime Started { get; }
Gets the moment the animation started.

Written

#
public int Written { get; }
Gets the number of frames written by the last run.

Methods

Create

#
public static AnimationManifest Create(Animation animation)
Create a manifest describing an animation about to run.
animation (Animation)

Matches

#
public bool Matches(Animation animation)
Gets whether this manifest describes the same images the given animation would write now.
animation (Animation)

Read

#
public static AnimationManifest Read(string folder)
Read the manifest in a folder, if there is one.
folder (string)
The manifest, or null if the folder has none or it cannot be read.

Record

#
public void Record(AnimationReport report)
Record the outcome of a run on this manifest, so the next one can tell a finished animation from an interrupted one.
report (AnimationReport)

Write

#
public bool Write(string folder, string template = null)
Write this manifest into a folder, replacing any manifest already there. Failure to write a manifest is not fatal; it only costs the ability to resume.
folder (string)Folder to write into.
template (string = null)File name template of the images in this folder, shown to whoever opens the file. Optional.