class documentation

class BackgroundMusicContext(object):

Constructor: BackgroundMusicContext(player_callback)

View In Hierarchy

Run background music in a given context

<b>WARNING: Not verified to work on macOS! Should work there as well, since also creates a subprocess under the hood.</b>

Method __enter__ Undocumented
Method __exit__ Undocumented
Method __init__ Create new background music context
Instance Variable __thread Undocumented
def __enter__(self):

Undocumented

def __exit__(self, exc_type, exc_val, exc_tb):

Undocumented

def __init__(self, player_callback: Callable[[], PlayThread] = play_random_music_in_background):

Create new background music context

Parameters
player_callback:Callable[[], PlayThread]Callback to run the music, defaults to<i>script_background_music.play.play_random_music_in_background</i>
__thread: PlayThread | None =

Undocumented