The JSON Structure

<< Click to Display Table of Contents >>

Navigation:  Appendix: JSON Scripting Directly >

The JSON Structure

The Top Level structure handles timeline objects and which timeline from which to read (tlToEdit property). The reason Delta only builds one timeline at a time is so that new timelines can be created while another is playing, without interrupting the playback.

Each timeline object has a Config object and a Clips array. You should only really need to change clipCount (length of clips array). This can contain any number of clip objects, each of which gives details about a single piece of media to add to the timeline.

The main properties to change are MediaType, Length, and Name. The ID and Type properties are also important.

ID is used to name clips within Delta

Type distinguishes between Movie and Image resources so that the script will look for resource names in either the \Movies or \Images folders.

Top Level Structure

json-top-level

At this level, there should only be timeline objects and the "tlToEdit" field.

Add a timeline object in the format of "tl-x": {} for every timeline you want to create.

The "tlToEdit" field specifies which timeline object from the JSON to load into the show.

Config Structure

json-config

ClipCount
Should match the number of clips in the "Clips" array.

StartFrame
The frame on which to start placing the first clip in the Clips array.

Timeline
Should match the number of the outer object, e.g. for tl-1 this must be 1.

KeepDisplayConfig
Set to 1 to keep the current display config, set to 0 to overwrite the current display config.

Layer
The layer on the timeline on which to place the clips.

Channel
(Not used.)

Merge
Set to 1 if you have a base file you want to merge the express layer into, rather than completely overwriting the existing file.

ClearExpressLayer
(If "Merge" is set to 1)

0: Load in clips from this file without clearing the current Express layer.

1: Clear the current express layer before loading in the new clips.

Dirty
Set to 1 if "Merge" is 1 and the clips in this file have changed since Delta last processed this file, otherwise set to 0.

JSONFileVersion
Should always be 1.

Clips Structure

For each array added here, use a unique ID and increment the ClipCount property under Config. Creating a show with this method will result in all clips being placed sequentially on the timeline with no gaps between them.

json-clips

ID
Used to uniquely name the clip on the timeline. Will be formatted as "Clip_{ID}" : {Name}. Common practice is to make the ID sequential, starting at x000 where x is the timeline number.

Type
The type of resource. Can be "Movie"”, "Image", or "Capture".

MediaType
Needs to match the file extension of the media; e.g. "tga", "mp4", "jpg". If "Type" is "Capture" then leave this blank ("").

Length
The length in frames of the resource (or set to "Full" to use the full length of the resource). For movie resources, if this does not match the number of frames in the movie, it will be trimmed or looped to meet this value.

Name
The name of the resource on disk (excluding the extension). If on a movie resource, looks in "C:\Movies", if on an image resource, looks in "C:\Images", if on a capture resource this should be the name of the capture device, e.g. "Integrated Webcam :ID 10000".

InPoint
Trim a movie resource to start from a specified frame. Must be between 0 and the total number of frames in the movie and always less than Outpoint.

OutPoint
Trim a movie resource to end on a specified frame. Must be between 0 and the total number of frames in the movie and always greater than InPoint. Set to "end" to not trim the movie.

(Ensure "LengthMode" is set to the correct value when using "Length" vs "InPoint"/"OutPoint".

CrossFade
Leave as 0.

PlayMode
"PlayOnce": This clip will play once then move on to the next clip.

"PlayCount": This clip will play the amount of times specified in "PlayModeDetails" before moving on to the next clip.

PlayModeDetails
The amount of times to loop this clip (only if "PlayMode" is "PlayCount").

Size
Leave as "FullScreen".

FadeMode
"None": No transition between clips.

"Transparent": A fade in/out is applied to the clip with a length specified in "FadeModeLength" (seconds).

FadeModeDetails
Always "both".

FadeModeLength
Time in seconds to fade in/out of resource (if "FadeMode" is "Transparent".

PlaySpeed
Sets the play speed of a movie resource. Doesn’t affect the length of the resource on the timeline.

DisableCodecAudio
Only used for Codec Movie resources. If set to 1 then the movie’s audio will be disabled.

MatchAudio
Search for any audio files which contain the same resource name as the movie and add them to the timeline at the same frame as the movie and 4 layers lower.

EndTransition
"Play" – continue playing after this clip.

"Stop" – stop playback after this clip.

StopType
"EndTransition" must be "Stop" for this to have any effect.

"Last": Stop at the end of this clip

"First": Stop at the beginning of the next clip

Actions
Place Delta sequences on the timeline

json-actions

id

Sequential action ID

frame

The RESOURCE frame number on which to place the sequence

tlFrame

The TIMELINE frame number on which to place the sequence

action

The name of the sequence to add to the timeline

valid

Set to "true"

LengthMode
"length" – Use the "Length" field to determine the length of the resource.

"in/out" – Use the "InPoint" and "OutPoint" fields to determine the length of the resource.

Page edited [d/m/y]: 21/09/2021