mirror of
https://github.com/mackron/miniaudio.git
synced 2026-04-24 01:04:02 +02:00
Minor refactor for getting load notifications working for sounds.
With this commit, you can now pass in a notification object which is fired when an asynchronous sound has finished loading.
This commit is contained in:
@@ -65,16 +65,16 @@ int main(int argc, char** argv)
|
||||
/*ma_sound_set_volume(&sound, 0.25f);*/
|
||||
//ma_sound_set_pitch(&sound, 2.0f);
|
||||
ma_sound_set_pan(&sound, 0.0f);
|
||||
ma_sound_set_looping(&sound, MA_TRUE);
|
||||
//ma_sound_set_looping(&sound, MA_TRUE);
|
||||
//ma_sound_seek_to_pcm_frame(&sound, 6000000);
|
||||
//ma_sound_set_start_delay(&sound, 1110);
|
||||
ma_sound_set_fade_point_in_milliseconds(&sound, 0, 0, 1, 0, 2000);
|
||||
ma_sound_set_stop_delay(&sound, 1000);
|
||||
ma_sound_start(&sound);
|
||||
|
||||
ma_sleep(2000);
|
||||
//ma_sleep(2000);
|
||||
printf("Stopping...\n");
|
||||
ma_sound_stop(&sound);
|
||||
//ma_sound_stop(&sound);
|
||||
//ma_sound_group_stop(ma_engine_get_master_sound_group(&engine));
|
||||
#endif
|
||||
|
||||
|
||||
Reference in New Issue
Block a user