Video switching commands

Program / Preview bus

class pyatem.command.ProgramInputCommand(index, source)

Implementation of the CPgI command. This is equivalent to pressing the buttons on the program bus on a control panel.

Offset

Size

Type

Description

0

1

u8

M/E index

1

1

?

unknown

2

2

u16

Source index

__init__(index, source)
Parameters
  • index – 0-indexed M/E number to control the program bus of

  • source – Source index to activate on the program bus

class pyatem.command.PreviewInputCommand(index, source)

Implementation of the CPvI command. This is equivalent to pressing the buttons on the preview bus on a control panel.

Offset

Size

Type

Description

0

1

u8

M/E index

1

1

?

unknown

2

2

u16

Source index

__init__(index, source)
Parameters
  • index – 0-indexed M/E number to control the preview bus of

  • source – Source index to activate on the preview bus

Transitions

class pyatem.command.CutCommand(index)

Implementation of the DCut command. This is equivalent to pressing the CUT button in the UI

Offset

Size

Type

Description

0

1

u8

M/E index

1

3

?

unknown

__init__(index)
Parameters

index – 0-indexed M/E number to send the CUT to

class pyatem.command.AutoCommand(index)

Implementation of the DAut command. This is equivalent to pressing the CUT button in the UI

Offset

Size

Type

Description

0

1

u8

M/E index

1

3

?

unknown

__init__(index)
Parameters

index – 0-indexed M/E number to send the AUTO transition to

class pyatem.command.TransitionPreviewCommand(index, enabled)

Implementation of the CTPr command. This sets the state of the Transition Preview function of the mixer

Offset

Size

Type

Description

0

1

u8

M/E index

1

1

bool

Preview enabled

2

2

?

unknown

__init__(index, enabled)
Parameters
  • index – 0-indexed M/E number to control the preview bus of

  • enabled – New state of the preview function

class pyatem.command.TransitionSettingsCommand(index, style=None, next_transition=None)

Implementation of the CTTp command. This is equivalent to pressing the buttons on the preview bus on a control panel.

Offset

Size

Type

Description

0

1

u8

Mask, bit0=set style, bit1=set next transition

1

1

u8

M/E index

2

1

u8

Style

3

1

u8

Next transition

__init__(index, style=None, next_transition=None)
Parameters
  • index – 0-indexed M/E number to control the preview bus of

  • style – Set new transition style, or None

  • style – Set next transition layers, or None

Transition settings

class pyatem.command.MixSettingsCommand(index, rate)

Implementation of the CTMx command. This sets the transition duration for the mix transition panel.

Offset

Size

Type

Description

0

1

u8

M/E index, 0-indexed

1

1

u8

Rate in frames

2

2

?

unknown

__init__(index, rate)
Parameters
  • index – 0-indexed DSK number to trigger

  • rate – Transition length in frames

class pyatem.command.DipSettingsCommand(index, rate=None, source=None)

Implementation of the CTDp command. This sets the settings for the dip transition panel.

Offset

Size

Type

Description

0

1

u8

Mask, bit0=set rate, bit1=set source

1

1

u8

M/E index

2

1

u8

Rate in frames

3

1

?

unknown

4

2

u16

Source index

6

2

?

unknown

__init__(index, rate=None, source=None)
Parameters
  • index – 0-indexed M/E number to control the preview bus of

  • rate – Set new transition rate, or None

  • source – Set the dip source, or None

class pyatem.command.WipeSettingsCommand(index, rate=None, pattern=None, width=None, source=None, symmetry=None, softness=None, positionx=None, positiony=None, reverse=None, flipflop=None)

Implementation of the CTWp command. This sets the settings for the wipe transition panel.

Offset

Size

Type

Description

0

2

u16

Mask, see table below

2

1

u8

M/E index

3

1

u8

Rate in frames

4

1

u8

Pattern style [0-17]

5

1

?

unknown

6

2

u16

Border width [0-10000]

8

2

u16

Border fill source

10

2

u16

Symmetry [0-10000]

12

2

u16

Softness [0-10000]

14

2

16

Transition origin x [0-10000]

16

2

16

Transition origin y [0-10000]

18

1

bool

Reverse

19

1

bool

Flip flop

Bit

Mask value

0

Rate

1

Pattern

2

Border width

3

Border fill source

4

Symmetry

5

Softness

6

Position x

7

Position y

8

Reverse

9

Flip flop

__init__(index, rate=None, pattern=None, width=None, source=None, symmetry=None, softness=None, positionx=None, positiony=None, reverse=None, flipflop=None)
Parameters
  • index – 0-indexed M/E number to control the preview bus of

  • rate – Set new transition rate, or None

  • pattern – Set transition pattern id, or None

  • width – Set transition border width, or None

  • source – Set transition border fill source index, or None

  • symmetry – Set transition symmetry, or None

  • softness – Set transition softness, or None

  • positionx – Set transition origin x, or None

  • positiony – Set transition origin y, or None

  • reverse – Set the reverse flag for the transition, or None

  • flipflop – Set the flipflop flag for the transition, or None

class pyatem.command.DveSettingsCommand(index, rate=None, style=None, fill_source=None, key_source=None, key_enable=None, key_premultiplied=None, key_clip=None, key_gain=None, key_invert=None, reverse=None, flipflop=None)

Implementation of the CTDv command. This sets the settings for the DVE transition panel.

Offset

Size

Type

Description

0

2

u16

Mask, see table below

2

1

u8

M/E index

3

1

u8

Rate in frames

4

1

u8

Pattern style [0-17]

5

1

?

unknown

6

2

u16

Fill source index

8

2

u16

Key source index

10

1

bool

Enable key

11

1

bool

Key is premultiplied

12

2

u16

Key clip [0-1000]

14

2

u16

Key gain [0-1000]

16

1

bool

Invert key

17

1

bool

Reverse transition direction

18

1

bool

Enable flip-flop

19

1

?

unknown

Bit

Mask value

0

Rate

1

?

2

Style

3

Fill source

4

Key source

5

Enable key

6

Key is premultiplied

7

Key clip

8

Key gain

9

Invert key

10

Reverse

11

Flip-flop

__init__(index, rate=None, style=None, fill_source=None, key_source=None, key_enable=None, key_premultiplied=None, key_clip=None, key_gain=None, key_invert=None, reverse=None, flipflop=None)
Parameters
  • index – 0-indexed M/E number to control the preview bus of

  • rate – Set new transition rate, or None

  • style – Set new transition style, or None

  • fill_source – Set new fill source, or None

  • key_source – Set new key source, or None

  • key_enable – Enable the keyer, or None

  • key_premultiplied – Key is premultiplied alpha, or None

  • key_clip – Key clip, or None

  • key_gain – Key gain, or None

  • key_invert – Invert the key source, or None

  • reverse – Set the reverse flag for the transition, or None

  • flipflop – Set the flipflop flag for the transition, or None

Palettes

class pyatem.command.ColorGeneratorCommand(index, hue=None, saturation=None, luma=None)

Implementation of the CClV command. This sets the color for a color generator

Offset

Size

Type

Description

0

1

u8

Set mask

1

1

u8

Color generator index

2

2

u16

Hue [0-3599]

4

2

u16

Saturation [0-1000]

6

2

u16

Luma [0-1000]

__init__(index, hue=None, saturation=None, luma=None)
Parameters
  • index – Color generator index

  • hue – New Hue for the generator, or None

  • saturation – New Saturation for the generator, or None

  • luma – New Luma for the generator, or None

Downstream

class pyatem.command.FadeToBlackCommand(index)

Implementation of the FtbA command. This triggers the fade-to-black transition

Offset

Size

Type

Description

0

1

u8

M/E index

1

1

?

unknown

2

1

?

unknown

3

1

?

unknown

__init__(index)
Parameters

index – 0-indexed M/E number to trigger FtB on

class pyatem.command.DkeyOnairCommand(index, on_air)

Implementation of the CDsL command. This setting the “on-air” state of the downstream keyer on or off panel.

Offset

Size

Type

Description

0

1

u8

Keyer index, 0-indexed

1

1

?

On air

2

2

?

unknown

__init__(index, on_air)
Parameters
  • index – 0-indexed DSK number to control

  • on_air – The new on-air state for the keyer

class pyatem.command.DkeyTieCommand(index, tie)

Implementation of the CDsT command. This setting the “tie” state of the downstream keyer on or off panel.

Offset

Size

Type

Description

0

1

u8

Keyer index, 0-indexed

1

1

?

Tie

2

2

?

unknown

__init__(index, tie)
Parameters
  • index – 0-indexed DSK number to control

  • tie – The new tie state for the keyer

class pyatem.command.DkeyAutoCommand(index)

Implementation of the DDsA command. This triggers the auto transition of a downstream keyer panel.

Offset

Size

Type

Description

0

1

u8

Keyer index, 0-indexed

1

3

?

unknown

__init__(index)
Parameters

index – 0-indexed DSK number to trigger

class pyatem.command.DkeyRateCommand(index, rate)

Implementation of the CDsR command. This sets the transition rate for the downstream keyer panel.

Offset

Size

Type

Description

0

1

u8

Keyer index, 0-indexed

1

1

u8

Rate in frames

2

2

?

unknown

__init__(index, rate)
Parameters
  • index – 0-indexed DSK number to change

  • rate – New rate for the keyer

class pyatem.command.CaptureStillCommand

Implementation of the Capt command. This saves the current frame of the program output into the media slots

Offset

Size

Type

Description

Upstream keyers

class pyatem.command.KeyOnAirCommand(index, keyer, enabled)

Implementation of the CKOn command. This enables an upstream keyer without having a transition.

Offset

Size

Type

Description

0

1

u8

M/E index, 0-indexed

1

1

u8

Keyer index

2

1

bool

Enabled

4

1

?

unknown

__init__(index, keyer, enabled)
Parameters
  • index – 0-indexed DSK number to trigger

  • keyer – 0-indexed keyer number

  • enabled – Set the keyer on-air or disabled

class pyatem.command.KeyTypeCommand(index, keyer, type=None, fly_enabled=None)

Implementation of the CKTp command. This sets the type of an upstream keyer.

Offset

Size

Type

Description

0

1

u8

Mask

1

1

u8

M/E index, 0-indexed

2

1

u8

Keyer index

3

1

u8

Keyer type

4

1

bool

Fly enabled

5

3

?

unknown

Bit

Mask value

0

Key type

1

Fly enabled

__init__(index, keyer, type=None, fly_enabled=None)
Parameters
  • index – 0-indexed DSK number to trigger

  • keyer – 0-indexed keyer number

  • source – Source index for the keyer fill

class pyatem.command.KeyFillCommand(index, keyer, source)

Implementation of the CKeF command. This enables an upstream keyer without having a transition.

Offset

Size

Type

Description

0

1

u8

M/E index, 0-indexed

1

1

u8

Keyer index

2

2

u16

Source index

__init__(index, keyer, source)
Parameters
  • index – 0-indexed DSK number to trigger

  • keyer – 0-indexed keyer number

  • source – Source index for the keyer fill

class pyatem.command.KeyCutCommand(index, keyer, source)

Implementation of the CKeC command. This sets the key source for an upstream keyer.

Offset

Size

Type

Description

0

1

u8

M/E index, 0-indexed

1

1

u8

Keyer index

2

2

u16

Source index

__init__(index, keyer, source)
Parameters
  • index – 0-indexed DSK number to trigger

  • keyer – 0-indexed keyer number

  • source – Source index for the keyer fill

class pyatem.command.KeyPropertiesLumaCommand(index, keyer, premultiplied=None, clip=None, gain=None, invert_key=None)

Implementation of the CKLm command. This sets the key source for an upstream keyer.

Offset

Size

Type

Description

0

1

u8

Mask

1

1

u8

M/E index, 0-indexed

2

1

u8

Keyer index

3

1

bool

Pre-multiplied

4

2

u16

Clip

6

2

u16

Gain

8

1

bool

Invert key

9

3

?

unknown

Bit

Mask value

0

Pre-multiplied

1

Clip

2

Gain

3

Invert key

__init__(index, keyer, premultiplied=None, clip=None, gain=None, invert_key=None)
Parameters
  • index – 0-indexed DSK number to trigger

  • keyer – 0-indexed keyer number

  • source – Source index for the keyer fill

class pyatem.command.KeyPropertiesDveCommand(index, keyer, size_x=None, size_y=None, pos_x=None, pos_y=None, rotation=None, border_enabled=None, shadow_enabled=None, border_bevel_enabled=None, outer_width=None, inner_width=None, outer_softness=None, inner_softness=None, bevel_softness=None, bevel_position=None, border_opacity=None, border_hue=None, border_saturation=None, border_luma=None, angle=None, altitude=None, mask_enabled=None, mask_top=None, mask_bottom=None, mask_left=None, mask_right=None, rate=None)

Implementation of the CKDV command. This sets the settings of the DVE in an upstream keyer

Offset

Size

Type

Description

0

1

u32

Mask

4

1

u8

M/E index, 0-indexed

5

1

u8

Keyer index

6

2

?

unknown

8

4

i32

Size x [0 - 9900]

12

4

i32

Size y [0 - 9900]

16

4

i32

Position x [-16000 - 16000]

20

4

i32

Position y [-9000 - 9000]

24

4

i32

Rotation

28

1

bool

Border enabled

29

1

bool

Shadow enabled

30

1

u8

Border bevel mode

31

1

?

unknown

32

2

u16

Border outer width [0 - 1600]

34

2

u16

Border inner width [0 - 1600]

36

1

u8

Border outer softness [0 - 100]

37

1

u8

Border inner softness [0 - 100]

38

1

u8

Border bevel softness [0 - 100]

39

1

u8

Border bevel position [0 - 100]

40

1

u8

Border opacity [0-100]

41

1

?

unknown

42

2

u16

Border color hue [0 - 3599]

44

2

u16

Border color saturation [0 - 1000]

46

2

u16

Border color luma [0 - 1000]

48

2

u16

Shadow light source angle [0 - 3590]

50

1

u8

Shadow light source altitude [10-100]

51

1

bool

Mask enabled

52

2

i16

Mask top [-9000 - 9000]

54

2

i16

Mask bottom [-9000 - 9000]

56

2

i16

Mask left [-16000 - 16000]

58

2

i16

Mask right [-16000 - 16000]

60

1

u8

Rate

61

3

?

unknown

Bit

Mask value

0

Size x

1

Size y

2

Position x

3

Position y

4

Rotation

5

Border enabled

6

Shadow enabled

7

Border bevel mode

8

Outer width

9

Inner width

10

Outer softness

11

Inner softness

12

Bevel softness

13

Bevel position

14

Border opacity

15

Border hue

16

Border saturation

17

Border luma

18

Shadow angle

19

Shadow altitude

20

Mask enabled

21

Mask top

22

Mask bottom

23

Mask left

24

Mask right

25

Rate

__init__(index, keyer, size_x=None, size_y=None, pos_x=None, pos_y=None, rotation=None, border_enabled=None, shadow_enabled=None, border_bevel_enabled=None, outer_width=None, inner_width=None, outer_softness=None, inner_softness=None, bevel_softness=None, bevel_position=None, border_opacity=None, border_hue=None, border_saturation=None, border_luma=None, angle=None, altitude=None, mask_enabled=None, mask_top=None, mask_bottom=None, mask_left=None, mask_right=None, rate=None)
Parameters

index – 0-indexed M/E number to control the preview bus of