Up to date

This page is up to date for Godot 4.2. If you still find outdated information, please open an issue.

AudioStreamPlayback

Inherits: RefCounted < Object

Inherited By: AudioStreamPlaybackPolyphonic, AudioStreamPlaybackResampled

Meta class for playing back audio.

Description

Can play, loop, pause a scroll through audio. See AudioStream and AudioStreamOggVorbis for usage.

Tutorials

Methods

int

_get_loop_count ( ) virtual const

float

_get_playback_position ( ) virtual const

bool

_is_playing ( ) virtual const

int

_mix ( AudioFrame* buffer, float rate_scale, int frames ) virtual

void

_seek ( float position ) virtual

void

_start ( float from_pos ) virtual

void

_stop ( ) virtual

void

_tag_used_streams ( ) virtual


Method Descriptions

int _get_loop_count ( ) virtual const

Overridable method. Should return how many times this audio stream has looped. Most built-in pla