Search Results for

    Show / Hide Table of Contents

    Interface IAudioClient

    Namespace: Discord.Audio
    Assembly: Discord.Net.Core.dll
    Syntax
    public interface IAudioClient : IDisposable

    Properties

    | Improve this Doc View Source

    ConnectionState

    Gets the current connection state of this client.

    Declaration
    ConnectionState ConnectionState { get; }
    Property Value
    Type Description
    ConnectionState
    | Improve this Doc View Source

    Latency

    Gets the estimated round-trip latency, in milliseconds, to the voice WebSocket server.

    Declaration
    int Latency { get; }
    Property Value
    Type Description
    Int32
    | Improve this Doc View Source

    UdpLatency

    Gets the estimated round-trip latency, in milliseconds, to the voice UDP server.

    Declaration
    int UdpLatency { get; }
    Property Value
    Type Description
    Int32

    Methods

    | Improve this Doc View Source

    CreateDirectOpusStream()

    Creates a new outgoing stream accepting Opus-encoded data. This is a direct stream with no internal timer.

    Declaration
    AudioOutStream CreateDirectOpusStream()
    Returns
    Type Description
    AudioOutStream
    | Improve this Doc View Source

    CreateDirectPCMStream(AudioApplication, Nullable<Int32>, Int32)

    Creates a new direct outgoing stream accepting PCM (raw) data. This is a direct stream with no internal timer.

    Declaration
    AudioOutStream CreateDirectPCMStream(AudioApplication application, int? bitrate = null, int packetLoss = 30)
    Parameters
    Type Name Description
    AudioApplication application
    Nullable<Int32> bitrate
    Int32 packetLoss
    Returns
    Type Description
    AudioOutStream
    | Improve this Doc View Source

    CreateOpusStream(Int32)

    Creates a new outgoing stream accepting Opus-encoded data.

    Declaration
    AudioOutStream CreateOpusStream(int bufferMillis = 1000)
    Parameters
    Type Name Description
    Int32 bufferMillis
    Returns
    Type Description
    AudioOutStream
    | Improve this Doc View Source

    CreatePCMStream(AudioApplication, Nullable<Int32>, Int32, Int32)

    Creates a new outgoing stream accepting PCM (raw) data.

    Declaration
    AudioOutStream CreatePCMStream(AudioApplication application, int? bitrate = null, int bufferMillis = 1000, int packetLoss = 30)
    Parameters
    Type Name Description
    AudioApplication application
    Nullable<Int32> bitrate
    Int32 bufferMillis
    Int32 packetLoss
    Returns
    Type Description
    AudioOutStream
    | Improve this Doc View Source

    GetStreams()

    Gets the current audio streams.

    Declaration
    IReadOnlyDictionary<ulong, AudioInStream> GetStreams()
    Returns
    Type Description
    IReadOnlyDictionary<UInt64, AudioInStream>
    | Improve this Doc View Source

    SetSpeakingAsync(Boolean)

    Declaration
    Task SetSpeakingAsync(bool value)
    Parameters
    Type Name Description
    Boolean value
    Returns
    Type Description
    Task
    | Improve this Doc View Source

    StopAsync()

    Declaration
    Task StopAsync()
    Returns
    Type Description
    Task

    Events

    | Improve this Doc View Source

    ClientDisconnected

    Declaration
    event Func<ulong, Task> ClientDisconnected
    Event Type
    Type Description
    Func<UInt64, Task>
    | Improve this Doc View Source

    Connected

    Declaration
    event Func<Task> Connected
    Event Type
    Type Description
    Func<Task>
    | Improve this Doc View Source

    Disconnected

    Declaration
    event Func<Exception, Task> Disconnected
    Event Type
    Type Description
    Func<Exception, Task>
    | Improve this Doc View Source

    LatencyUpdated

    Declaration
    event Func<int, int, Task> LatencyUpdated
    Event Type
    Type Description
    Func<Int32, Int32, Task>
    | Improve this Doc View Source

    SpeakingUpdated

    Declaration
    event Func<ulong, bool, Task> SpeakingUpdated
    Event Type
    Type Description
    Func<UInt64, Boolean, Task>
    | Improve this Doc View Source

    StreamCreated

    Declaration
    event Func<ulong, AudioInStream, Task> StreamCreated
    Event Type
    Type Description
    Func<UInt64, AudioInStream, Task>
    | Improve this Doc View Source

    StreamDestroyed

    Declaration
    event Func<ulong, Task> StreamDestroyed
    Event Type
    Type Description
    Func<UInt64, Task>
    | Improve this Doc View Source

    UdpLatencyUpdated

    Declaration
    event Func<int, int, Task> UdpLatencyUpdated
    Event Type
    Type Description
    Func<Int32, Int32, Task>

    Theme

    • Improve this Doc
    • View Source
    In This Article
    Back to top Discord.Net (c) 2015-2022 3.9.0