Module ggez::audio [] [src]

Provides an interface to output sound to the user's speakers.

This departs from the Love2D API a bit because SDL2_mixer is opinionated about the difference between samples and music files, and also makes channel management and such more explicit. This seems a bit awkward but we'll roll with it for now.

Structs

Music

A source of music data. Music is played on a separate dedicated channel from sounds, and also has a separate corpus of decoders than sounds do; see the SDL_mixer documentation for details or use Context::print_sound_stats() to print out which decoders are supported for your build.

Sound

A source of audio data.

Traits

AudioOps

A trait for general operations on sound objects.

Functions

pause_music
play_music
resume_music
rewind_music
stop_music

Type Definitions

Channel

An object representing a channel that may be playing a particular Sound.