public class

Mixer

extends Object
java.lang.Object
   ↳ com.amazonaws.ivs.broadcast.Mixer

Class Overview

The mixer determines the final on-screen and in-ear state for visual elements and audio. An element is represented by a "Slot" that has a number of associated parameters to place an image stream spatially and set the gain of an audio stream from a device. Each slot can be bound to a single image device (such as a camera) and a single audio device (such as a microphone).

Summary

Public Methods
boolean addSlot(BroadcastConfiguration.Mixer.Slot slot)
Add a new slot to the mixer configuration
void bind(Device device, String slot)
Bind a device's output to a mixer slot (specified in the mixer configuration)
String getDeviceBinding(Device device)
Get a device's current binding, if it is bound.
boolean removeSlot(String name)
Remove a slot from the mixer configuration
void transition(String slot, BroadcastConfiguration.Mixer.Slot nextState, double duration, Runnable onComplete)
Transition a slot to a new state
[Expand]
Inherited Methods
From class java.lang.Object

Public Methods

public boolean addSlot (BroadcastConfiguration.Mixer.Slot slot)

Add a new slot to the mixer configuration

Parameters
slot The slot configuration to be added
Returns
  • Success

public void bind (Device device, String slot)

Bind a device's output to a mixer slot (specified in the mixer configuration)

Parameters
device The device to bind to the mixer
slot The target slot's name

public String getDeviceBinding (Device device)

Get a device's current binding, if it is bound.

Parameters
device The device to query
Returns
  • A slot name if it is bound, otherwise null

public boolean removeSlot (String name)

Remove a slot from the mixer configuration

Parameters
name The slot to be removed
Returns
  • Success

public void transition (String slot, BroadcastConfiguration.Mixer.Slot nextState, double duration, Runnable onComplete)

Transition a slot to a new state

Parameters
slot The target slot's name
nextState The new state for the slot
duration The amount of time to animate the transition for
onComplete An optional callback that will be called when the animation has completed