docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Struct RTCIceServer

    Represents a configuration for an ICE server used within WebRTC connections.

    Namespace: Unity.WebRTC
    Assembly: Unity.WebRTC.dll
    Syntax
    [Serializable]
    public struct RTCIceServer
    Remarks

    Represents a configuration for an ICE server used within WebRTC connections, including authentication credentials and STUN/TURN server URLs.

    Examples
    RTCConfiguration configuration = default;
    configuration.iceServers = new[] { new RTCIceServer { urls = new[] { "stun:stun.l.google.com:19302" } } };

    Fields

    credential

    Specifies the credential for authenticating with the ICE server.

    Declaration
    [Tooltip("Optional: specifies the password to use when authenticating with the ICE server")]
    public string credential
    Field Value
    Type Description
    string
    See Also
    RTCConfiguration

    credentialType

    Specifies the type of credential used.

    Declaration
    [Tooltip("What type of credential the `password` value")]
    public RTCIceCredentialType credentialType
    Field Value
    Type Description
    RTCIceCredentialType
    See Also
    RTCConfiguration

    urls

    An array containing the URLs of STUN or TURN servers to use for ICE negotiation.

    Declaration
    [Tooltip("Array to set URLs of your STUN/TURN servers")]
    public string[] urls
    Field Value
    Type Description
    string[]
    See Also
    RTCConfiguration

    username

    Specifies the user name for authenticating with the ICE server.

    Declaration
    [Tooltip("Optional: specifies the username to use when authenticating with the ICE server")]
    public string username
    Field Value
    Type Description
    string
    See Also
    RTCConfiguration

    See Also

    RTCConfiguration
    In This Article
    Back to top
    Copyright © 2024 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)