TranscodingUser

Used to set transcoding parameters for each host.

public static class TranscodingUser {
    public int uid;
    public String userId;
    public int x;
    public int y;
    public int width;
    public int height;
    public int zOrder;
    public float alpha;
    public int audioChannel;
  }

Properties

uid
User ID of the host.
x
The x-coordinate of the host video in the composite layout (origin at top-left, in pixels). Range: [0, width], where width is the canvas width set in LiveTranscoding.
y
The y-coordinate of the host video in the composite layout (origin at top-left, in pixels). Range: [0, height], where height is the canvas height set in LiveTranscoding.
width
Width of the host video (in pixels).
height
Height of the host video (in pixels).
zOrder
Note:
  • If the value is less than 0 or greater than 100, ERR_INVALID_ARGUMENT is returned.
  • Setting zOrder to 0 is supported.
Z-order index of the host video. Range: [0, 100].
  • 0: (Default) bottom layer.
  • 100: top layer.
alpha
Transparency of the host video. Range: [0.0, 1.0].
  • 0.0: Fully transparent.
  • 1.0: (Default) Fully opaque.
audioChannel
Note: If this value is not 0, a dedicated player is required for playback.
Audio channel of the host in the output audio. Default is 0. Range: [0, 5].
  • 0: (Recommended) Default setting. Supports up to stereo depending on the host's upstream capability.
  • 1: Use FL (Front Left) channel. If the host sends multiple audio streams, Agora mixes them into mono.
  • 2: Use FC (Front Center) channel. If the host sends multiple audio streams, Agora mixes them into mono.
  • 3: Use FR (Front Right) channel. If the host sends multiple audio streams, Agora mixes them into mono.
  • 4: Use BL (Back Left) channel. If the host sends multiple audio streams, Agora mixes them into mono.
  • 5: Use BR (Back Right) channel. If the host sends multiple audio streams, Agora mixes them into mono.
  • 0xFF or values greater than 5: Mute the host's audio. Agora removes the host's audio.