TranscodingUser

Settings for each host participating in the transcoding mix.

public class TranscodingUser
    {
        public TranscodingUser()
        {
            uid = 0;
            x = 0;
            y = 0;
            width = 0;
            height = 0;
            zOrder = 0;
            alpha = 1.0;
            audioChannel = 0;
        }

        public TranscodingUser(uint uid, int x, int y, int width, int height, int zOrder, double alpha,
            int audioChannel)
        {
            this.uid = uid;
            this.x = x;
            this.y = y;
            this.width = width;
            this.height = height;
            this.zOrder = zOrder;
            this.alpha = alpha;
            this.audioChannel = audioChannel;
        }

        public uint uid { set; get; }
        public int x { set; get; }
        public int y { set; get; }
        public int width { set; get; }
        public int height { set; get; }
        public int zOrder { set; get; }
        public double alpha { set; get; }
        public int audioChannel { set; get; }
    }

Properties

uid
User ID of the host.
x
The x-coordinate (px) of the host video in the output video, with the top-left corner of the output video as the origin. Value range: [0,width], where width is set in LiveTranscoding.
y
The y-coordinate (px) of the host video in the output video, with the top-left corner of the output video as the origin. Value range: [0,height], where height is set in LiveTranscoding.
width
Width (px) of the host video.
height
Height (px) of the host video.
zOrder
Note:
  • If the value is less than 0 or greater than 100, the error ERR_INVALID_ARGUMENT is returned.
  • Setting zOrder to 0 is supported.
Layer number of the host video. Value range: [0,100].
  • 0: (Default) Video is at the bottom layer.
  • 100: Video is at the top layer.
alpha
Transparency of the host video. Value range: [0.0,1.0].
  • 0.0: Fully transparent.
  • 1.0: (Default) Fully opaque.
audioChannel
Note: When the value is not 0, a special player is required.
The audio channel occupied by the host's audio in the output audio. Default is 0. Value range: [0,5]:
  • 0: (Recommended) Default audio mixing setting, supports up to stereo, related to the host's upstream audio.
  • 1: Host audio is in the FL channel of the output audio. If the upstream audio is multi-channel, the Agora server mixes it into mono first.
  • 2: Host audio is in the FC channel of the output audio. If the upstream audio is multi-channel, the Agora server mixes it into mono first.
  • 3: Host audio is in the FR channel of the output audio. If the upstream audio is multi-channel, the Agora server mixes it into mono first.
  • 4: Host audio is in the BL channel of the output audio. If the upstream audio is multi-channel, the Agora server mixes it into mono first.
  • 5: Host audio is in the BR channel of the output audio. If the upstream audio is multi-channel, the Agora server mixes it into mono first.
  • 0xFF or values greater than 5: This host's audio is muted, and the Agora server removes the host's audio.