Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

48 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Flight

Standalone, pure Swift Discord voice library

Flight Logo

The smoothest way to fly audio into Discord

Features

  • Voice Gateway
    • Seamless Connect / Disconnect
    • Auto-Reconnecting & Resumes
    • Invisible DAVE (End-to-End Encryption) Support
    • Granular State Tracking
  • Playback
    • Play, Pause, Resume, Stop
    • Real-time Volume Control
    • Dynamic AudioMixer for playing multiple tracks simultaneously
    • Track Queueing (QueueManager)
  • Audio Pipeline
    • Opus Encoding / Decoding
    • Smart Jitter Buffering (Sequence Sorting, PLC triggering)
    • Strict Continuous Clock Frame Scheduling (20ms)
  • Events
    • trackStarted & trackFinished
    • onUserConnect & onUserDisconnect
    • Receive Voice Audio (onAudioReceived)

Sources

  • FFmpeg (FFmpegSource)
    • Supports local files, HTTP streams, and everything FFmpeg can parse
  • Youtube / SoundCloud (FFmpegSource via yt-dlp)
    • Supported automatically via ytsearch: and scsearch: queries
  • Raw PCM (AudioMixer / Custom Sources)
    • Full support for writing your own custom AudioSource generator
  • DCA / Pre-encoded Opus (OpusSource)
    • Bypasses CPU-heavy encoding entirely for pre-processed .dca files

Documentation

  • Comprehensive documentation is available in the Book directory. Check out the Installation Guide to get started!

Installation

  • Keep in mind that Flight is heavily in active development. For issues, please open an issue in the Issues Tab.
  • Flight is distributed via the Swift Package Manager. Just drop this in your Package.swift:
dependencies: [
    .package(url: "https://github.com/debaucheryparty/Flight.git", branch: "main")
]
  • Note: You must enable C++ Interoperability (.interoperabilityMode(.Cxx)) on your target to use Flight's encryption suite smoothly.

Contributing

  • The dev environment used in this project is:
    • macOS / Linux
    • Swift toolchain: Swift 6.0+
    • System Dependencies: ffmpeg, yt-dlp
  • This should enable you to fork, compile, and test the project before opening a PR.

If you need help or ask for help, feel free to open a Discussion on GitHub or reach out to the maintainers!

About

A Swift voice library for Discord.

Topics

Resources

Stars

Watchers

Forks

Releases

Packages

Used by

Contributors

Languages