diff --git a/mpfmc/core/audio/audio_interface.c b/mpfmc/core/audio/audio_interface.c index b20e4a28..bcd47033 100644 --- a/mpfmc/core/audio/audio_interface.c +++ b/mpfmc/core/audio/audio_interface.c @@ -822,12 +822,12 @@ static const char *__pyx_filename; static const char *__pyx_f[] = { - "mpfmc\\core\\audio\\audio_interface.pyx", + "mpfmc/core/audio/audio_interface.pyx", "stringsource", - "mpfmc\\core\\audio\\track.pxd", - "mpfmc\\core\\audio\\sound_file.pxd", - "mpfmc\\core\\audio\\track_standard.pxd", - "mpfmc\\core\\audio\\track_sound_loop.pxd", + "mpfmc/core/audio/track.pxd", + "mpfmc/core/audio/sound_file.pxd", + "mpfmc/core/audio/track_standard.pxd", + "mpfmc/core/audio/track_sound_loop.pxd", }; /*--- Type declarations ---*/ @@ -1518,7 +1518,7 @@ struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface_AudioInterface { }; -/* "mpfmc/core/audio/audio_interface.pyx":244 +/* "mpfmc/core/audio/audio_interface.pyx":245 * * @staticmethod * def string_to_gain(gain): # <<<<<<<<<<<<<< @@ -1531,7 +1531,7 @@ struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct__strin }; -/* "mpfmc/core/audio/audio_interface.pyx":249 +/* "mpfmc/core/audio/audio_interface.pyx":250 * * if gain_string.endswith('DB'): * gain_string = ''.join(i for i in gain_string if not i.isalpha()) # <<<<<<<<<<<<<< @@ -1545,7 +1545,7 @@ struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_1_gene }; -/* "mpfmc/core/audio/audio_interface.pyx":269 +/* "mpfmc/core/audio/audio_interface.pyx":270 * * @staticmethod * def string_to_secs(time): # <<<<<<<<<<<<<< @@ -1558,7 +1558,7 @@ struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_2_stri }; -/* "mpfmc/core/audio/audio_interface.pyx":288 +/* "mpfmc/core/audio/audio_interface.pyx":289 * * if time_string.endswith('MS') or time_string.endswith('MSEC'): * time_string = ''.join(i for i in time_string if not i.isalpha()) # <<<<<<<<<<<<<< @@ -1572,7 +1572,7 @@ struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_3_gene }; -/* "mpfmc/core/audio/audio_interface.pyx":292 +/* "mpfmc/core/audio/audio_interface.pyx":293 * * elif time_string.endswith('S') or time_string.endswith('SEC'): * time_string = ''.join(i for i in time_string if not i.isalpha()) # <<<<<<<<<<<<<< @@ -1586,7 +1586,7 @@ struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_4_gene }; -/* "mpfmc/core/audio/audio_interface.pyx":296 +/* "mpfmc/core/audio/audio_interface.pyx":297 * * elif 'D' in time_string: * time_string = ''.join(i for i in time_string if not i.isalpha()) # <<<<<<<<<<<<<< @@ -1600,7 +1600,7 @@ struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_5_gene }; -/* "mpfmc/core/audio/audio_interface.pyx":300 +/* "mpfmc/core/audio/audio_interface.pyx":301 * * elif 'H' in time_string: * time_string = ''.join(i for i in time_string if not i.isalpha()) # <<<<<<<<<<<<<< @@ -1614,7 +1614,7 @@ struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_6_gene }; -/* "mpfmc/core/audio/audio_interface.pyx":304 +/* "mpfmc/core/audio/audio_interface.pyx":305 * * elif 'M' in time_string: * time_string = ''.join(i for i in time_string if not i.isalpha()) # <<<<<<<<<<<<<< @@ -1691,6 +1691,7 @@ struct __pyx_vtabstruct_5mpfmc_4core_5audio_16track_sound_loop_TrackSoundLoop { PyObject *(*_delete_player_layers)(struct __pyx_obj_5mpfmc_4core_5audio_16track_sound_loop_TrackSoundLoop *, __pyx_t_5mpfmc_4core_5audio_16track_sound_loop_SoundLoopSetPlayer *); PyObject *(*_cancel_all_delayed_players)(struct __pyx_obj_5mpfmc_4core_5audio_16track_sound_loop_TrackSoundLoop *); PyObject *(*_fade_out_all_players)(struct __pyx_obj_5mpfmc_4core_5audio_16track_sound_loop_TrackSoundLoop *, Uint32); + Uint32 (*_fix_sample_frame_pos)(struct __pyx_obj_5mpfmc_4core_5audio_16track_sound_loop_TrackSoundLoop *, Uint32, Uint8, int); Uint32 (*_round_sample_pos_up_to_interval)(struct __pyx_obj_5mpfmc_4core_5audio_16track_sound_loop_TrackSoundLoop *, Uint32, Uint32, int); void (*mix_playing_sounds)(__pyx_t_5mpfmc_4core_5audio_5track_TrackState *, Uint32, __pyx_t_5mpfmc_4core_5audio_4sdl2_AudioCallbackData *); }; @@ -2574,7 +2575,7 @@ static const char __pyx_k_mpfmc_core_audio_playlist_contro[] = "mpfmc.core.audio static const char __pyx_k_no_default___reduce___due_to_non[] = "no default __reduce__ due to non-trivial __cinit__"; static const char __pyx_k_The_audio_interface_only_support_2[] = "The audio interface only supports little endian systems in this release."; static const char __pyx_k_Unable_to_initialize_Audio_Inter_2[] = "Unable to initialize Audio Interface: Buffer samples is required to be a power of two"; -static const char __pyx_k_mpfmc_core_audio_audio_interface_2[] = "mpfmc\\core\\audio\\audio_interface.pyx"; +static const char __pyx_k_mpfmc_core_audio_audio_interface_2[] = "mpfmc/core/audio/audio_interface.pyx"; static PyObject *__pyx_kp_u_; static PyObject *__pyx_kp_u_Add_track_failed_the_maximum_num; static PyObject *__pyx_kp_u_Add_track_failed_the_track_name; @@ -4350,7 +4351,7 @@ static int __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_2__in * self.audio_callback_data.track_count = 0 * self.audio_callback_data.tracks = PyMem_Malloc(MAX_TRACKS * sizeof(TrackState*)) # <<<<<<<<<<<<<< * self.audio_callback_data.c_log_file = NULL - * # self.audio_callback_data.c_log_file = fopen("D:\\Temp\\Dev\\MPFMC_AudioLibrary.log", "wb") + * # self.audio_callback_data.c_log_file = fopen("/tmp/MPFMC_AudioLibrary.log", "wb") */ __pyx_v_self->audio_callback_data.tracks = ((void **)PyMem_Malloc((8 * (sizeof(__pyx_t_5mpfmc_4core_5audio_5track_TrackState *))))); @@ -4358,22 +4359,22 @@ static int __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_2__in * self.audio_callback_data.track_count = 0 * self.audio_callback_data.tracks = PyMem_Malloc(MAX_TRACKS * sizeof(TrackState*)) * self.audio_callback_data.c_log_file = NULL # <<<<<<<<<<<<<< + * # self.audio_callback_data.c_log_file = fopen("/tmp/MPFMC_AudioLibrary.log", "wb") * # self.audio_callback_data.c_log_file = fopen("D:\\Temp\\Dev\\MPFMC_AudioLibrary.log", "wb") - * # fprintf(self.audio_callback_data.c_log_file, "---------------------------------------------------------------------------\r\n") */ __pyx_v_self->audio_callback_data.c_log_file = NULL; - /* "mpfmc/core/audio/audio_interface.pyx":171 + /* "mpfmc/core/audio/audio_interface.pyx":172 * # fflush(self.audio_callback_data.c_log_file) * * self.log.info('Settings requested - rate: %d, channels: %d, buffer: %d samples', # <<<<<<<<<<<<<< * rate, channels, buffer_samples) * self.log.info('Settings in use - rate: %d, channels: %d, buffer: %d samples (%d bytes @ %d bytes per sample)', */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_info); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 171, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_info); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 172, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - /* "mpfmc/core/audio/audio_interface.pyx":172 + /* "mpfmc/core/audio/audio_interface.pyx":173 * * self.log.info('Settings requested - rate: %d, channels: %d, buffer: %d samples', * rate, channels, buffer_samples) # <<<<<<<<<<<<<< @@ -4395,7 +4396,7 @@ static int __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_2__in #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[5] = {__pyx_t_10, __pyx_kp_u_Settings_requested_rate_d_channe, __pyx_v_rate, __pyx_v_channels, __pyx_v_buffer_samples}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_9, 4+__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 171, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_9, 4+__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 172, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_GOTREF(__pyx_t_1); } else @@ -4403,13 +4404,13 @@ static int __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_2__in #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[5] = {__pyx_t_10, __pyx_kp_u_Settings_requested_rate_d_channe, __pyx_v_rate, __pyx_v_channels, __pyx_v_buffer_samples}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_9, 4+__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 171, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_9, 4+__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 172, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_GOTREF(__pyx_t_1); } else #endif { - __pyx_t_2 = PyTuple_New(4+__pyx_t_9); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 171, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(4+__pyx_t_9); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 172, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (__pyx_t_10) { __Pyx_GIVEREF(__pyx_t_10); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_10); __pyx_t_10 = NULL; @@ -4426,55 +4427,55 @@ static int __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_2__in __Pyx_INCREF(__pyx_v_buffer_samples); __Pyx_GIVEREF(__pyx_v_buffer_samples); PyTuple_SET_ITEM(__pyx_t_2, 3+__pyx_t_9, __pyx_v_buffer_samples); - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 171, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 172, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; } __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":173 + /* "mpfmc/core/audio/audio_interface.pyx":174 * self.log.info('Settings requested - rate: %d, channels: %d, buffer: %d samples', * rate, channels, buffer_samples) * self.log.info('Settings in use - rate: %d, channels: %d, buffer: %d samples (%d bytes @ %d bytes per sample)', # <<<<<<<<<<<<<< * self.audio_callback_data.sample_rate, self.audio_callback_data.channels, * self.audio_callback_data.buffer_samples, self.audio_callback_data.buffer_size, */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_info); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 173, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_info); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 174, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - /* "mpfmc/core/audio/audio_interface.pyx":174 + /* "mpfmc/core/audio/audio_interface.pyx":175 * rate, channels, buffer_samples) * self.log.info('Settings in use - rate: %d, channels: %d, buffer: %d samples (%d bytes @ %d bytes per sample)', * self.audio_callback_data.sample_rate, self.audio_callback_data.channels, # <<<<<<<<<<<<<< * self.audio_callback_data.buffer_samples, self.audio_callback_data.buffer_size, * self.audio_callback_data.bytes_per_sample) */ - __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->audio_callback_data.sample_rate); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 174, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->audio_callback_data.sample_rate); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 175, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_10 = __Pyx_PyInt_From_int(__pyx_v_self->audio_callback_data.channels); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 174, __pyx_L1_error) + __pyx_t_10 = __Pyx_PyInt_From_int(__pyx_v_self->audio_callback_data.channels); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 175, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); - /* "mpfmc/core/audio/audio_interface.pyx":175 + /* "mpfmc/core/audio/audio_interface.pyx":176 * self.log.info('Settings in use - rate: %d, channels: %d, buffer: %d samples (%d bytes @ %d bytes per sample)', * self.audio_callback_data.sample_rate, self.audio_callback_data.channels, * self.audio_callback_data.buffer_samples, self.audio_callback_data.buffer_size, # <<<<<<<<<<<<<< * self.audio_callback_data.bytes_per_sample) * */ - __pyx_t_6 = __Pyx_PyInt_From_Uint16(__pyx_v_self->audio_callback_data.buffer_samples); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 175, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyInt_From_Uint16(__pyx_v_self->audio_callback_data.buffer_samples); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 176, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_12 = __Pyx_PyInt_From_Uint32(__pyx_v_self->audio_callback_data.buffer_size); if (unlikely(!__pyx_t_12)) __PYX_ERR(0, 175, __pyx_L1_error) + __pyx_t_12 = __Pyx_PyInt_From_Uint32(__pyx_v_self->audio_callback_data.buffer_size); if (unlikely(!__pyx_t_12)) __PYX_ERR(0, 176, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_12); - /* "mpfmc/core/audio/audio_interface.pyx":176 + /* "mpfmc/core/audio/audio_interface.pyx":177 * self.audio_callback_data.sample_rate, self.audio_callback_data.channels, * self.audio_callback_data.buffer_samples, self.audio_callback_data.buffer_size, * self.audio_callback_data.bytes_per_sample) # <<<<<<<<<<<<<< * * # Unlock the SDL audio callback functions */ - __pyx_t_13 = __Pyx_PyInt_From_Uint8(__pyx_v_self->audio_callback_data.bytes_per_sample); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 176, __pyx_L1_error) + __pyx_t_13 = __Pyx_PyInt_From_Uint8(__pyx_v_self->audio_callback_data.bytes_per_sample); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 177, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_13); __pyx_t_14 = NULL; __pyx_t_9 = 0; @@ -4491,7 +4492,7 @@ static int __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_2__in #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[7] = {__pyx_t_14, __pyx_kp_u_Settings_in_use_rate_d_channels, __pyx_t_2, __pyx_t_10, __pyx_t_6, __pyx_t_12, __pyx_t_13}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_9, 6+__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 173, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_9, 6+__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 174, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; @@ -4504,7 +4505,7 @@ static int __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_2__in #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[7] = {__pyx_t_14, __pyx_kp_u_Settings_in_use_rate_d_channels, __pyx_t_2, __pyx_t_10, __pyx_t_6, __pyx_t_12, __pyx_t_13}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_9, 6+__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 173, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_9, 6+__pyx_t_9); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 174, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; @@ -4515,7 +4516,7 @@ static int __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_2__in } else #endif { - __pyx_t_15 = PyTuple_New(6+__pyx_t_9); if (unlikely(!__pyx_t_15)) __PYX_ERR(0, 173, __pyx_L1_error) + __pyx_t_15 = PyTuple_New(6+__pyx_t_9); if (unlikely(!__pyx_t_15)) __PYX_ERR(0, 174, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_15); if (__pyx_t_14) { __Pyx_GIVEREF(__pyx_t_14); PyTuple_SET_ITEM(__pyx_t_15, 0, __pyx_t_14); __pyx_t_14 = NULL; @@ -4538,14 +4539,14 @@ static int __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_2__in __pyx_t_6 = 0; __pyx_t_12 = 0; __pyx_t_13 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_15, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 173, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_15, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 174, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; } __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":179 + /* "mpfmc/core/audio/audio_interface.pyx":180 * * # Unlock the SDL audio callback functions * SDL_UnlockAudio() # <<<<<<<<<<<<<< @@ -4554,14 +4555,14 @@ static int __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_2__in */ SDL_UnlockAudio(); - /* "mpfmc/core/audio/audio_interface.pyx":181 + /* "mpfmc/core/audio/audio_interface.pyx":182 * SDL_UnlockAudio() * * self.tracks = list() # <<<<<<<<<<<<<< * self.playlist_controllers = dict() * */ - __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 181, __pyx_L1_error) + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 182, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->tracks); @@ -4569,14 +4570,14 @@ static int __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_2__in __pyx_v_self->tracks = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":182 + /* "mpfmc/core/audio/audio_interface.pyx":183 * * self.tracks = list() * self.playlist_controllers = dict() # <<<<<<<<<<<<<< * * def __del__(self): */ - __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 182, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 183, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __Pyx_GOTREF(__pyx_v_self->playlist_controllers); @@ -4612,7 +4613,7 @@ static int __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_2__in return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":184 +/* "mpfmc/core/audio/audio_interface.pyx":185 * self.playlist_controllers = dict() * * def __del__(self): # <<<<<<<<<<<<<< @@ -4645,14 +4646,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__del__", 0); - /* "mpfmc/core/audio/audio_interface.pyx":186 + /* "mpfmc/core/audio/audio_interface.pyx":187 * def __del__(self): * """Shut down the audio interface and clean up allocated memory""" * self.log.debug("Shutting down and cleaning up allocated memory...") # <<<<<<<<<<<<<< * * # Stop audio processing (will stop all SDL callbacks) */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_debug); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 186, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_debug); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 187, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -4666,19 +4667,19 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_kp_u_Shutting_down_and_cleaning_up_al) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_kp_u_Shutting_down_and_cleaning_up_al); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 186, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 187, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":189 + /* "mpfmc/core/audio/audio_interface.pyx":190 * * # Stop audio processing (will stop all SDL callbacks) * self.shutdown() # <<<<<<<<<<<<<< * * self.audio_callback_data.track_count = 0 */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_shutdown); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 189, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_shutdown); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 190, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -4692,12 +4693,12 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 189, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 190, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":191 + /* "mpfmc/core/audio/audio_interface.pyx":192 * self.shutdown() * * self.audio_callback_data.track_count = 0 # <<<<<<<<<<<<<< @@ -4706,7 +4707,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ __pyx_v_self->audio_callback_data.track_count = 0; - /* "mpfmc/core/audio/audio_interface.pyx":192 + /* "mpfmc/core/audio/audio_interface.pyx":193 * * self.audio_callback_data.track_count = 0 * PyMem_Free(self.audio_callback_data.tracks) # <<<<<<<<<<<<<< @@ -4715,7 +4716,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ PyMem_Free(__pyx_v_self->audio_callback_data.tracks); - /* "mpfmc/core/audio/audio_interface.pyx":193 + /* "mpfmc/core/audio/audio_interface.pyx":194 * self.audio_callback_data.track_count = 0 * PyMem_Free(self.audio_callback_data.tracks) * self.audio_callback_data.tracks = NULL # <<<<<<<<<<<<<< @@ -4724,14 +4725,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ __pyx_v_self->audio_callback_data.tracks = NULL; - /* "mpfmc/core/audio/audio_interface.pyx":196 + /* "mpfmc/core/audio/audio_interface.pyx":197 * * # Remove tracks * self.tracks.clear() # <<<<<<<<<<<<<< * * # SDL and SDL_Mixer no longer needed */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->tracks, __pyx_n_s_clear); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 196, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->tracks, __pyx_n_s_clear); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 197, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -4745,12 +4746,12 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 196, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 197, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":199 + /* "mpfmc/core/audio/audio_interface.pyx":200 * * # SDL and SDL_Mixer no longer needed * Mix_Quit() # <<<<<<<<<<<<<< @@ -4759,7 +4760,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ Mix_Quit(); - /* "mpfmc/core/audio/audio_interface.pyx":200 + /* "mpfmc/core/audio/audio_interface.pyx":201 * # SDL and SDL_Mixer no longer needed * Mix_Quit() * SDL_Quit() # <<<<<<<<<<<<<< @@ -4768,7 +4769,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ SDL_Quit(); - /* "mpfmc/core/audio/audio_interface.pyx":184 + /* "mpfmc/core/audio/audio_interface.pyx":185 * self.playlist_controllers = dict() * * def __del__(self): # <<<<<<<<<<<<<< @@ -4791,7 +4792,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":202 +/* "mpfmc/core/audio/audio_interface.pyx":203 * SDL_Quit() * * def _initialize_gstreamer(self): # <<<<<<<<<<<<<< @@ -4833,7 +4834,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("_initialize_gstreamer", 0); - /* "mpfmc/core/audio/audio_interface.pyx":204 + /* "mpfmc/core/audio/audio_interface.pyx":205 * def _initialize_gstreamer(self): * """Initialize the GStreamer library""" * if gst_is_initialized(): # <<<<<<<<<<<<<< @@ -4843,7 +4844,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_1 = (gst_is_initialized() != 0); if (__pyx_t_1) { - /* "mpfmc/core/audio/audio_interface.pyx":205 + /* "mpfmc/core/audio/audio_interface.pyx":206 * """Initialize the GStreamer library""" * if gst_is_initialized(): * return True # <<<<<<<<<<<<<< @@ -4855,7 +4856,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_r = Py_True; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":204 + /* "mpfmc/core/audio/audio_interface.pyx":205 * def _initialize_gstreamer(self): * """Initialize the GStreamer library""" * if gst_is_initialized(): # <<<<<<<<<<<<<< @@ -4864,7 +4865,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":207 + /* "mpfmc/core/audio/audio_interface.pyx":208 * return True * * cdef int argc = 0 # <<<<<<<<<<<<<< @@ -4873,7 +4874,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ __pyx_v_argc = 0; - /* "mpfmc/core/audio/audio_interface.pyx":208 + /* "mpfmc/core/audio/audio_interface.pyx":209 * * cdef int argc = 0 * cdef char **argv = NULL # <<<<<<<<<<<<<< @@ -4882,7 +4883,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ __pyx_v_argv = NULL; - /* "mpfmc/core/audio/audio_interface.pyx":210 + /* "mpfmc/core/audio/audio_interface.pyx":211 * cdef char **argv = NULL * cdef GError *error * if not gst_init_check(&argc, &argv, &error): # <<<<<<<<<<<<<< @@ -4892,18 +4893,18 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_1 = ((!(gst_init_check((&__pyx_v_argc), (&__pyx_v_argv), (&__pyx_v_error)) != 0)) != 0); if (unlikely(__pyx_t_1)) { - /* "mpfmc/core/audio/audio_interface.pyx":211 + /* "mpfmc/core/audio/audio_interface.pyx":212 * cdef GError *error * if not gst_init_check(&argc, &argv, &error): * msg = 'Unable to initialize gstreamer: code={} message={}'.format(error.code, error.message) # <<<<<<<<<<<<<< * raise AudioException(msg) * */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_kp_u_Unable_to_initialize_gstreamer_c, __pyx_n_s_format); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 211, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_kp_u_Unable_to_initialize_gstreamer_c, __pyx_n_s_format); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 212, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = __Pyx_PyInt_From_int(__pyx_v_error->code); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 211, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyInt_From_int(__pyx_v_error->code); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 212, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_5 = __Pyx_PyBytes_FromString(__pyx_v_error->message); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 211, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyBytes_FromString(__pyx_v_error->message); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 212, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_6 = NULL; __pyx_t_7 = 0; @@ -4920,7 +4921,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_t_4, __pyx_t_5}; - __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 211, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 212, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; @@ -4930,7 +4931,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_t_4, __pyx_t_5}; - __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 211, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 212, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; @@ -4938,7 +4939,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } else #endif { - __pyx_t_8 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 211, __pyx_L1_error) + __pyx_t_8 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 212, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_6) { __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_6); __pyx_t_6 = NULL; @@ -4950,7 +4951,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_7, __pyx_t_5); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_8, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 211, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_8, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 212, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } @@ -4958,14 +4959,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_v_msg = __pyx_t_2; __pyx_t_2 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":212 + /* "mpfmc/core/audio/audio_interface.pyx":213 * if not gst_init_check(&argc, &argv, &error): * msg = 'Unable to initialize gstreamer: code={} message={}'.format(error.code, error.message) * raise AudioException(msg) # <<<<<<<<<<<<<< * * @staticmethod */ - __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_AudioException); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 212, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_AudioException); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 213, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { @@ -4979,14 +4980,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_2 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_8, __pyx_v_msg) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_msg); __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 212, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 213, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_Raise(__pyx_t_2, 0, 0, 0); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __PYX_ERR(0, 212, __pyx_L1_error) + __PYX_ERR(0, 213, __pyx_L1_error) - /* "mpfmc/core/audio/audio_interface.pyx":210 + /* "mpfmc/core/audio/audio_interface.pyx":211 * cdef char **argv = NULL * cdef GError *error * if not gst_init_check(&argc, &argv, &error): # <<<<<<<<<<<<<< @@ -4995,7 +4996,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":202 + /* "mpfmc/core/audio/audio_interface.pyx":203 * SDL_Quit() * * def _initialize_gstreamer(self): # <<<<<<<<<<<<<< @@ -5022,7 +5023,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":215 +/* "mpfmc/core/audio/audio_interface.pyx":216 * * @staticmethod * def initialize(int rate=44100, int channels=2, int buffer_samples=4096, **kwargs): # <<<<<<<<<<<<<< @@ -5084,7 +5085,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, pos_args, "initialize") < 0)) __PYX_ERR(0, 215, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, pos_args, "initialize") < 0)) __PYX_ERR(0, 216, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -5099,24 +5100,24 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } } if (values[0]) { - __pyx_v_rate = __Pyx_PyInt_As_int(values[0]); if (unlikely((__pyx_v_rate == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 215, __pyx_L3_error) + __pyx_v_rate = __Pyx_PyInt_As_int(values[0]); if (unlikely((__pyx_v_rate == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 216, __pyx_L3_error) } else { __pyx_v_rate = ((int)0xAC44); } if (values[1]) { - __pyx_v_channels = __Pyx_PyInt_As_int(values[1]); if (unlikely((__pyx_v_channels == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 215, __pyx_L3_error) + __pyx_v_channels = __Pyx_PyInt_As_int(values[1]); if (unlikely((__pyx_v_channels == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 216, __pyx_L3_error) } else { __pyx_v_channels = ((int)2); } if (values[2]) { - __pyx_v_buffer_samples = __Pyx_PyInt_As_int(values[2]); if (unlikely((__pyx_v_buffer_samples == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 215, __pyx_L3_error) + __pyx_v_buffer_samples = __Pyx_PyInt_As_int(values[2]); if (unlikely((__pyx_v_buffer_samples == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 216, __pyx_L3_error) } else { __pyx_v_buffer_samples = ((int)0x1000); } } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("initialize", 0, 0, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 215, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("initialize", 0, 0, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 216, __pyx_L3_error) __pyx_L3_error:; __Pyx_DECREF(__pyx_v_kwargs); __pyx_v_kwargs = 0; __Pyx_AddTraceback("mpfmc.core.audio.audio_interface.AudioInterface.initialize", __pyx_clineno, __pyx_lineno, __pyx_filename); @@ -5143,69 +5144,69 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("initialize", 0); - /* "mpfmc/core/audio/audio_interface.pyx":227 + /* "mpfmc/core/audio/audio_interface.pyx":228 * """ * # Initialize the audio instance and return it * audio_interface_instance = AudioInterface(rate=rate, # <<<<<<<<<<<<<< * channels=channels, * buffer_samples=buffer_samples, */ - __pyx_t_2 = __Pyx_PyDict_NewPresized(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 227, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyDict_NewPresized(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 228, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_rate); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 227, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_rate); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 228, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_rate, __pyx_t_3) < 0) __PYX_ERR(0, 227, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_rate, __pyx_t_3) < 0) __PYX_ERR(0, 228, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":228 + /* "mpfmc/core/audio/audio_interface.pyx":229 * # Initialize the audio instance and return it * audio_interface_instance = AudioInterface(rate=rate, * channels=channels, # <<<<<<<<<<<<<< * buffer_samples=buffer_samples, * **kwargs) */ - __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_channels); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 228, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_channels); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 229, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_channels, __pyx_t_3) < 0) __PYX_ERR(0, 227, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_channels, __pyx_t_3) < 0) __PYX_ERR(0, 228, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":229 + /* "mpfmc/core/audio/audio_interface.pyx":230 * audio_interface_instance = AudioInterface(rate=rate, * channels=channels, * buffer_samples=buffer_samples, # <<<<<<<<<<<<<< * **kwargs) * return audio_interface_instance */ - __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_buffer_samples); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 229, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_buffer_samples); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 230, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_buffer_samples, __pyx_t_3) < 0) __PYX_ERR(0, 227, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_buffer_samples, __pyx_t_3) < 0) __PYX_ERR(0, 228, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_1 = __pyx_t_2; __pyx_t_2 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":230 + /* "mpfmc/core/audio/audio_interface.pyx":231 * channels=channels, * buffer_samples=buffer_samples, * **kwargs) # <<<<<<<<<<<<<< * return audio_interface_instance * */ - if (__Pyx_MergeKeywords(__pyx_t_1, __pyx_v_kwargs) < 0) __PYX_ERR(0, 230, __pyx_L1_error) + if (__Pyx_MergeKeywords(__pyx_t_1, __pyx_v_kwargs) < 0) __PYX_ERR(0, 231, __pyx_L1_error) - /* "mpfmc/core/audio/audio_interface.pyx":227 + /* "mpfmc/core/audio/audio_interface.pyx":228 * """ * # Initialize the audio instance and return it * audio_interface_instance = AudioInterface(rate=rate, # <<<<<<<<<<<<<< * channels=channels, * buffer_samples=buffer_samples, */ - __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface), __pyx_empty_tuple, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 227, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface), __pyx_empty_tuple, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 228, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_audio_interface_instance = ((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface_AudioInterface *)__pyx_t_2); __pyx_t_2 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":231 + /* "mpfmc/core/audio/audio_interface.pyx":232 * buffer_samples=buffer_samples, * **kwargs) * return audio_interface_instance # <<<<<<<<<<<<<< @@ -5217,7 +5218,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_r = ((PyObject *)__pyx_v_audio_interface_instance); goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":215 + /* "mpfmc/core/audio/audio_interface.pyx":216 * * @staticmethod * def initialize(int rate=44100, int channels=2, int buffer_samples=4096, **kwargs): # <<<<<<<<<<<<<< @@ -5239,7 +5240,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":234 +/* "mpfmc/core/audio/audio_interface.pyx":235 * * @staticmethod * def power_of_two(int num): # <<<<<<<<<<<<<< @@ -5278,18 +5279,18 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface else goto __pyx_L5_argtuple_error; } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "power_of_two") < 0)) __PYX_ERR(0, 234, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "power_of_two") < 0)) __PYX_ERR(0, 235, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 1) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); } - __pyx_v_num = __Pyx_PyInt_As_int(values[0]); if (unlikely((__pyx_v_num == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 234, __pyx_L3_error) + __pyx_v_num = __Pyx_PyInt_As_int(values[0]); if (unlikely((__pyx_v_num == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 235, __pyx_L3_error) } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("power_of_two", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 234, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("power_of_two", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 235, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("mpfmc.core.audio.audio_interface.AudioInterface.power_of_two", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -5313,7 +5314,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("power_of_two", 0); - /* "mpfmc/core/audio/audio_interface.pyx":236 + /* "mpfmc/core/audio/audio_interface.pyx":237 * def power_of_two(int num): * """ Returns whether or not the supplied number is a power of 2 """ * return ((num & (num - 1)) == 0) and num != 0 # <<<<<<<<<<<<<< @@ -5324,14 +5325,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_2 = ((__pyx_v_num & (__pyx_v_num - 1)) == 0); if (__pyx_t_2) { } else { - __pyx_t_3 = __Pyx_PyBool_FromLong(__pyx_t_2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 236, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyBool_FromLong(__pyx_t_2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 237, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_1 = __pyx_t_3; __pyx_t_3 = 0; goto __pyx_L3_bool_binop_done; } __pyx_t_2 = (__pyx_v_num != 0); - __pyx_t_3 = __Pyx_PyBool_FromLong(__pyx_t_2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 236, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyBool_FromLong(__pyx_t_2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 237, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_1 = __pyx_t_3; __pyx_t_3 = 0; @@ -5340,7 +5341,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":234 + /* "mpfmc/core/audio/audio_interface.pyx":235 * * @staticmethod * def power_of_two(int num): # <<<<<<<<<<<<<< @@ -5360,7 +5361,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":239 +/* "mpfmc/core/audio/audio_interface.pyx":240 * * @staticmethod * def db_to_gain(float db): # <<<<<<<<<<<<<< @@ -5399,18 +5400,18 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface else goto __pyx_L5_argtuple_error; } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "db_to_gain") < 0)) __PYX_ERR(0, 239, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "db_to_gain") < 0)) __PYX_ERR(0, 240, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 1) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); } - __pyx_v_db = __pyx_PyFloat_AsFloat(values[0]); if (unlikely((__pyx_v_db == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 239, __pyx_L3_error) + __pyx_v_db = __pyx_PyFloat_AsFloat(values[0]); if (unlikely((__pyx_v_db == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 240, __pyx_L3_error) } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("db_to_gain", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 239, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("db_to_gain", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 240, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("mpfmc.core.audio.audio_interface.AudioInterface.db_to_gain", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -5437,7 +5438,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("db_to_gain", 0); - /* "mpfmc/core/audio/audio_interface.pyx":241 + /* "mpfmc/core/audio/audio_interface.pyx":242 * def db_to_gain(float db): * """Converts a value in decibels (-inf to 0.0) to a gain (0.0 to 1.0)""" * return pow(10, db / 20.0) # <<<<<<<<<<<<<< @@ -5445,9 +5446,9 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * @staticmethod */ __Pyx_XDECREF(__pyx_r); - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pow); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 241, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pow); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 242, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = PyFloat_FromDouble((((double)__pyx_v_db) / 20.0)); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 241, __pyx_L1_error) + __pyx_t_3 = PyFloat_FromDouble((((double)__pyx_v_db) / 20.0)); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 242, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; __pyx_t_5 = 0; @@ -5464,7 +5465,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_int_10, __pyx_t_3}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 241, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 242, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; @@ -5473,14 +5474,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_int_10, __pyx_t_3}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 241, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_5, 2+__pyx_t_5); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 242, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; } else #endif { - __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 241, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(2+__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 242, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -5491,7 +5492,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_5, __pyx_t_3); __pyx_t_3 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_6, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 241, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_6, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 242, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } @@ -5500,7 +5501,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":239 + /* "mpfmc/core/audio/audio_interface.pyx":240 * * @staticmethod * def db_to_gain(float db): # <<<<<<<<<<<<<< @@ -5523,7 +5524,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":244 +/* "mpfmc/core/audio/audio_interface.pyx":245 * * @staticmethod * def string_to_gain(gain): # <<<<<<<<<<<<<< @@ -5562,7 +5563,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface else goto __pyx_L5_argtuple_error; } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "string_to_gain") < 0)) __PYX_ERR(0, 244, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "string_to_gain") < 0)) __PYX_ERR(0, 245, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 1) { goto __pyx_L5_argtuple_error; @@ -5573,7 +5574,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("string_to_gain", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 244, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("string_to_gain", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 245, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("mpfmc.core.audio.audio_interface.AudioInterface.string_to_gain", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -5587,7 +5588,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } static PyObject *__pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_gain_2generator(__pyx_CoroutineObject *__pyx_generator, CYTHON_UNUSED PyThreadState *__pyx_tstate, PyObject *__pyx_sent_value); /* proto */ -/* "mpfmc/core/audio/audio_interface.pyx":249 +/* "mpfmc/core/audio/audio_interface.pyx":250 * * if gain_string.endswith('DB'): * gain_string = ''.join(i for i in gain_string if not i.isalpha()) # <<<<<<<<<<<<<< @@ -5607,7 +5608,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface if (unlikely(!__pyx_cur_scope)) { __pyx_cur_scope = ((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_1_genexpr *)Py_None); __Pyx_INCREF(Py_None); - __PYX_ERR(0, 249, __pyx_L1_error) + __PYX_ERR(0, 250, __pyx_L1_error) } else { __Pyx_GOTREF(__pyx_cur_scope); } @@ -5615,7 +5616,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(((PyObject *)__pyx_cur_scope->__pyx_outer_scope)); __Pyx_GIVEREF(__pyx_cur_scope->__pyx_outer_scope); { - __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_gain_2generator, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_string_to_gain_locals_genexpr, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!gen)) __PYX_ERR(0, 249, __pyx_L1_error) + __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_gain_2generator, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_string_to_gain_locals_genexpr, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!gen)) __PYX_ERR(0, 250, __pyx_L1_error) __Pyx_DECREF(__pyx_cur_scope); __Pyx_RefNannyFinishContext(); return (PyObject *) gen; @@ -5657,26 +5658,26 @@ static PyObject *__pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return NULL; } __pyx_L3_first_run:; - if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 249, __pyx_L1_error) - __pyx_r = PyList_New(0); if (unlikely(!__pyx_r)) __PYX_ERR(0, 249, __pyx_L1_error) + if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 250, __pyx_L1_error) + __pyx_r = PyList_New(0); if (unlikely(!__pyx_r)) __PYX_ERR(0, 250, __pyx_L1_error) __Pyx_GOTREF(__pyx_r); - if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_gain_string)) { __Pyx_RaiseClosureNameError("gain_string"); __PYX_ERR(0, 249, __pyx_L1_error) } + if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_gain_string)) { __Pyx_RaiseClosureNameError("gain_string"); __PYX_ERR(0, 250, __pyx_L1_error) } if (unlikely(__pyx_cur_scope->__pyx_outer_scope->__pyx_v_gain_string == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' is not iterable"); - __PYX_ERR(0, 249, __pyx_L1_error) + __PYX_ERR(0, 250, __pyx_L1_error) } __Pyx_INCREF(__pyx_cur_scope->__pyx_outer_scope->__pyx_v_gain_string); __pyx_t_1 = __pyx_cur_scope->__pyx_outer_scope->__pyx_v_gain_string; - __pyx_t_6 = __Pyx_init_unicode_iteration(__pyx_t_1, (&__pyx_t_3), (&__pyx_t_4), (&__pyx_t_5)); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 249, __pyx_L1_error) + __pyx_t_6 = __Pyx_init_unicode_iteration(__pyx_t_1, (&__pyx_t_3), (&__pyx_t_4), (&__pyx_t_5)); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 250, __pyx_L1_error) for (__pyx_t_7 = 0; __pyx_t_7 < __pyx_t_3; __pyx_t_7++) { __pyx_t_2 = __pyx_t_7; __pyx_cur_scope->__pyx_v_i = __Pyx_PyUnicode_READ(__pyx_t_5, __pyx_t_4, __pyx_t_2); __pyx_t_8 = Py_UNICODE_ISALPHA(__pyx_cur_scope->__pyx_v_i); __pyx_t_9 = ((!(__pyx_t_8 != 0)) != 0); if (__pyx_t_9) { - __pyx_t_10 = PyUnicode_FromOrdinal(__pyx_cur_scope->__pyx_v_i); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 249, __pyx_L1_error) + __pyx_t_10 = PyUnicode_FromOrdinal(__pyx_cur_scope->__pyx_v_i); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 250, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); - if (unlikely(__Pyx_ListComp_Append(__pyx_r, (PyObject*)__pyx_t_10))) __PYX_ERR(0, 249, __pyx_L1_error) + if (unlikely(__Pyx_ListComp_Append(__pyx_r, (PyObject*)__pyx_t_10))) __PYX_ERR(0, 250, __pyx_L1_error) __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } } @@ -5701,7 +5702,7 @@ static PyObject *__pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":244 +/* "mpfmc/core/audio/audio_interface.pyx":245 * * @staticmethod * def string_to_gain(gain): # <<<<<<<<<<<<<< @@ -5730,21 +5731,21 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface if (unlikely(!__pyx_cur_scope)) { __pyx_cur_scope = ((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct__string_to_gain *)Py_None); __Pyx_INCREF(Py_None); - __PYX_ERR(0, 244, __pyx_L1_error) + __PYX_ERR(0, 245, __pyx_L1_error) } else { __Pyx_GOTREF(__pyx_cur_scope); } - /* "mpfmc/core/audio/audio_interface.pyx":246 + /* "mpfmc/core/audio/audio_interface.pyx":247 * def string_to_gain(gain): * """Converts a string to a gain value (0.0 to 1.0)""" * cdef str gain_string = str(gain).upper() # <<<<<<<<<<<<<< * * if gain_string.endswith('DB'): */ - __pyx_t_2 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyUnicode_Type)), __pyx_v_gain); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 246, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyUnicode_Type)), __pyx_v_gain); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 247, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_upper); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 246, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_upper); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 247, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; @@ -5759,15 +5760,15 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 246, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 247, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (!(likely(PyUnicode_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(0, 246, __pyx_L1_error) + if (!(likely(PyUnicode_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(0, 247, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __pyx_cur_scope->__pyx_v_gain_string = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":248 + /* "mpfmc/core/audio/audio_interface.pyx":249 * cdef str gain_string = str(gain).upper() * * if gain_string.endswith('DB'): # <<<<<<<<<<<<<< @@ -5776,24 +5777,24 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_cur_scope->__pyx_v_gain_string == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "endswith"); - __PYX_ERR(0, 248, __pyx_L1_error) + __PYX_ERR(0, 249, __pyx_L1_error) } - __pyx_t_4 = __Pyx_PyUnicode_Tailmatch(__pyx_cur_scope->__pyx_v_gain_string, __pyx_n_u_DB, 0, PY_SSIZE_T_MAX, 1); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(0, 248, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyUnicode_Tailmatch(__pyx_cur_scope->__pyx_v_gain_string, __pyx_n_u_DB, 0, PY_SSIZE_T_MAX, 1); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(0, 249, __pyx_L1_error) if ((__pyx_t_4 != 0)) { - /* "mpfmc/core/audio/audio_interface.pyx":249 + /* "mpfmc/core/audio/audio_interface.pyx":250 * * if gain_string.endswith('DB'): * gain_string = ''.join(i for i in gain_string if not i.isalpha()) # <<<<<<<<<<<<<< * return min(max(AudioInterface.db_to_gain(float(gain_string)), 0.0), 1.0) * */ - __pyx_t_1 = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_gain_genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 249, __pyx_L1_error) + __pyx_t_1 = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_gain_genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 250, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = __Pyx_Generator_Next(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 249, __pyx_L1_error) + __pyx_t_3 = __Pyx_Generator_Next(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 250, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = PyUnicode_Join(__pyx_kp_u_, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 249, __pyx_L1_error) + __pyx_t_1 = PyUnicode_Join(__pyx_kp_u_, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 250, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_cur_scope->__pyx_v_gain_string); @@ -5801,7 +5802,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_GIVEREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":250 + /* "mpfmc/core/audio/audio_interface.pyx":251 * if gain_string.endswith('DB'): * gain_string = ''.join(i for i in gain_string if not i.isalpha()) * return min(max(AudioInterface.db_to_gain(float(gain_string)), 0.0), 1.0) # <<<<<<<<<<<<<< @@ -5811,9 +5812,9 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_XDECREF(__pyx_r); __pyx_t_5 = 1.0; __pyx_t_6 = 0.0; - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface), __pyx_n_s_db_to_gain); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 250, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface), __pyx_n_s_db_to_gain); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 251, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_2 = __Pyx_PyNumber_Float(__pyx_cur_scope->__pyx_v_gain_string); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 250, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyNumber_Float(__pyx_cur_scope->__pyx_v_gain_string); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 251, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -5828,17 +5829,17 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_1 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_7, __pyx_t_2) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2); __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 250, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 251, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_2 = PyFloat_FromDouble(__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 250, __pyx_L1_error) + __pyx_t_2 = PyFloat_FromDouble(__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 251, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_7 = PyObject_RichCompare(__pyx_t_2, __pyx_t_1, Py_GT); __Pyx_XGOTREF(__pyx_t_7); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 250, __pyx_L1_error) + __pyx_t_7 = PyObject_RichCompare(__pyx_t_2, __pyx_t_1, Py_GT); __Pyx_XGOTREF(__pyx_t_7); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 251, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_7); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(0, 250, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_7); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(0, 251, __pyx_L1_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (__pyx_t_4) { - __pyx_t_7 = PyFloat_FromDouble(__pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 250, __pyx_L1_error) + __pyx_t_7 = PyFloat_FromDouble(__pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 251, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_3 = __pyx_t_7; __pyx_t_7 = 0; @@ -5850,14 +5851,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(__pyx_t_3); __pyx_t_1 = __pyx_t_3; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - __pyx_t_7 = PyFloat_FromDouble(__pyx_t_5); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 250, __pyx_L1_error) + __pyx_t_7 = PyFloat_FromDouble(__pyx_t_5); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 251, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); - __pyx_t_2 = PyObject_RichCompare(__pyx_t_7, __pyx_t_1, Py_LT); __Pyx_XGOTREF(__pyx_t_2); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 250, __pyx_L1_error) + __pyx_t_2 = PyObject_RichCompare(__pyx_t_7, __pyx_t_1, Py_LT); __Pyx_XGOTREF(__pyx_t_2); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 251, __pyx_L1_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; - __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(0, 250, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(0, 251, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (__pyx_t_4) { - __pyx_t_2 = PyFloat_FromDouble(__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 250, __pyx_L1_error) + __pyx_t_2 = PyFloat_FromDouble(__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 251, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = __pyx_t_2; __pyx_t_2 = 0; @@ -5871,7 +5872,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":248 + /* "mpfmc/core/audio/audio_interface.pyx":249 * cdef str gain_string = str(gain).upper() * * if gain_string.endswith('DB'): # <<<<<<<<<<<<<< @@ -5880,7 +5881,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":252 + /* "mpfmc/core/audio/audio_interface.pyx":253 * return min(max(AudioInterface.db_to_gain(float(gain_string)), 0.0), 1.0) * * return min(max(float(gain_string), 0.0), 1.0) # <<<<<<<<<<<<<< @@ -5890,7 +5891,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_XDECREF(__pyx_r); __pyx_t_5 = 1.0; __pyx_t_6 = 0.0; - __pyx_t_8 = __Pyx_PyObject_AsDouble(__pyx_cur_scope->__pyx_v_gain_string); if (unlikely(__pyx_t_8 == ((double)((double)-1)) && PyErr_Occurred())) __PYX_ERR(0, 252, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_AsDouble(__pyx_cur_scope->__pyx_v_gain_string); if (unlikely(__pyx_t_8 == ((double)((double)-1)) && PyErr_Occurred())) __PYX_ERR(0, 253, __pyx_L1_error) if (((__pyx_t_6 > __pyx_t_8) != 0)) { __pyx_t_9 = __pyx_t_6; } else { @@ -5902,13 +5903,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } else { __pyx_t_9 = __pyx_t_6; } - __pyx_t_3 = PyFloat_FromDouble(__pyx_t_9); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 252, __pyx_L1_error) + __pyx_t_3 = PyFloat_FromDouble(__pyx_t_9); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 253, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_r = __pyx_t_3; __pyx_t_3 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":244 + /* "mpfmc/core/audio/audio_interface.pyx":245 * * @staticmethod * def string_to_gain(gain): # <<<<<<<<<<<<<< @@ -5931,7 +5932,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":254 +/* "mpfmc/core/audio/audio_interface.pyx":255 * return min(max(float(gain_string), 0.0), 1.0) * * def convert_seconds_to_samples(self, float seconds): # <<<<<<<<<<<<<< @@ -5951,7 +5952,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("convert_seconds_to_samples (wrapper)", 0); assert(__pyx_arg_seconds); { - __pyx_v_seconds = __pyx_PyFloat_AsFloat(__pyx_arg_seconds); if (unlikely((__pyx_v_seconds == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 254, __pyx_L3_error) + __pyx_v_seconds = __pyx_PyFloat_AsFloat(__pyx_arg_seconds); if (unlikely((__pyx_v_seconds == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 255, __pyx_L3_error) } goto __pyx_L4_argument_unpacking_done; __pyx_L3_error:; @@ -5975,7 +5976,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("convert_seconds_to_samples", 0); - /* "mpfmc/core/audio/audio_interface.pyx":256 + /* "mpfmc/core/audio/audio_interface.pyx":257 * def convert_seconds_to_samples(self, float seconds): * """Converts the specified number of seconds into samples (based on current sample rate)""" * return int(self.audio_callback_data.sample_rate * seconds) # <<<<<<<<<<<<<< @@ -5983,13 +5984,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * def convert_seconds_to_buffer_length(self, float seconds): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyInt_FromDouble((__pyx_v_self->audio_callback_data.sample_rate * __pyx_v_seconds)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 256, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_FromDouble((__pyx_v_self->audio_callback_data.sample_rate * __pyx_v_seconds)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 257, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":254 + /* "mpfmc/core/audio/audio_interface.pyx":255 * return min(max(float(gain_string), 0.0), 1.0) * * def convert_seconds_to_samples(self, float seconds): # <<<<<<<<<<<<<< @@ -6008,7 +6009,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":258 +/* "mpfmc/core/audio/audio_interface.pyx":259 * return int(self.audio_callback_data.sample_rate * seconds) * * def convert_seconds_to_buffer_length(self, float seconds): # <<<<<<<<<<<<<< @@ -6028,7 +6029,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("convert_seconds_to_buffer_length (wrapper)", 0); assert(__pyx_arg_seconds); { - __pyx_v_seconds = __pyx_PyFloat_AsFloat(__pyx_arg_seconds); if (unlikely((__pyx_v_seconds == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 258, __pyx_L3_error) + __pyx_v_seconds = __pyx_PyFloat_AsFloat(__pyx_arg_seconds); if (unlikely((__pyx_v_seconds == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 259, __pyx_L3_error) } goto __pyx_L4_argument_unpacking_done; __pyx_L3_error:; @@ -6052,7 +6053,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("convert_seconds_to_buffer_length", 0); - /* "mpfmc/core/audio/audio_interface.pyx":261 + /* "mpfmc/core/audio/audio_interface.pyx":262 * """Convert the specified number of seconds into a buffer length (based on current * sample rate, the number of audio channels, and the number of bytes per sample).""" * return int(seconds * self.audio_callback_data.sample_rate * self.audio_callback_data.channels * self.audio_callback_data.bytes_per_sample) # <<<<<<<<<<<<<< @@ -6060,13 +6061,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * def convert_buffer_length_to_seconds(self, int buffer_length): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyInt_FromDouble((((__pyx_v_seconds * __pyx_v_self->audio_callback_data.sample_rate) * __pyx_v_self->audio_callback_data.channels) * __pyx_v_self->audio_callback_data.bytes_per_sample)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 261, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_FromDouble((((__pyx_v_seconds * __pyx_v_self->audio_callback_data.sample_rate) * __pyx_v_self->audio_callback_data.channels) * __pyx_v_self->audio_callback_data.bytes_per_sample)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 262, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":258 + /* "mpfmc/core/audio/audio_interface.pyx":259 * return int(self.audio_callback_data.sample_rate * seconds) * * def convert_seconds_to_buffer_length(self, float seconds): # <<<<<<<<<<<<<< @@ -6085,7 +6086,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":263 +/* "mpfmc/core/audio/audio_interface.pyx":264 * return int(seconds * self.audio_callback_data.sample_rate * self.audio_callback_data.channels * self.audio_callback_data.bytes_per_sample) * * def convert_buffer_length_to_seconds(self, int buffer_length): # <<<<<<<<<<<<<< @@ -6105,7 +6106,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("convert_buffer_length_to_seconds (wrapper)", 0); assert(__pyx_arg_buffer_length); { - __pyx_v_buffer_length = __Pyx_PyInt_As_int(__pyx_arg_buffer_length); if (unlikely((__pyx_v_buffer_length == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 263, __pyx_L3_error) + __pyx_v_buffer_length = __Pyx_PyInt_As_int(__pyx_arg_buffer_length); if (unlikely((__pyx_v_buffer_length == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 264, __pyx_L3_error) } goto __pyx_L4_argument_unpacking_done; __pyx_L3_error:; @@ -6131,7 +6132,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("convert_buffer_length_to_seconds", 0); - /* "mpfmc/core/audio/audio_interface.pyx":266 + /* "mpfmc/core/audio/audio_interface.pyx":267 * """Convert the specified buffer length into a time in seconds (based on current * sample rate, the number of audio channels, and the number of bytes per sample).""" * return round(buffer_length / (self.audio_callback_data.sample_rate * self.audio_callback_data.channels * self.audio_callback_data.bytes_per_sample), 3) # <<<<<<<<<<<<<< @@ -6142,11 +6143,11 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_1 = ((__pyx_v_self->audio_callback_data.sample_rate * __pyx_v_self->audio_callback_data.channels) * __pyx_v_self->audio_callback_data.bytes_per_sample); if (unlikely(__pyx_t_1 == 0)) { PyErr_SetString(PyExc_ZeroDivisionError, "float division"); - __PYX_ERR(0, 266, __pyx_L1_error) + __PYX_ERR(0, 267, __pyx_L1_error) } - __pyx_t_2 = PyFloat_FromDouble((((double)__pyx_v_buffer_length) / ((double)__pyx_t_1))); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 266, __pyx_L1_error) + __pyx_t_2 = PyFloat_FromDouble((((double)__pyx_v_buffer_length) / ((double)__pyx_t_1))); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 267, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 266, __pyx_L1_error) + __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 267, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); @@ -6154,14 +6155,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_GIVEREF(__pyx_int_3); PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_3); __pyx_t_2 = 0; - __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_round, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 266, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_round, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 267, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":263 + /* "mpfmc/core/audio/audio_interface.pyx":264 * return int(seconds * self.audio_callback_data.sample_rate * self.audio_callback_data.channels * self.audio_callback_data.bytes_per_sample) * * def convert_buffer_length_to_seconds(self, int buffer_length): # <<<<<<<<<<<<<< @@ -6181,7 +6182,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":269 +/* "mpfmc/core/audio/audio_interface.pyx":270 * * @staticmethod * def string_to_secs(time): # <<<<<<<<<<<<<< @@ -6220,7 +6221,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface else goto __pyx_L5_argtuple_error; } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "string_to_secs") < 0)) __PYX_ERR(0, 269, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "string_to_secs") < 0)) __PYX_ERR(0, 270, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 1) { goto __pyx_L5_argtuple_error; @@ -6231,7 +6232,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("string_to_secs", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 269, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("string_to_secs", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 270, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("mpfmc.core.audio.audio_interface.AudioInterface.string_to_secs", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -6245,7 +6246,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } static PyObject *__pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_2generator1(__pyx_CoroutineObject *__pyx_generator, CYTHON_UNUSED PyThreadState *__pyx_tstate, PyObject *__pyx_sent_value); /* proto */ -/* "mpfmc/core/audio/audio_interface.pyx":288 +/* "mpfmc/core/audio/audio_interface.pyx":289 * * if time_string.endswith('MS') or time_string.endswith('MSEC'): * time_string = ''.join(i for i in time_string if not i.isalpha()) # <<<<<<<<<<<<<< @@ -6265,7 +6266,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface if (unlikely(!__pyx_cur_scope)) { __pyx_cur_scope = ((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_3_genexpr *)Py_None); __Pyx_INCREF(Py_None); - __PYX_ERR(0, 288, __pyx_L1_error) + __PYX_ERR(0, 289, __pyx_L1_error) } else { __Pyx_GOTREF(__pyx_cur_scope); } @@ -6273,7 +6274,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(((PyObject *)__pyx_cur_scope->__pyx_outer_scope)); __Pyx_GIVEREF(__pyx_cur_scope->__pyx_outer_scope); { - __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_2generator1, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_string_to_secs_locals_genexpr, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!gen)) __PYX_ERR(0, 288, __pyx_L1_error) + __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_2generator1, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_string_to_secs_locals_genexpr, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!gen)) __PYX_ERR(0, 289, __pyx_L1_error) __Pyx_DECREF(__pyx_cur_scope); __Pyx_RefNannyFinishContext(); return (PyObject *) gen; @@ -6315,26 +6316,26 @@ static PyObject *__pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return NULL; } __pyx_L3_first_run:; - if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 288, __pyx_L1_error) - __pyx_r = PyList_New(0); if (unlikely(!__pyx_r)) __PYX_ERR(0, 288, __pyx_L1_error) + if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 289, __pyx_L1_error) + __pyx_r = PyList_New(0); if (unlikely(!__pyx_r)) __PYX_ERR(0, 289, __pyx_L1_error) __Pyx_GOTREF(__pyx_r); - if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string)) { __Pyx_RaiseClosureNameError("time_string"); __PYX_ERR(0, 288, __pyx_L1_error) } + if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string)) { __Pyx_RaiseClosureNameError("time_string"); __PYX_ERR(0, 289, __pyx_L1_error) } if (unlikely(__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' is not iterable"); - __PYX_ERR(0, 288, __pyx_L1_error) + __PYX_ERR(0, 289, __pyx_L1_error) } __Pyx_INCREF(__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string); __pyx_t_1 = __pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string; - __pyx_t_6 = __Pyx_init_unicode_iteration(__pyx_t_1, (&__pyx_t_3), (&__pyx_t_4), (&__pyx_t_5)); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 288, __pyx_L1_error) + __pyx_t_6 = __Pyx_init_unicode_iteration(__pyx_t_1, (&__pyx_t_3), (&__pyx_t_4), (&__pyx_t_5)); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 289, __pyx_L1_error) for (__pyx_t_7 = 0; __pyx_t_7 < __pyx_t_3; __pyx_t_7++) { __pyx_t_2 = __pyx_t_7; __pyx_cur_scope->__pyx_v_i = __Pyx_PyUnicode_READ(__pyx_t_5, __pyx_t_4, __pyx_t_2); __pyx_t_8 = Py_UNICODE_ISALPHA(__pyx_cur_scope->__pyx_v_i); __pyx_t_9 = ((!(__pyx_t_8 != 0)) != 0); if (__pyx_t_9) { - __pyx_t_10 = PyUnicode_FromOrdinal(__pyx_cur_scope->__pyx_v_i); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 288, __pyx_L1_error) + __pyx_t_10 = PyUnicode_FromOrdinal(__pyx_cur_scope->__pyx_v_i); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 289, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); - if (unlikely(__Pyx_ListComp_Append(__pyx_r, (PyObject*)__pyx_t_10))) __PYX_ERR(0, 288, __pyx_L1_error) + if (unlikely(__Pyx_ListComp_Append(__pyx_r, (PyObject*)__pyx_t_10))) __PYX_ERR(0, 289, __pyx_L1_error) __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } } @@ -6360,7 +6361,7 @@ static PyObject *__pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } static PyObject *__pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_5generator2(__pyx_CoroutineObject *__pyx_generator, CYTHON_UNUSED PyThreadState *__pyx_tstate, PyObject *__pyx_sent_value); /* proto */ -/* "mpfmc/core/audio/audio_interface.pyx":292 +/* "mpfmc/core/audio/audio_interface.pyx":293 * * elif time_string.endswith('S') or time_string.endswith('SEC'): * time_string = ''.join(i for i in time_string if not i.isalpha()) # <<<<<<<<<<<<<< @@ -6380,7 +6381,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface if (unlikely(!__pyx_cur_scope)) { __pyx_cur_scope = ((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_4_genexpr *)Py_None); __Pyx_INCREF(Py_None); - __PYX_ERR(0, 292, __pyx_L1_error) + __PYX_ERR(0, 293, __pyx_L1_error) } else { __Pyx_GOTREF(__pyx_cur_scope); } @@ -6388,7 +6389,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(((PyObject *)__pyx_cur_scope->__pyx_outer_scope)); __Pyx_GIVEREF(__pyx_cur_scope->__pyx_outer_scope); { - __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_5generator2, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_string_to_secs_locals_genexpr, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!gen)) __PYX_ERR(0, 292, __pyx_L1_error) + __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_5generator2, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_string_to_secs_locals_genexpr, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!gen)) __PYX_ERR(0, 293, __pyx_L1_error) __Pyx_DECREF(__pyx_cur_scope); __Pyx_RefNannyFinishContext(); return (PyObject *) gen; @@ -6430,26 +6431,26 @@ static PyObject *__pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return NULL; } __pyx_L3_first_run:; - if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 292, __pyx_L1_error) - __pyx_r = PyList_New(0); if (unlikely(!__pyx_r)) __PYX_ERR(0, 292, __pyx_L1_error) + if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 293, __pyx_L1_error) + __pyx_r = PyList_New(0); if (unlikely(!__pyx_r)) __PYX_ERR(0, 293, __pyx_L1_error) __Pyx_GOTREF(__pyx_r); - if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string)) { __Pyx_RaiseClosureNameError("time_string"); __PYX_ERR(0, 292, __pyx_L1_error) } + if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string)) { __Pyx_RaiseClosureNameError("time_string"); __PYX_ERR(0, 293, __pyx_L1_error) } if (unlikely(__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' is not iterable"); - __PYX_ERR(0, 292, __pyx_L1_error) + __PYX_ERR(0, 293, __pyx_L1_error) } __Pyx_INCREF(__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string); __pyx_t_1 = __pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string; - __pyx_t_6 = __Pyx_init_unicode_iteration(__pyx_t_1, (&__pyx_t_3), (&__pyx_t_4), (&__pyx_t_5)); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 292, __pyx_L1_error) + __pyx_t_6 = __Pyx_init_unicode_iteration(__pyx_t_1, (&__pyx_t_3), (&__pyx_t_4), (&__pyx_t_5)); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 293, __pyx_L1_error) for (__pyx_t_7 = 0; __pyx_t_7 < __pyx_t_3; __pyx_t_7++) { __pyx_t_2 = __pyx_t_7; __pyx_cur_scope->__pyx_v_i = __Pyx_PyUnicode_READ(__pyx_t_5, __pyx_t_4, __pyx_t_2); __pyx_t_8 = Py_UNICODE_ISALPHA(__pyx_cur_scope->__pyx_v_i); __pyx_t_9 = ((!(__pyx_t_8 != 0)) != 0); if (__pyx_t_9) { - __pyx_t_10 = PyUnicode_FromOrdinal(__pyx_cur_scope->__pyx_v_i); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 292, __pyx_L1_error) + __pyx_t_10 = PyUnicode_FromOrdinal(__pyx_cur_scope->__pyx_v_i); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 293, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); - if (unlikely(__Pyx_ListComp_Append(__pyx_r, (PyObject*)__pyx_t_10))) __PYX_ERR(0, 292, __pyx_L1_error) + if (unlikely(__Pyx_ListComp_Append(__pyx_r, (PyObject*)__pyx_t_10))) __PYX_ERR(0, 293, __pyx_L1_error) __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } } @@ -6475,7 +6476,7 @@ static PyObject *__pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } static PyObject *__pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_8generator3(__pyx_CoroutineObject *__pyx_generator, CYTHON_UNUSED PyThreadState *__pyx_tstate, PyObject *__pyx_sent_value); /* proto */ -/* "mpfmc/core/audio/audio_interface.pyx":296 +/* "mpfmc/core/audio/audio_interface.pyx":297 * * elif 'D' in time_string: * time_string = ''.join(i for i in time_string if not i.isalpha()) # <<<<<<<<<<<<<< @@ -6495,7 +6496,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface if (unlikely(!__pyx_cur_scope)) { __pyx_cur_scope = ((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_5_genexpr *)Py_None); __Pyx_INCREF(Py_None); - __PYX_ERR(0, 296, __pyx_L1_error) + __PYX_ERR(0, 297, __pyx_L1_error) } else { __Pyx_GOTREF(__pyx_cur_scope); } @@ -6503,7 +6504,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(((PyObject *)__pyx_cur_scope->__pyx_outer_scope)); __Pyx_GIVEREF(__pyx_cur_scope->__pyx_outer_scope); { - __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_8generator3, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_string_to_secs_locals_genexpr, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!gen)) __PYX_ERR(0, 296, __pyx_L1_error) + __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_8generator3, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_string_to_secs_locals_genexpr, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!gen)) __PYX_ERR(0, 297, __pyx_L1_error) __Pyx_DECREF(__pyx_cur_scope); __Pyx_RefNannyFinishContext(); return (PyObject *) gen; @@ -6545,26 +6546,26 @@ static PyObject *__pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return NULL; } __pyx_L3_first_run:; - if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 296, __pyx_L1_error) - __pyx_r = PyList_New(0); if (unlikely(!__pyx_r)) __PYX_ERR(0, 296, __pyx_L1_error) + if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 297, __pyx_L1_error) + __pyx_r = PyList_New(0); if (unlikely(!__pyx_r)) __PYX_ERR(0, 297, __pyx_L1_error) __Pyx_GOTREF(__pyx_r); - if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string)) { __Pyx_RaiseClosureNameError("time_string"); __PYX_ERR(0, 296, __pyx_L1_error) } + if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string)) { __Pyx_RaiseClosureNameError("time_string"); __PYX_ERR(0, 297, __pyx_L1_error) } if (unlikely(__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' is not iterable"); - __PYX_ERR(0, 296, __pyx_L1_error) + __PYX_ERR(0, 297, __pyx_L1_error) } __Pyx_INCREF(__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string); __pyx_t_1 = __pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string; - __pyx_t_6 = __Pyx_init_unicode_iteration(__pyx_t_1, (&__pyx_t_3), (&__pyx_t_4), (&__pyx_t_5)); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 296, __pyx_L1_error) + __pyx_t_6 = __Pyx_init_unicode_iteration(__pyx_t_1, (&__pyx_t_3), (&__pyx_t_4), (&__pyx_t_5)); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 297, __pyx_L1_error) for (__pyx_t_7 = 0; __pyx_t_7 < __pyx_t_3; __pyx_t_7++) { __pyx_t_2 = __pyx_t_7; __pyx_cur_scope->__pyx_v_i = __Pyx_PyUnicode_READ(__pyx_t_5, __pyx_t_4, __pyx_t_2); __pyx_t_8 = Py_UNICODE_ISALPHA(__pyx_cur_scope->__pyx_v_i); __pyx_t_9 = ((!(__pyx_t_8 != 0)) != 0); if (__pyx_t_9) { - __pyx_t_10 = PyUnicode_FromOrdinal(__pyx_cur_scope->__pyx_v_i); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 296, __pyx_L1_error) + __pyx_t_10 = PyUnicode_FromOrdinal(__pyx_cur_scope->__pyx_v_i); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 297, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); - if (unlikely(__Pyx_ListComp_Append(__pyx_r, (PyObject*)__pyx_t_10))) __PYX_ERR(0, 296, __pyx_L1_error) + if (unlikely(__Pyx_ListComp_Append(__pyx_r, (PyObject*)__pyx_t_10))) __PYX_ERR(0, 297, __pyx_L1_error) __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } } @@ -6590,7 +6591,7 @@ static PyObject *__pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } static PyObject *__pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_11generator4(__pyx_CoroutineObject *__pyx_generator, CYTHON_UNUSED PyThreadState *__pyx_tstate, PyObject *__pyx_sent_value); /* proto */ -/* "mpfmc/core/audio/audio_interface.pyx":300 +/* "mpfmc/core/audio/audio_interface.pyx":301 * * elif 'H' in time_string: * time_string = ''.join(i for i in time_string if not i.isalpha()) # <<<<<<<<<<<<<< @@ -6610,7 +6611,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface if (unlikely(!__pyx_cur_scope)) { __pyx_cur_scope = ((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_6_genexpr *)Py_None); __Pyx_INCREF(Py_None); - __PYX_ERR(0, 300, __pyx_L1_error) + __PYX_ERR(0, 301, __pyx_L1_error) } else { __Pyx_GOTREF(__pyx_cur_scope); } @@ -6618,7 +6619,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(((PyObject *)__pyx_cur_scope->__pyx_outer_scope)); __Pyx_GIVEREF(__pyx_cur_scope->__pyx_outer_scope); { - __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_11generator4, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_string_to_secs_locals_genexpr, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!gen)) __PYX_ERR(0, 300, __pyx_L1_error) + __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_11generator4, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_string_to_secs_locals_genexpr, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!gen)) __PYX_ERR(0, 301, __pyx_L1_error) __Pyx_DECREF(__pyx_cur_scope); __Pyx_RefNannyFinishContext(); return (PyObject *) gen; @@ -6660,26 +6661,26 @@ static PyObject *__pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return NULL; } __pyx_L3_first_run:; - if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 300, __pyx_L1_error) - __pyx_r = PyList_New(0); if (unlikely(!__pyx_r)) __PYX_ERR(0, 300, __pyx_L1_error) + if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 301, __pyx_L1_error) + __pyx_r = PyList_New(0); if (unlikely(!__pyx_r)) __PYX_ERR(0, 301, __pyx_L1_error) __Pyx_GOTREF(__pyx_r); - if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string)) { __Pyx_RaiseClosureNameError("time_string"); __PYX_ERR(0, 300, __pyx_L1_error) } + if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string)) { __Pyx_RaiseClosureNameError("time_string"); __PYX_ERR(0, 301, __pyx_L1_error) } if (unlikely(__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' is not iterable"); - __PYX_ERR(0, 300, __pyx_L1_error) + __PYX_ERR(0, 301, __pyx_L1_error) } __Pyx_INCREF(__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string); __pyx_t_1 = __pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string; - __pyx_t_6 = __Pyx_init_unicode_iteration(__pyx_t_1, (&__pyx_t_3), (&__pyx_t_4), (&__pyx_t_5)); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 300, __pyx_L1_error) + __pyx_t_6 = __Pyx_init_unicode_iteration(__pyx_t_1, (&__pyx_t_3), (&__pyx_t_4), (&__pyx_t_5)); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 301, __pyx_L1_error) for (__pyx_t_7 = 0; __pyx_t_7 < __pyx_t_3; __pyx_t_7++) { __pyx_t_2 = __pyx_t_7; __pyx_cur_scope->__pyx_v_i = __Pyx_PyUnicode_READ(__pyx_t_5, __pyx_t_4, __pyx_t_2); __pyx_t_8 = Py_UNICODE_ISALPHA(__pyx_cur_scope->__pyx_v_i); __pyx_t_9 = ((!(__pyx_t_8 != 0)) != 0); if (__pyx_t_9) { - __pyx_t_10 = PyUnicode_FromOrdinal(__pyx_cur_scope->__pyx_v_i); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 300, __pyx_L1_error) + __pyx_t_10 = PyUnicode_FromOrdinal(__pyx_cur_scope->__pyx_v_i); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 301, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); - if (unlikely(__Pyx_ListComp_Append(__pyx_r, (PyObject*)__pyx_t_10))) __PYX_ERR(0, 300, __pyx_L1_error) + if (unlikely(__Pyx_ListComp_Append(__pyx_r, (PyObject*)__pyx_t_10))) __PYX_ERR(0, 301, __pyx_L1_error) __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } } @@ -6705,7 +6706,7 @@ static PyObject *__pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } static PyObject *__pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_14generator5(__pyx_CoroutineObject *__pyx_generator, CYTHON_UNUSED PyThreadState *__pyx_tstate, PyObject *__pyx_sent_value); /* proto */ -/* "mpfmc/core/audio/audio_interface.pyx":304 +/* "mpfmc/core/audio/audio_interface.pyx":305 * * elif 'M' in time_string: * time_string = ''.join(i for i in time_string if not i.isalpha()) # <<<<<<<<<<<<<< @@ -6725,7 +6726,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface if (unlikely(!__pyx_cur_scope)) { __pyx_cur_scope = ((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_7_genexpr *)Py_None); __Pyx_INCREF(Py_None); - __PYX_ERR(0, 304, __pyx_L1_error) + __PYX_ERR(0, 305, __pyx_L1_error) } else { __Pyx_GOTREF(__pyx_cur_scope); } @@ -6733,7 +6734,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(((PyObject *)__pyx_cur_scope->__pyx_outer_scope)); __Pyx_GIVEREF(__pyx_cur_scope->__pyx_outer_scope); { - __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_14generator5, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_string_to_secs_locals_genexpr, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!gen)) __PYX_ERR(0, 304, __pyx_L1_error) + __pyx_CoroutineObject *gen = __Pyx_Generator_New((__pyx_coroutine_body_t) __pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_14generator5, NULL, (PyObject *) __pyx_cur_scope, __pyx_n_s_genexpr, __pyx_n_s_string_to_secs_locals_genexpr, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!gen)) __PYX_ERR(0, 305, __pyx_L1_error) __Pyx_DECREF(__pyx_cur_scope); __Pyx_RefNannyFinishContext(); return (PyObject *) gen; @@ -6775,26 +6776,26 @@ static PyObject *__pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return NULL; } __pyx_L3_first_run:; - if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 304, __pyx_L1_error) - __pyx_r = PyList_New(0); if (unlikely(!__pyx_r)) __PYX_ERR(0, 304, __pyx_L1_error) + if (unlikely(!__pyx_sent_value)) __PYX_ERR(0, 305, __pyx_L1_error) + __pyx_r = PyList_New(0); if (unlikely(!__pyx_r)) __PYX_ERR(0, 305, __pyx_L1_error) __Pyx_GOTREF(__pyx_r); - if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string)) { __Pyx_RaiseClosureNameError("time_string"); __PYX_ERR(0, 304, __pyx_L1_error) } + if (unlikely(!__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string)) { __Pyx_RaiseClosureNameError("time_string"); __PYX_ERR(0, 305, __pyx_L1_error) } if (unlikely(__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' is not iterable"); - __PYX_ERR(0, 304, __pyx_L1_error) + __PYX_ERR(0, 305, __pyx_L1_error) } __Pyx_INCREF(__pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string); __pyx_t_1 = __pyx_cur_scope->__pyx_outer_scope->__pyx_v_time_string; - __pyx_t_6 = __Pyx_init_unicode_iteration(__pyx_t_1, (&__pyx_t_3), (&__pyx_t_4), (&__pyx_t_5)); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 304, __pyx_L1_error) + __pyx_t_6 = __Pyx_init_unicode_iteration(__pyx_t_1, (&__pyx_t_3), (&__pyx_t_4), (&__pyx_t_5)); if (unlikely(__pyx_t_6 == ((int)-1))) __PYX_ERR(0, 305, __pyx_L1_error) for (__pyx_t_7 = 0; __pyx_t_7 < __pyx_t_3; __pyx_t_7++) { __pyx_t_2 = __pyx_t_7; __pyx_cur_scope->__pyx_v_i = __Pyx_PyUnicode_READ(__pyx_t_5, __pyx_t_4, __pyx_t_2); __pyx_t_8 = Py_UNICODE_ISALPHA(__pyx_cur_scope->__pyx_v_i); __pyx_t_9 = ((!(__pyx_t_8 != 0)) != 0); if (__pyx_t_9) { - __pyx_t_10 = PyUnicode_FromOrdinal(__pyx_cur_scope->__pyx_v_i); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 304, __pyx_L1_error) + __pyx_t_10 = PyUnicode_FromOrdinal(__pyx_cur_scope->__pyx_v_i); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 305, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); - if (unlikely(__Pyx_ListComp_Append(__pyx_r, (PyObject*)__pyx_t_10))) __PYX_ERR(0, 304, __pyx_L1_error) + if (unlikely(__Pyx_ListComp_Append(__pyx_r, (PyObject*)__pyx_t_10))) __PYX_ERR(0, 305, __pyx_L1_error) __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } } @@ -6819,7 +6820,7 @@ static PyObject *__pyx_gb_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":269 +/* "mpfmc/core/audio/audio_interface.pyx":270 * * @staticmethod * def string_to_secs(time): # <<<<<<<<<<<<<< @@ -6849,21 +6850,21 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface if (unlikely(!__pyx_cur_scope)) { __pyx_cur_scope = ((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_2_string_to_secs *)Py_None); __Pyx_INCREF(Py_None); - __PYX_ERR(0, 269, __pyx_L1_error) + __PYX_ERR(0, 270, __pyx_L1_error) } else { __Pyx_GOTREF(__pyx_cur_scope); } - /* "mpfmc/core/audio/audio_interface.pyx":285 + /* "mpfmc/core/audio/audio_interface.pyx":286 * respectively * """ * cdef str time_string = str(time).upper() # <<<<<<<<<<<<<< * * if time_string.endswith('MS') or time_string.endswith('MSEC'): */ - __pyx_t_2 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyUnicode_Type)), __pyx_v_time); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 285, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyUnicode_Type)), __pyx_v_time); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 286, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_upper); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 285, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_upper); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 286, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; @@ -6878,15 +6879,15 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 285, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 286, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (!(likely(PyUnicode_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(0, 285, __pyx_L1_error) + if (!(likely(PyUnicode_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(0, 286, __pyx_L1_error) __Pyx_GIVEREF(__pyx_t_1); __pyx_cur_scope->__pyx_v_time_string = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":287 + /* "mpfmc/core/audio/audio_interface.pyx":288 * cdef str time_string = str(time).upper() * * if time_string.endswith('MS') or time_string.endswith('MSEC'): # <<<<<<<<<<<<<< @@ -6895,9 +6896,9 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_cur_scope->__pyx_v_time_string == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "endswith"); - __PYX_ERR(0, 287, __pyx_L1_error) + __PYX_ERR(0, 288, __pyx_L1_error) } - __pyx_t_5 = __Pyx_PyUnicode_Tailmatch(__pyx_cur_scope->__pyx_v_time_string, __pyx_n_u_MS, 0, PY_SSIZE_T_MAX, 1); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(0, 287, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyUnicode_Tailmatch(__pyx_cur_scope->__pyx_v_time_string, __pyx_n_u_MS, 0, PY_SSIZE_T_MAX, 1); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(0, 288, __pyx_L1_error) if (!(__pyx_t_5 != 0)) { } else { __pyx_t_4 = (__pyx_t_5 != 0); @@ -6905,26 +6906,26 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } if (unlikely(__pyx_cur_scope->__pyx_v_time_string == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "endswith"); - __PYX_ERR(0, 287, __pyx_L1_error) + __PYX_ERR(0, 288, __pyx_L1_error) } - __pyx_t_5 = __Pyx_PyUnicode_Tailmatch(__pyx_cur_scope->__pyx_v_time_string, __pyx_n_u_MSEC, 0, PY_SSIZE_T_MAX, 1); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(0, 287, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyUnicode_Tailmatch(__pyx_cur_scope->__pyx_v_time_string, __pyx_n_u_MSEC, 0, PY_SSIZE_T_MAX, 1); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(0, 288, __pyx_L1_error) __pyx_t_4 = (__pyx_t_5 != 0); __pyx_L4_bool_binop_done:; if (__pyx_t_4) { - /* "mpfmc/core/audio/audio_interface.pyx":288 + /* "mpfmc/core/audio/audio_interface.pyx":289 * * if time_string.endswith('MS') or time_string.endswith('MSEC'): * time_string = ''.join(i for i in time_string if not i.isalpha()) # <<<<<<<<<<<<<< * return float(time_string) / 1000.0 * */ - __pyx_t_1 = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 288, __pyx_L1_error) + __pyx_t_1 = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 289, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = __Pyx_Generator_Next(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 288, __pyx_L1_error) + __pyx_t_3 = __Pyx_Generator_Next(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 289, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = PyUnicode_Join(__pyx_kp_u_, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 288, __pyx_L1_error) + __pyx_t_1 = PyUnicode_Join(__pyx_kp_u_, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 289, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_cur_scope->__pyx_v_time_string); @@ -6932,7 +6933,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_GIVEREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":289 + /* "mpfmc/core/audio/audio_interface.pyx":290 * if time_string.endswith('MS') or time_string.endswith('MSEC'): * time_string = ''.join(i for i in time_string if not i.isalpha()) * return float(time_string) / 1000.0 # <<<<<<<<<<<<<< @@ -6940,14 +6941,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * elif time_string.endswith('S') or time_string.endswith('SEC'): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_6 = __Pyx_PyObject_AsDouble(__pyx_cur_scope->__pyx_v_time_string); if (unlikely(__pyx_t_6 == ((double)((double)-1)) && PyErr_Occurred())) __PYX_ERR(0, 289, __pyx_L1_error) - __pyx_t_1 = PyFloat_FromDouble((__pyx_t_6 / 1000.0)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 289, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_AsDouble(__pyx_cur_scope->__pyx_v_time_string); if (unlikely(__pyx_t_6 == ((double)((double)-1)) && PyErr_Occurred())) __PYX_ERR(0, 290, __pyx_L1_error) + __pyx_t_1 = PyFloat_FromDouble((__pyx_t_6 / 1000.0)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 290, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":287 + /* "mpfmc/core/audio/audio_interface.pyx":288 * cdef str time_string = str(time).upper() * * if time_string.endswith('MS') or time_string.endswith('MSEC'): # <<<<<<<<<<<<<< @@ -6956,7 +6957,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":291 + /* "mpfmc/core/audio/audio_interface.pyx":292 * return float(time_string) / 1000.0 * * elif time_string.endswith('S') or time_string.endswith('SEC'): # <<<<<<<<<<<<<< @@ -6965,9 +6966,9 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_cur_scope->__pyx_v_time_string == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "endswith"); - __PYX_ERR(0, 291, __pyx_L1_error) + __PYX_ERR(0, 292, __pyx_L1_error) } - __pyx_t_5 = __Pyx_PyUnicode_Tailmatch(__pyx_cur_scope->__pyx_v_time_string, __pyx_n_u_S, 0, PY_SSIZE_T_MAX, 1); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(0, 291, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyUnicode_Tailmatch(__pyx_cur_scope->__pyx_v_time_string, __pyx_n_u_S, 0, PY_SSIZE_T_MAX, 1); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(0, 292, __pyx_L1_error) if (!(__pyx_t_5 != 0)) { } else { __pyx_t_4 = (__pyx_t_5 != 0); @@ -6975,26 +6976,26 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } if (unlikely(__pyx_cur_scope->__pyx_v_time_string == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "endswith"); - __PYX_ERR(0, 291, __pyx_L1_error) + __PYX_ERR(0, 292, __pyx_L1_error) } - __pyx_t_5 = __Pyx_PyUnicode_Tailmatch(__pyx_cur_scope->__pyx_v_time_string, __pyx_n_u_SEC, 0, PY_SSIZE_T_MAX, 1); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(0, 291, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyUnicode_Tailmatch(__pyx_cur_scope->__pyx_v_time_string, __pyx_n_u_SEC, 0, PY_SSIZE_T_MAX, 1); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(0, 292, __pyx_L1_error) __pyx_t_4 = (__pyx_t_5 != 0); __pyx_L6_bool_binop_done:; if (__pyx_t_4) { - /* "mpfmc/core/audio/audio_interface.pyx":292 + /* "mpfmc/core/audio/audio_interface.pyx":293 * * elif time_string.endswith('S') or time_string.endswith('SEC'): * time_string = ''.join(i for i in time_string if not i.isalpha()) # <<<<<<<<<<<<<< * return float(time_string) * */ - __pyx_t_1 = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_3genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 292, __pyx_L1_error) + __pyx_t_1 = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_3genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 293, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = __Pyx_Generator_Next(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 292, __pyx_L1_error) + __pyx_t_3 = __Pyx_Generator_Next(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 293, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = PyUnicode_Join(__pyx_kp_u_, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 292, __pyx_L1_error) + __pyx_t_1 = PyUnicode_Join(__pyx_kp_u_, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 293, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_cur_scope->__pyx_v_time_string); @@ -7002,7 +7003,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_GIVEREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":293 + /* "mpfmc/core/audio/audio_interface.pyx":294 * elif time_string.endswith('S') or time_string.endswith('SEC'): * time_string = ''.join(i for i in time_string if not i.isalpha()) * return float(time_string) # <<<<<<<<<<<<<< @@ -7010,13 +7011,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * elif 'D' in time_string: */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyNumber_Float(__pyx_cur_scope->__pyx_v_time_string); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 293, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyNumber_Float(__pyx_cur_scope->__pyx_v_time_string); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 294, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":291 + /* "mpfmc/core/audio/audio_interface.pyx":292 * return float(time_string) / 1000.0 * * elif time_string.endswith('S') or time_string.endswith('SEC'): # <<<<<<<<<<<<<< @@ -7025,7 +7026,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":295 + /* "mpfmc/core/audio/audio_interface.pyx":296 * return float(time_string) * * elif 'D' in time_string: # <<<<<<<<<<<<<< @@ -7034,25 +7035,25 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_cur_scope->__pyx_v_time_string == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(0, 295, __pyx_L1_error) + __PYX_ERR(0, 296, __pyx_L1_error) } - __pyx_t_4 = (__Pyx_PyUnicode_ContainsTF(__pyx_n_u_D, __pyx_cur_scope->__pyx_v_time_string, Py_EQ)); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(0, 295, __pyx_L1_error) + __pyx_t_4 = (__Pyx_PyUnicode_ContainsTF(__pyx_n_u_D, __pyx_cur_scope->__pyx_v_time_string, Py_EQ)); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(0, 296, __pyx_L1_error) __pyx_t_5 = (__pyx_t_4 != 0); if (__pyx_t_5) { - /* "mpfmc/core/audio/audio_interface.pyx":296 + /* "mpfmc/core/audio/audio_interface.pyx":297 * * elif 'D' in time_string: * time_string = ''.join(i for i in time_string if not i.isalpha()) # <<<<<<<<<<<<<< * return float(time_string) * 86400 * */ - __pyx_t_1 = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_6genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 296, __pyx_L1_error) + __pyx_t_1 = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_6genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 297, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = __Pyx_Generator_Next(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 296, __pyx_L1_error) + __pyx_t_3 = __Pyx_Generator_Next(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 297, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = PyUnicode_Join(__pyx_kp_u_, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 296, __pyx_L1_error) + __pyx_t_1 = PyUnicode_Join(__pyx_kp_u_, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 297, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_cur_scope->__pyx_v_time_string); @@ -7060,7 +7061,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_GIVEREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":297 + /* "mpfmc/core/audio/audio_interface.pyx":298 * elif 'D' in time_string: * time_string = ''.join(i for i in time_string if not i.isalpha()) * return float(time_string) * 86400 # <<<<<<<<<<<<<< @@ -7068,14 +7069,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * elif 'H' in time_string: */ __Pyx_XDECREF(__pyx_r); - __pyx_t_6 = __Pyx_PyObject_AsDouble(__pyx_cur_scope->__pyx_v_time_string); if (unlikely(__pyx_t_6 == ((double)((double)-1)) && PyErr_Occurred())) __PYX_ERR(0, 297, __pyx_L1_error) - __pyx_t_1 = PyFloat_FromDouble((__pyx_t_6 * 86400.0)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 297, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_AsDouble(__pyx_cur_scope->__pyx_v_time_string); if (unlikely(__pyx_t_6 == ((double)((double)-1)) && PyErr_Occurred())) __PYX_ERR(0, 298, __pyx_L1_error) + __pyx_t_1 = PyFloat_FromDouble((__pyx_t_6 * 86400.0)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 298, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":295 + /* "mpfmc/core/audio/audio_interface.pyx":296 * return float(time_string) * * elif 'D' in time_string: # <<<<<<<<<<<<<< @@ -7084,7 +7085,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":299 + /* "mpfmc/core/audio/audio_interface.pyx":300 * return float(time_string) * 86400 * * elif 'H' in time_string: # <<<<<<<<<<<<<< @@ -7093,25 +7094,25 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_cur_scope->__pyx_v_time_string == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(0, 299, __pyx_L1_error) + __PYX_ERR(0, 300, __pyx_L1_error) } - __pyx_t_5 = (__Pyx_PyUnicode_ContainsTF(__pyx_n_u_H, __pyx_cur_scope->__pyx_v_time_string, Py_EQ)); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(0, 299, __pyx_L1_error) + __pyx_t_5 = (__Pyx_PyUnicode_ContainsTF(__pyx_n_u_H, __pyx_cur_scope->__pyx_v_time_string, Py_EQ)); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(0, 300, __pyx_L1_error) __pyx_t_4 = (__pyx_t_5 != 0); if (__pyx_t_4) { - /* "mpfmc/core/audio/audio_interface.pyx":300 + /* "mpfmc/core/audio/audio_interface.pyx":301 * * elif 'H' in time_string: * time_string = ''.join(i for i in time_string if not i.isalpha()) # <<<<<<<<<<<<<< * return float(time_string) * 3600 * */ - __pyx_t_1 = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_9genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 300, __pyx_L1_error) + __pyx_t_1 = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_9genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 301, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = __Pyx_Generator_Next(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 300, __pyx_L1_error) + __pyx_t_3 = __Pyx_Generator_Next(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 301, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = PyUnicode_Join(__pyx_kp_u_, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 300, __pyx_L1_error) + __pyx_t_1 = PyUnicode_Join(__pyx_kp_u_, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 301, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_cur_scope->__pyx_v_time_string); @@ -7119,7 +7120,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_GIVEREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":301 + /* "mpfmc/core/audio/audio_interface.pyx":302 * elif 'H' in time_string: * time_string = ''.join(i for i in time_string if not i.isalpha()) * return float(time_string) * 3600 # <<<<<<<<<<<<<< @@ -7127,14 +7128,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * elif 'M' in time_string: */ __Pyx_XDECREF(__pyx_r); - __pyx_t_6 = __Pyx_PyObject_AsDouble(__pyx_cur_scope->__pyx_v_time_string); if (unlikely(__pyx_t_6 == ((double)((double)-1)) && PyErr_Occurred())) __PYX_ERR(0, 301, __pyx_L1_error) - __pyx_t_1 = PyFloat_FromDouble((__pyx_t_6 * 3600.0)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 301, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_AsDouble(__pyx_cur_scope->__pyx_v_time_string); if (unlikely(__pyx_t_6 == ((double)((double)-1)) && PyErr_Occurred())) __PYX_ERR(0, 302, __pyx_L1_error) + __pyx_t_1 = PyFloat_FromDouble((__pyx_t_6 * 3600.0)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 302, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":299 + /* "mpfmc/core/audio/audio_interface.pyx":300 * return float(time_string) * 86400 * * elif 'H' in time_string: # <<<<<<<<<<<<<< @@ -7143,7 +7144,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":303 + /* "mpfmc/core/audio/audio_interface.pyx":304 * return float(time_string) * 3600 * * elif 'M' in time_string: # <<<<<<<<<<<<<< @@ -7152,25 +7153,25 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_cur_scope->__pyx_v_time_string == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(0, 303, __pyx_L1_error) + __PYX_ERR(0, 304, __pyx_L1_error) } - __pyx_t_4 = (__Pyx_PyUnicode_ContainsTF(__pyx_n_u_M, __pyx_cur_scope->__pyx_v_time_string, Py_EQ)); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(0, 303, __pyx_L1_error) + __pyx_t_4 = (__Pyx_PyUnicode_ContainsTF(__pyx_n_u_M, __pyx_cur_scope->__pyx_v_time_string, Py_EQ)); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(0, 304, __pyx_L1_error) __pyx_t_5 = (__pyx_t_4 != 0); if (__pyx_t_5) { - /* "mpfmc/core/audio/audio_interface.pyx":304 + /* "mpfmc/core/audio/audio_interface.pyx":305 * * elif 'M' in time_string: * time_string = ''.join(i for i in time_string if not i.isalpha()) # <<<<<<<<<<<<<< * return float(time_string) * 60 * */ - __pyx_t_1 = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_12genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 304, __pyx_L1_error) + __pyx_t_1 = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_14string_to_secs_12genexpr(((PyObject*)__pyx_cur_scope)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 305, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = __Pyx_Generator_Next(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 304, __pyx_L1_error) + __pyx_t_3 = __Pyx_Generator_Next(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 305, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = PyUnicode_Join(__pyx_kp_u_, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 304, __pyx_L1_error) + __pyx_t_1 = PyUnicode_Join(__pyx_kp_u_, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 305, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_cur_scope->__pyx_v_time_string); @@ -7178,7 +7179,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_GIVEREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":305 + /* "mpfmc/core/audio/audio_interface.pyx":306 * elif 'M' in time_string: * time_string = ''.join(i for i in time_string if not i.isalpha()) * return float(time_string) * 60 # <<<<<<<<<<<<<< @@ -7186,14 +7187,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * elif not time_string or time_string == 'NONE': */ __Pyx_XDECREF(__pyx_r); - __pyx_t_6 = __Pyx_PyObject_AsDouble(__pyx_cur_scope->__pyx_v_time_string); if (unlikely(__pyx_t_6 == ((double)((double)-1)) && PyErr_Occurred())) __PYX_ERR(0, 305, __pyx_L1_error) - __pyx_t_1 = PyFloat_FromDouble((__pyx_t_6 * 60.0)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 305, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_AsDouble(__pyx_cur_scope->__pyx_v_time_string); if (unlikely(__pyx_t_6 == ((double)((double)-1)) && PyErr_Occurred())) __PYX_ERR(0, 306, __pyx_L1_error) + __pyx_t_1 = PyFloat_FromDouble((__pyx_t_6 * 60.0)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 306, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":303 + /* "mpfmc/core/audio/audio_interface.pyx":304 * return float(time_string) * 3600 * * elif 'M' in time_string: # <<<<<<<<<<<<<< @@ -7202,7 +7203,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":307 + /* "mpfmc/core/audio/audio_interface.pyx":308 * return float(time_string) * 60 * * elif not time_string or time_string == 'NONE': # <<<<<<<<<<<<<< @@ -7216,13 +7217,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_5 = __pyx_t_7; goto __pyx_L8_bool_binop_done; } - __pyx_t_7 = (__Pyx_PyUnicode_Equals(__pyx_cur_scope->__pyx_v_time_string, __pyx_n_u_NONE, Py_EQ)); if (unlikely(__pyx_t_7 < 0)) __PYX_ERR(0, 307, __pyx_L1_error) + __pyx_t_7 = (__Pyx_PyUnicode_Equals(__pyx_cur_scope->__pyx_v_time_string, __pyx_n_u_NONE, Py_EQ)); if (unlikely(__pyx_t_7 < 0)) __PYX_ERR(0, 308, __pyx_L1_error) __pyx_t_4 = (__pyx_t_7 != 0); __pyx_t_5 = __pyx_t_4; __pyx_L8_bool_binop_done:; if (__pyx_t_5) { - /* "mpfmc/core/audio/audio_interface.pyx":308 + /* "mpfmc/core/audio/audio_interface.pyx":309 * * elif not time_string or time_string == 'NONE': * return 0.0 # <<<<<<<<<<<<<< @@ -7234,7 +7235,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_r = __pyx_float_0_0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":307 + /* "mpfmc/core/audio/audio_interface.pyx":308 * return float(time_string) * 60 * * elif not time_string or time_string == 'NONE': # <<<<<<<<<<<<<< @@ -7243,7 +7244,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":311 + /* "mpfmc/core/audio/audio_interface.pyx":312 * * else: * try: # <<<<<<<<<<<<<< @@ -7260,7 +7261,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_XGOTREF(__pyx_t_10); /*try:*/ { - /* "mpfmc/core/audio/audio_interface.pyx":312 + /* "mpfmc/core/audio/audio_interface.pyx":313 * else: * try: * return float(time_string) # <<<<<<<<<<<<<< @@ -7268,13 +7269,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * return 0.0 */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyNumber_Float(__pyx_cur_scope->__pyx_v_time_string); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 312, __pyx_L10_error) + __pyx_t_1 = __Pyx_PyNumber_Float(__pyx_cur_scope->__pyx_v_time_string); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 313, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L14_try_return; - /* "mpfmc/core/audio/audio_interface.pyx":311 + /* "mpfmc/core/audio/audio_interface.pyx":312 * * else: * try: # <<<<<<<<<<<<<< @@ -7287,7 +7288,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":313 + /* "mpfmc/core/audio/audio_interface.pyx":314 * try: * return float(time_string) * except: # <<<<<<<<<<<<<< @@ -7296,12 +7297,12 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ /*except:*/ { __Pyx_AddTraceback("mpfmc.core.audio.audio_interface.AudioInterface.string_to_secs", __pyx_clineno, __pyx_lineno, __pyx_filename); - if (__Pyx_GetException(&__pyx_t_1, &__pyx_t_3, &__pyx_t_2) < 0) __PYX_ERR(0, 313, __pyx_L12_except_error) + if (__Pyx_GetException(&__pyx_t_1, &__pyx_t_3, &__pyx_t_2) < 0) __PYX_ERR(0, 314, __pyx_L12_except_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GOTREF(__pyx_t_3); __Pyx_GOTREF(__pyx_t_2); - /* "mpfmc/core/audio/audio_interface.pyx":314 + /* "mpfmc/core/audio/audio_interface.pyx":315 * return float(time_string) * except: * return 0.0 # <<<<<<<<<<<<<< @@ -7318,7 +7319,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_L12_except_error:; - /* "mpfmc/core/audio/audio_interface.pyx":311 + /* "mpfmc/core/audio/audio_interface.pyx":312 * * else: * try: # <<<<<<<<<<<<<< @@ -7345,7 +7346,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } } - /* "mpfmc/core/audio/audio_interface.pyx":269 + /* "mpfmc/core/audio/audio_interface.pyx":270 * * @staticmethod * def string_to_secs(time): # <<<<<<<<<<<<<< @@ -7367,7 +7368,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":316 +/* "mpfmc/core/audio/audio_interface.pyx":317 * return 0.0 * * def string_to_samples(self, samples): # <<<<<<<<<<<<<< @@ -7406,16 +7407,16 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("string_to_samples", 0); - /* "mpfmc/core/audio/audio_interface.pyx":326 + /* "mpfmc/core/audio/audio_interface.pyx":327 * Integer containing the number of samples. * """ * cdef str samples_string = str(samples).upper() # <<<<<<<<<<<<<< * * # If the string contains only digits we assume it is already in samples */ - __pyx_t_2 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyUnicode_Type)), __pyx_v_samples); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 326, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_CallOneArg(((PyObject *)(&PyUnicode_Type)), __pyx_v_samples); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 327, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_upper); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 326, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_upper); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 327, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; @@ -7430,14 +7431,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2) : __Pyx_PyObject_CallNoArg(__pyx_t_3); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 326, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 327, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - if (!(likely(PyUnicode_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(0, 326, __pyx_L1_error) + if (!(likely(PyUnicode_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(0, 327, __pyx_L1_error) __pyx_v_samples_string = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":329 + /* "mpfmc/core/audio/audio_interface.pyx":330 * * # If the string contains only digits we assume it is already in samples * try: # <<<<<<<<<<<<<< @@ -7453,7 +7454,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_XGOTREF(__pyx_t_6); /*try:*/ { - /* "mpfmc/core/audio/audio_interface.pyx":330 + /* "mpfmc/core/audio/audio_interface.pyx":331 * # If the string contains only digits we assume it is already in samples * try: * return int(float(samples_string)) # <<<<<<<<<<<<<< @@ -7461,16 +7462,16 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * pass */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyNumber_Float(__pyx_v_samples_string); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 330, __pyx_L3_error) + __pyx_t_1 = __Pyx_PyNumber_Float(__pyx_v_samples_string); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 331, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = __Pyx_PyNumber_Int(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 330, __pyx_L3_error) + __pyx_t_3 = __Pyx_PyNumber_Int(__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 331, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_3; __pyx_t_3 = 0; goto __pyx_L7_try_return; - /* "mpfmc/core/audio/audio_interface.pyx":329 + /* "mpfmc/core/audio/audio_interface.pyx":330 * * # If the string contains only digits we assume it is already in samples * try: # <<<<<<<<<<<<<< @@ -7483,7 +7484,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":331 + /* "mpfmc/core/audio/audio_interface.pyx":332 * try: * return int(float(samples_string)) * except: # <<<<<<<<<<<<<< @@ -7496,7 +7497,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_L7_try_return:; - /* "mpfmc/core/audio/audio_interface.pyx":329 + /* "mpfmc/core/audio/audio_interface.pyx":330 * * # If the string contains only digits we assume it is already in samples * try: # <<<<<<<<<<<<<< @@ -7515,14 +7516,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_ExceptionReset(__pyx_t_4, __pyx_t_5, __pyx_t_6); } - /* "mpfmc/core/audio/audio_interface.pyx":336 + /* "mpfmc/core/audio/audio_interface.pyx":337 * # Time strings are also permitted and will be converted to seconds * # and then to samples using the current sample rate. * cdef float seconds = AudioInterface.string_to_secs(samples_string) # <<<<<<<<<<<<<< * return int(self.audio_callback_data.sample_rate * seconds) * */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface), __pyx_n_s_string_to_secs); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 336, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface), __pyx_n_s_string_to_secs); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 337, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) { @@ -7536,14 +7537,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_3 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_1, __pyx_t_2, __pyx_v_samples_string) : __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_v_samples_string); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 336, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 337, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_7 = __pyx_PyFloat_AsFloat(__pyx_t_3); if (unlikely((__pyx_t_7 == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 336, __pyx_L1_error) + __pyx_t_7 = __pyx_PyFloat_AsFloat(__pyx_t_3); if (unlikely((__pyx_t_7 == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 337, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_v_seconds = __pyx_t_7; - /* "mpfmc/core/audio/audio_interface.pyx":337 + /* "mpfmc/core/audio/audio_interface.pyx":338 * # and then to samples using the current sample rate. * cdef float seconds = AudioInterface.string_to_secs(samples_string) * return int(self.audio_callback_data.sample_rate * seconds) # <<<<<<<<<<<<<< @@ -7551,13 +7552,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * @classmethod */ __Pyx_XDECREF(__pyx_r); - __pyx_t_3 = __Pyx_PyInt_FromDouble((__pyx_v_self->audio_callback_data.sample_rate * __pyx_v_seconds)); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 337, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_FromDouble((__pyx_v_self->audio_callback_data.sample_rate * __pyx_v_seconds)); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 338, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_r = __pyx_t_3; __pyx_t_3 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":316 + /* "mpfmc/core/audio/audio_interface.pyx":317 * return 0.0 * * def string_to_samples(self, samples): # <<<<<<<<<<<<<< @@ -7579,7 +7580,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":340 +/* "mpfmc/core/audio/audio_interface.pyx":341 * * @classmethod * def get_sdl_version(cls): # <<<<<<<<<<<<<< @@ -7618,7 +7619,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("get_sdl_version", 0); - /* "mpfmc/core/audio/audio_interface.pyx":346 + /* "mpfmc/core/audio/audio_interface.pyx":347 * """ * cdef SDL_version version * SDL_GetVersion(&version) # <<<<<<<<<<<<<< @@ -7627,7 +7628,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ SDL_GetVersion((&__pyx_v_version)); - /* "mpfmc/core/audio/audio_interface.pyx":347 + /* "mpfmc/core/audio/audio_interface.pyx":348 * cdef SDL_version version * SDL_GetVersion(&version) * return 'SDL {}.{}.{}'.format(version.major, version.minor, version.patch) # <<<<<<<<<<<<<< @@ -7635,13 +7636,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * @classmethod */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_kp_u_SDL, __pyx_n_s_format); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 347, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_kp_u_SDL, __pyx_n_s_format); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 348, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyInt_From_Uint8(__pyx_v_version.major); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 347, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_From_Uint8(__pyx_v_version.major); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 348, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = __Pyx_PyInt_From_Uint8(__pyx_v_version.minor); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 347, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyInt_From_Uint8(__pyx_v_version.minor); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 348, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_5 = __Pyx_PyInt_From_Uint8(__pyx_v_version.patch); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 347, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyInt_From_Uint8(__pyx_v_version.patch); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 348, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_6 = NULL; __pyx_t_7 = 0; @@ -7658,7 +7659,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[4] = {__pyx_t_6, __pyx_t_3, __pyx_t_4, __pyx_t_5}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 347, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 348, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; @@ -7669,7 +7670,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[4] = {__pyx_t_6, __pyx_t_3, __pyx_t_4, __pyx_t_5}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 347, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 348, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; @@ -7678,7 +7679,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } else #endif { - __pyx_t_8 = PyTuple_New(3+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 347, __pyx_L1_error) + __pyx_t_8 = PyTuple_New(3+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 348, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_6) { __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_6); __pyx_t_6 = NULL; @@ -7692,7 +7693,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_3 = 0; __pyx_t_4 = 0; __pyx_t_5 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_8, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 347, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_8, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 348, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } @@ -7701,7 +7702,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":340 + /* "mpfmc/core/audio/audio_interface.pyx":341 * * @classmethod * def get_sdl_version(cls): # <<<<<<<<<<<<<< @@ -7726,7 +7727,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":350 +/* "mpfmc/core/audio/audio_interface.pyx":351 * * @classmethod * def get_sdl_mixer_version(cls): # <<<<<<<<<<<<<< @@ -7765,7 +7766,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("get_sdl_mixer_version", 0); - /* "mpfmc/core/audio/audio_interface.pyx":355 + /* "mpfmc/core/audio/audio_interface.pyx":356 * :return: SDL_Mixer library version string * """ * cdef const SDL_version *version = Mix_Linked_Version() # <<<<<<<<<<<<<< @@ -7774,7 +7775,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ __pyx_v_version = Mix_Linked_Version(); - /* "mpfmc/core/audio/audio_interface.pyx":356 + /* "mpfmc/core/audio/audio_interface.pyx":357 * """ * cdef const SDL_version *version = Mix_Linked_Version() * return 'SDL_Mixer {}.{}.{}'.format(version.major, version.minor, version.patch) # <<<<<<<<<<<<<< @@ -7782,13 +7783,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * @classmethod */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_kp_u_SDL_Mixer, __pyx_n_s_format); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 356, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_kp_u_SDL_Mixer, __pyx_n_s_format); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 357, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_3 = __Pyx_PyInt_From_Uint8(__pyx_v_version->major); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 356, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_From_Uint8(__pyx_v_version->major); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 357, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = __Pyx_PyInt_From_Uint8(__pyx_v_version->minor); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 356, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyInt_From_Uint8(__pyx_v_version->minor); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 357, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_5 = __Pyx_PyInt_From_Uint8(__pyx_v_version->patch); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 356, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyInt_From_Uint8(__pyx_v_version->patch); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 357, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_6 = NULL; __pyx_t_7 = 0; @@ -7805,7 +7806,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[4] = {__pyx_t_6, __pyx_t_3, __pyx_t_4, __pyx_t_5}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 356, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 357, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; @@ -7816,7 +7817,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[4] = {__pyx_t_6, __pyx_t_3, __pyx_t_4, __pyx_t_5}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 356, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 357, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; @@ -7825,7 +7826,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } else #endif { - __pyx_t_8 = PyTuple_New(3+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 356, __pyx_L1_error) + __pyx_t_8 = PyTuple_New(3+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 357, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_6) { __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_6); __pyx_t_6 = NULL; @@ -7839,7 +7840,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_3 = 0; __pyx_t_4 = 0; __pyx_t_5 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_8, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 356, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_8, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 357, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } @@ -7848,7 +7849,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":350 + /* "mpfmc/core/audio/audio_interface.pyx":351 * * @classmethod * def get_sdl_mixer_version(cls): # <<<<<<<<<<<<<< @@ -7873,7 +7874,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":359 +/* "mpfmc/core/audio/audio_interface.pyx":360 * * @classmethod * def get_gstreamer_version(cls): # <<<<<<<<<<<<<< @@ -7913,14 +7914,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("get_gstreamer_version", 0); - /* "mpfmc/core/audio/audio_interface.pyx":364 + /* "mpfmc/core/audio/audio_interface.pyx":365 * :return: GStreamer library version string * """ * gst_version = get_gst_version() # <<<<<<<<<<<<<< * return 'GStreamer {}.{}.{}.{}'.format( * gst_version[0], gst_version[1], gst_version[2], gst_version[3]) */ - __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_get_gst_version); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 364, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_get_gst_version); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 365, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { @@ -7934,13 +7935,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 364, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 365, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_gst_version = __pyx_t_1; __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":365 + /* "mpfmc/core/audio/audio_interface.pyx":366 * """ * gst_version = get_gst_version() * return 'GStreamer {}.{}.{}.{}'.format( # <<<<<<<<<<<<<< @@ -7948,23 +7949,23 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_kp_u_GStreamer, __pyx_n_s_format); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 365, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_kp_u_GStreamer, __pyx_n_s_format); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 366, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - /* "mpfmc/core/audio/audio_interface.pyx":366 + /* "mpfmc/core/audio/audio_interface.pyx":367 * gst_version = get_gst_version() * return 'GStreamer {}.{}.{}.{}'.format( * gst_version[0], gst_version[1], gst_version[2], gst_version[3]) # <<<<<<<<<<<<<< * * @classmethod */ - __pyx_t_3 = __Pyx_GetItemInt(__pyx_v_gst_version, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 366, __pyx_L1_error) + __pyx_t_3 = __Pyx_GetItemInt(__pyx_v_gst_version, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 367, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = __Pyx_GetItemInt(__pyx_v_gst_version, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 366, __pyx_L1_error) + __pyx_t_4 = __Pyx_GetItemInt(__pyx_v_gst_version, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 367, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_5 = __Pyx_GetItemInt(__pyx_v_gst_version, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 366, __pyx_L1_error) + __pyx_t_5 = __Pyx_GetItemInt(__pyx_v_gst_version, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 367, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - __pyx_t_6 = __Pyx_GetItemInt(__pyx_v_gst_version, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 366, __pyx_L1_error) + __pyx_t_6 = __Pyx_GetItemInt(__pyx_v_gst_version, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 367, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; __pyx_t_8 = 0; @@ -7981,7 +7982,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[5] = {__pyx_t_7, __pyx_t_3, __pyx_t_4, __pyx_t_5, __pyx_t_6}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_8, 4+__pyx_t_8); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 365, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_8, 4+__pyx_t_8); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 366, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; @@ -7993,7 +7994,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[5] = {__pyx_t_7, __pyx_t_3, __pyx_t_4, __pyx_t_5, __pyx_t_6}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_8, 4+__pyx_t_8); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 365, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_8, 4+__pyx_t_8); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 366, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; @@ -8003,7 +8004,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } else #endif { - __pyx_t_9 = PyTuple_New(4+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 365, __pyx_L1_error) + __pyx_t_9 = PyTuple_New(4+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 366, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_7); __pyx_t_7 = NULL; @@ -8020,7 +8021,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_4 = 0; __pyx_t_5 = 0; __pyx_t_6 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_9, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 365, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_9, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 366, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } @@ -8029,7 +8030,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":359 + /* "mpfmc/core/audio/audio_interface.pyx":360 * * @classmethod * def get_gstreamer_version(cls): # <<<<<<<<<<<<<< @@ -8056,7 +8057,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":369 +/* "mpfmc/core/audio/audio_interface.pyx":370 * * @classmethod * def get_glib_version(cls): # <<<<<<<<<<<<<< @@ -8094,7 +8095,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("get_glib_version", 0); - /* "mpfmc/core/audio/audio_interface.pyx":374 + /* "mpfmc/core/audio/audio_interface.pyx":375 * :return: GLib library version string * """ * return 'GLib {}.{}.{}'.format( # <<<<<<<<<<<<<< @@ -8102,21 +8103,21 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * */ __Pyx_XDECREF(__pyx_r); - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_kp_u_GLib, __pyx_n_s_format); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 374, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_kp_u_GLib, __pyx_n_s_format); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 375, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - /* "mpfmc/core/audio/audio_interface.pyx":375 + /* "mpfmc/core/audio/audio_interface.pyx":376 * """ * return 'GLib {}.{}.{}'.format( * glib_major_version, glib_minor_version, glib_micro_version) # <<<<<<<<<<<<<< * * def supported_extensions(self): */ - __pyx_t_3 = __Pyx_PyInt_From_int(glib_major_version); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 375, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_From_int(glib_major_version); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 376, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - __pyx_t_4 = __Pyx_PyInt_From_int(glib_minor_version); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 375, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyInt_From_int(glib_minor_version); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 376, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_5 = __Pyx_PyInt_From_int(glib_micro_version); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 375, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyInt_From_int(glib_micro_version); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 376, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_6 = NULL; __pyx_t_7 = 0; @@ -8133,7 +8134,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[4] = {__pyx_t_6, __pyx_t_3, __pyx_t_4, __pyx_t_5}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 374, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 375, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; @@ -8144,7 +8145,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[4] = {__pyx_t_6, __pyx_t_3, __pyx_t_4, __pyx_t_5}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 374, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 375, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; @@ -8153,7 +8154,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } else #endif { - __pyx_t_8 = PyTuple_New(3+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 374, __pyx_L1_error) + __pyx_t_8 = PyTuple_New(3+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 375, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_6) { __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_6); __pyx_t_6 = NULL; @@ -8167,7 +8168,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_3 = 0; __pyx_t_4 = 0; __pyx_t_5 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_8, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 374, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_8, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 375, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } @@ -8176,7 +8177,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":369 + /* "mpfmc/core/audio/audio_interface.pyx":370 * * @classmethod * def get_glib_version(cls): # <<<<<<<<<<<<<< @@ -8201,7 +8202,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":377 +/* "mpfmc/core/audio/audio_interface.pyx":378 * glib_major_version, glib_minor_version, glib_micro_version) * * def supported_extensions(self): # <<<<<<<<<<<<<< @@ -8232,7 +8233,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("supported_extensions", 0); - /* "mpfmc/core/audio/audio_interface.pyx":383 + /* "mpfmc/core/audio/audio_interface.pyx":384 * A list of file extensions supported. * """ * return ["wav", "ogg", "flac",] # <<<<<<<<<<<<<< @@ -8240,7 +8241,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * def get_master_volume(self): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyList_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 383, __pyx_L1_error) + __pyx_t_1 = PyList_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 384, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(__pyx_n_u_wav); __Pyx_GIVEREF(__pyx_n_u_wav); @@ -8255,7 +8256,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":377 + /* "mpfmc/core/audio/audio_interface.pyx":378 * glib_major_version, glib_minor_version, glib_micro_version) * * def supported_extensions(self): # <<<<<<<<<<<<<< @@ -8274,7 +8275,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":385 +/* "mpfmc/core/audio/audio_interface.pyx":386 * return ["wav", "ogg", "flac",] * * def get_master_volume(self): # <<<<<<<<<<<<<< @@ -8306,7 +8307,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("get_master_volume", 0); - /* "mpfmc/core/audio/audio_interface.pyx":386 + /* "mpfmc/core/audio/audio_interface.pyx":387 * * def get_master_volume(self): * return round(self.audio_callback_data.master_volume / SDL_MIX_MAXVOLUME, 2) # <<<<<<<<<<<<<< @@ -8316,11 +8317,11 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_XDECREF(__pyx_r); if (unlikely(SDL_MIX_MAXVOLUME == 0)) { PyErr_SetString(PyExc_ZeroDivisionError, "float division"); - __PYX_ERR(0, 386, __pyx_L1_error) + __PYX_ERR(0, 387, __pyx_L1_error) } - __pyx_t_1 = PyFloat_FromDouble((((double)__pyx_v_self->audio_callback_data.master_volume) / ((double)SDL_MIX_MAXVOLUME))); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 386, __pyx_L1_error) + __pyx_t_1 = PyFloat_FromDouble((((double)__pyx_v_self->audio_callback_data.master_volume) / ((double)SDL_MIX_MAXVOLUME))); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 387, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 386, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 387, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); @@ -8328,14 +8329,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_GIVEREF(__pyx_int_2); PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_int_2); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_round, __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 386, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_round, __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 387, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":385 + /* "mpfmc/core/audio/audio_interface.pyx":386 * return ["wav", "ogg", "flac",] * * def get_master_volume(self): # <<<<<<<<<<<<<< @@ -8355,7 +8356,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":388 +/* "mpfmc/core/audio/audio_interface.pyx":389 * return round(self.audio_callback_data.master_volume / SDL_MIX_MAXVOLUME, 2) * * def set_master_volume(self, float volume): # <<<<<<<<<<<<<< @@ -8375,7 +8376,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("set_master_volume (wrapper)", 0); assert(__pyx_arg_volume); { - __pyx_v_volume = __pyx_PyFloat_AsFloat(__pyx_arg_volume); if (unlikely((__pyx_v_volume == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 388, __pyx_L3_error) + __pyx_v_volume = __pyx_PyFloat_AsFloat(__pyx_arg_volume); if (unlikely((__pyx_v_volume == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 389, __pyx_L3_error) } goto __pyx_L4_argument_unpacking_done; __pyx_L3_error:; @@ -8399,7 +8400,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface float __pyx_t_4; __Pyx_RefNannySetupContext("set_master_volume", 0); - /* "mpfmc/core/audio/audio_interface.pyx":389 + /* "mpfmc/core/audio/audio_interface.pyx":390 * * def set_master_volume(self, float volume): * SDL_LockAudio() # <<<<<<<<<<<<<< @@ -8408,7 +8409,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ SDL_LockAudio(); - /* "mpfmc/core/audio/audio_interface.pyx":390 + /* "mpfmc/core/audio/audio_interface.pyx":391 * def set_master_volume(self, float volume): * SDL_LockAudio() * self.audio_callback_data.master_volume = min(max(volume * SDL_MIX_MAXVOLUME, 0), SDL_MIX_MAXVOLUME) # <<<<<<<<<<<<<< @@ -8431,7 +8432,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_v_self->audio_callback_data.master_volume = ((Uint8)__pyx_t_4); - /* "mpfmc/core/audio/audio_interface.pyx":391 + /* "mpfmc/core/audio/audio_interface.pyx":392 * SDL_LockAudio() * self.audio_callback_data.master_volume = min(max(volume * SDL_MIX_MAXVOLUME, 0), SDL_MIX_MAXVOLUME) * SDL_UnlockAudio() # <<<<<<<<<<<<<< @@ -8440,7 +8441,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ SDL_UnlockAudio(); - /* "mpfmc/core/audio/audio_interface.pyx":388 + /* "mpfmc/core/audio/audio_interface.pyx":389 * return round(self.audio_callback_data.master_volume / SDL_MIX_MAXVOLUME, 2) * * def set_master_volume(self, float volume): # <<<<<<<<<<<<<< @@ -8455,7 +8456,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":393 +/* "mpfmc/core/audio/audio_interface.pyx":394 * SDL_UnlockAudio() * * def get_settings(self): # <<<<<<<<<<<<<< @@ -8488,20 +8489,20 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("get_settings", 0); - /* "mpfmc/core/audio/audio_interface.pyx":400 + /* "mpfmc/core/audio/audio_interface.pyx":401 * audio interface is not enabled. * """ * if self.enabled: # <<<<<<<<<<<<<< * return {'sample_rate': self.audio_callback_data.sample_rate, * 'audio_channels': self.audio_callback_data.channels, */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_enabled); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 400, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_enabled); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 401, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 400, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 401, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; if (__pyx_t_2) { - /* "mpfmc/core/audio/audio_interface.pyx":401 + /* "mpfmc/core/audio/audio_interface.pyx":402 * """ * if self.enabled: * return {'sample_rate': self.audio_callback_data.sample_rate, # <<<<<<<<<<<<<< @@ -8509,77 +8510,77 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * 'buffer_samples': self.audio_callback_data.buffer_samples, */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyDict_NewPresized(6); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 401, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyDict_NewPresized(6); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 402, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_self->audio_callback_data.sample_rate); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 401, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_self->audio_callback_data.sample_rate); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 402, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - if (PyDict_SetItem(__pyx_t_1, __pyx_n_u_sample_rate, __pyx_t_3) < 0) __PYX_ERR(0, 401, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_1, __pyx_n_u_sample_rate, __pyx_t_3) < 0) __PYX_ERR(0, 402, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":402 + /* "mpfmc/core/audio/audio_interface.pyx":403 * if self.enabled: * return {'sample_rate': self.audio_callback_data.sample_rate, * 'audio_channels': self.audio_callback_data.channels, # <<<<<<<<<<<<<< * 'buffer_samples': self.audio_callback_data.buffer_samples, * 'buffer_size': self.audio_callback_data.buffer_size, */ - __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_self->audio_callback_data.channels); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 402, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_self->audio_callback_data.channels); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 403, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - if (PyDict_SetItem(__pyx_t_1, __pyx_n_u_audio_channels, __pyx_t_3) < 0) __PYX_ERR(0, 401, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_1, __pyx_n_u_audio_channels, __pyx_t_3) < 0) __PYX_ERR(0, 402, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":403 + /* "mpfmc/core/audio/audio_interface.pyx":404 * return {'sample_rate': self.audio_callback_data.sample_rate, * 'audio_channels': self.audio_callback_data.channels, * 'buffer_samples': self.audio_callback_data.buffer_samples, # <<<<<<<<<<<<<< * 'buffer_size': self.audio_callback_data.buffer_size, * 'bytes_per_sample': self.audio_callback_data.bytes_per_sample, */ - __pyx_t_3 = __Pyx_PyInt_From_Uint16(__pyx_v_self->audio_callback_data.buffer_samples); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 403, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_From_Uint16(__pyx_v_self->audio_callback_data.buffer_samples); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 404, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - if (PyDict_SetItem(__pyx_t_1, __pyx_n_u_buffer_samples, __pyx_t_3) < 0) __PYX_ERR(0, 401, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_1, __pyx_n_u_buffer_samples, __pyx_t_3) < 0) __PYX_ERR(0, 402, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":404 + /* "mpfmc/core/audio/audio_interface.pyx":405 * 'audio_channels': self.audio_callback_data.channels, * 'buffer_samples': self.audio_callback_data.buffer_samples, * 'buffer_size': self.audio_callback_data.buffer_size, # <<<<<<<<<<<<<< * 'bytes_per_sample': self.audio_callback_data.bytes_per_sample, * 'seconds_to_bytes_factor': self.audio_callback_data.seconds_to_bytes_factor */ - __pyx_t_3 = __Pyx_PyInt_From_Uint32(__pyx_v_self->audio_callback_data.buffer_size); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 404, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_From_Uint32(__pyx_v_self->audio_callback_data.buffer_size); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 405, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - if (PyDict_SetItem(__pyx_t_1, __pyx_n_u_buffer_size, __pyx_t_3) < 0) __PYX_ERR(0, 401, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_1, __pyx_n_u_buffer_size, __pyx_t_3) < 0) __PYX_ERR(0, 402, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":405 + /* "mpfmc/core/audio/audio_interface.pyx":406 * 'buffer_samples': self.audio_callback_data.buffer_samples, * 'buffer_size': self.audio_callback_data.buffer_size, * 'bytes_per_sample': self.audio_callback_data.bytes_per_sample, # <<<<<<<<<<<<<< * 'seconds_to_bytes_factor': self.audio_callback_data.seconds_to_bytes_factor * } */ - __pyx_t_3 = __Pyx_PyInt_From_Uint8(__pyx_v_self->audio_callback_data.bytes_per_sample); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 405, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyInt_From_Uint8(__pyx_v_self->audio_callback_data.bytes_per_sample); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 406, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - if (PyDict_SetItem(__pyx_t_1, __pyx_n_u_bytes_per_sample, __pyx_t_3) < 0) __PYX_ERR(0, 401, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_1, __pyx_n_u_bytes_per_sample, __pyx_t_3) < 0) __PYX_ERR(0, 402, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":406 + /* "mpfmc/core/audio/audio_interface.pyx":407 * 'buffer_size': self.audio_callback_data.buffer_size, * 'bytes_per_sample': self.audio_callback_data.bytes_per_sample, * 'seconds_to_bytes_factor': self.audio_callback_data.seconds_to_bytes_factor # <<<<<<<<<<<<<< * } * else: */ - __pyx_t_3 = PyFloat_FromDouble(__pyx_v_self->audio_callback_data.seconds_to_bytes_factor); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 406, __pyx_L1_error) + __pyx_t_3 = PyFloat_FromDouble(__pyx_v_self->audio_callback_data.seconds_to_bytes_factor); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 407, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); - if (PyDict_SetItem(__pyx_t_1, __pyx_n_u_seconds_to_bytes_factor, __pyx_t_3) < 0) __PYX_ERR(0, 401, __pyx_L1_error) + if (PyDict_SetItem(__pyx_t_1, __pyx_n_u_seconds_to_bytes_factor, __pyx_t_3) < 0) __PYX_ERR(0, 402, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":400 + /* "mpfmc/core/audio/audio_interface.pyx":401 * audio interface is not enabled. * """ * if self.enabled: # <<<<<<<<<<<<<< @@ -8588,7 +8589,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":409 + /* "mpfmc/core/audio/audio_interface.pyx":410 * } * else: * return None # <<<<<<<<<<<<<< @@ -8601,7 +8602,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface goto __pyx_L0; } - /* "mpfmc/core/audio/audio_interface.pyx":393 + /* "mpfmc/core/audio/audio_interface.pyx":394 * SDL_UnlockAudio() * * def get_settings(self): # <<<<<<<<<<<<<< @@ -8621,7 +8622,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":411 +/* "mpfmc/core/audio/audio_interface.pyx":412 * return None * * cdef write_gst_log_message(self, message_type, message): # <<<<<<<<<<<<<< @@ -8641,24 +8642,24 @@ static PyObject *__pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_ int __pyx_clineno = 0; __Pyx_RefNannySetupContext("write_gst_log_message", 0); - /* "mpfmc/core/audio/audio_interface.pyx":414 + /* "mpfmc/core/audio/audio_interface.pyx":415 * """Write GStreamer log message to the mpfmc log""" * # print(message_type, message) * if message_type == 'error': # <<<<<<<<<<<<<< * self.log.error(message) * elif message_type == 'warning': */ - __pyx_t_1 = (__Pyx_PyUnicode_Equals(__pyx_v_message_type, __pyx_n_u_error, Py_EQ)); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 414, __pyx_L1_error) + __pyx_t_1 = (__Pyx_PyUnicode_Equals(__pyx_v_message_type, __pyx_n_u_error, Py_EQ)); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 415, __pyx_L1_error) if (__pyx_t_1) { - /* "mpfmc/core/audio/audio_interface.pyx":415 + /* "mpfmc/core/audio/audio_interface.pyx":416 * # print(message_type, message) * if message_type == 'error': * self.log.error(message) # <<<<<<<<<<<<<< * elif message_type == 'warning': * self.log.warning(message) */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_error); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 415, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_error); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 416, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -8672,12 +8673,12 @@ static PyObject *__pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_ } __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_v_message) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_message); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 415, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 416, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":414 + /* "mpfmc/core/audio/audio_interface.pyx":415 * """Write GStreamer log message to the mpfmc log""" * # print(message_type, message) * if message_type == 'error': # <<<<<<<<<<<<<< @@ -8687,24 +8688,24 @@ static PyObject *__pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_ goto __pyx_L3; } - /* "mpfmc/core/audio/audio_interface.pyx":416 + /* "mpfmc/core/audio/audio_interface.pyx":417 * if message_type == 'error': * self.log.error(message) * elif message_type == 'warning': # <<<<<<<<<<<<<< * self.log.warning(message) * elif message_type == 'info': */ - __pyx_t_1 = (__Pyx_PyUnicode_Equals(__pyx_v_message_type, __pyx_n_u_warning, Py_EQ)); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 416, __pyx_L1_error) + __pyx_t_1 = (__Pyx_PyUnicode_Equals(__pyx_v_message_type, __pyx_n_u_warning, Py_EQ)); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 417, __pyx_L1_error) if (__pyx_t_1) { - /* "mpfmc/core/audio/audio_interface.pyx":417 + /* "mpfmc/core/audio/audio_interface.pyx":418 * self.log.error(message) * elif message_type == 'warning': * self.log.warning(message) # <<<<<<<<<<<<<< * elif message_type == 'info': * self.log.info(message) */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_warning); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 417, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_warning); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 418, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -8718,12 +8719,12 @@ static PyObject *__pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_ } __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_v_message) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_message); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 417, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 418, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":416 + /* "mpfmc/core/audio/audio_interface.pyx":417 * if message_type == 'error': * self.log.error(message) * elif message_type == 'warning': # <<<<<<<<<<<<<< @@ -8733,24 +8734,24 @@ static PyObject *__pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_ goto __pyx_L3; } - /* "mpfmc/core/audio/audio_interface.pyx":418 + /* "mpfmc/core/audio/audio_interface.pyx":419 * elif message_type == 'warning': * self.log.warning(message) * elif message_type == 'info': # <<<<<<<<<<<<<< * self.log.info(message) * */ - __pyx_t_1 = (__Pyx_PyUnicode_Equals(__pyx_v_message_type, __pyx_n_u_info, Py_EQ)); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 418, __pyx_L1_error) + __pyx_t_1 = (__Pyx_PyUnicode_Equals(__pyx_v_message_type, __pyx_n_u_info, Py_EQ)); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 419, __pyx_L1_error) if (__pyx_t_1) { - /* "mpfmc/core/audio/audio_interface.pyx":419 + /* "mpfmc/core/audio/audio_interface.pyx":420 * self.log.warning(message) * elif message_type == 'info': * self.log.info(message) # <<<<<<<<<<<<<< * * @property */ - __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_info); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 419, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_info); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 420, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { @@ -8764,12 +8765,12 @@ static PyObject *__pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_ } __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_v_message) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_message); __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 419, __pyx_L1_error) + if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 420, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":418 + /* "mpfmc/core/audio/audio_interface.pyx":419 * elif message_type == 'warning': * self.log.warning(message) * elif message_type == 'info': # <<<<<<<<<<<<<< @@ -8779,7 +8780,7 @@ static PyObject *__pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_ } __pyx_L3:; - /* "mpfmc/core/audio/audio_interface.pyx":411 + /* "mpfmc/core/audio/audio_interface.pyx":412 * return None * * cdef write_gst_log_message(self, message_type, message): # <<<<<<<<<<<<<< @@ -8802,7 +8803,7 @@ static PyObject *__pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_ return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":422 +/* "mpfmc/core/audio/audio_interface.pyx":423 * * @property * def enabled(self): # <<<<<<<<<<<<<< @@ -8832,7 +8833,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("__get__", 0); - /* "mpfmc/core/audio/audio_interface.pyx":423 + /* "mpfmc/core/audio/audio_interface.pyx":424 * @property * def enabled(self): * return Mix_GetMusicHookData() != NULL # <<<<<<<<<<<<<< @@ -8840,13 +8841,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * def enable(self): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyBool_FromLong((Mix_GetMusicHookData() != NULL)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 423, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyBool_FromLong((Mix_GetMusicHookData() != NULL)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 424, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":422 + /* "mpfmc/core/audio/audio_interface.pyx":423 * * @property * def enabled(self): # <<<<<<<<<<<<<< @@ -8865,7 +8866,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":425 +/* "mpfmc/core/audio/audio_interface.pyx":426 * return Mix_GetMusicHookData() != NULL * * def enable(self): # <<<<<<<<<<<<<< @@ -8898,14 +8899,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("enable", 0); - /* "mpfmc/core/audio/audio_interface.pyx":429 + /* "mpfmc/core/audio/audio_interface.pyx":430 * Enables audio playback (begins audio processing) * """ * self.log.info("Enabling audio playback") # <<<<<<<<<<<<<< * Mix_HookMusic(self.audio_callback, &self.audio_callback_data) * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_info); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 429, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_info); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 430, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -8919,12 +8920,12 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_kp_u_Enabling_audio_playback) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_kp_u_Enabling_audio_playback); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 429, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 430, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":430 + /* "mpfmc/core/audio/audio_interface.pyx":431 * """ * self.log.info("Enabling audio playback") * Mix_HookMusic(self.audio_callback, &self.audio_callback_data) # <<<<<<<<<<<<<< @@ -8933,7 +8934,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ Mix_HookMusic(((struct __pyx_vtabstruct_5mpfmc_4core_5audio_15audio_interface_AudioInterface *)__pyx_v_self->__pyx_vtab)->audio_callback, (&__pyx_v_self->audio_callback_data)); - /* "mpfmc/core/audio/audio_interface.pyx":425 + /* "mpfmc/core/audio/audio_interface.pyx":426 * return Mix_GetMusicHookData() != NULL * * def enable(self): # <<<<<<<<<<<<<< @@ -8956,7 +8957,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":432 +/* "mpfmc/core/audio/audio_interface.pyx":433 * Mix_HookMusic(self.audio_callback, &self.audio_callback_data) * * def disable(self): # <<<<<<<<<<<<<< @@ -8989,14 +8990,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("disable", 0); - /* "mpfmc/core/audio/audio_interface.pyx":436 + /* "mpfmc/core/audio/audio_interface.pyx":437 * Disables audio playback (stops audio processing) * """ * self.log.info("Disabling audio playback") # <<<<<<<<<<<<<< * self.stop_all_sounds() * Mix_HookMusic(NULL, NULL) */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_info); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 436, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_info); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 437, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -9010,19 +9011,19 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_kp_u_Disabling_audio_playback) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_kp_u_Disabling_audio_playback); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 436, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 437, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":437 + /* "mpfmc/core/audio/audio_interface.pyx":438 * """ * self.log.info("Disabling audio playback") * self.stop_all_sounds() # <<<<<<<<<<<<<< * Mix_HookMusic(NULL, NULL) * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_stop_all_sounds); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 437, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_stop_all_sounds); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 438, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -9036,12 +9037,12 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 437, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 438, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":438 + /* "mpfmc/core/audio/audio_interface.pyx":439 * self.log.info("Disabling audio playback") * self.stop_all_sounds() * Mix_HookMusic(NULL, NULL) # <<<<<<<<<<<<<< @@ -9050,7 +9051,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ Mix_HookMusic(NULL, NULL); - /* "mpfmc/core/audio/audio_interface.pyx":432 + /* "mpfmc/core/audio/audio_interface.pyx":433 * Mix_HookMusic(self.audio_callback, &self.audio_callback_data) * * def disable(self): # <<<<<<<<<<<<<< @@ -9073,7 +9074,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":440 +/* "mpfmc/core/audio/audio_interface.pyx":441 * Mix_HookMusic(NULL, NULL) * * def shutdown(self): # <<<<<<<<<<<<<< @@ -9106,14 +9107,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("shutdown", 0); - /* "mpfmc/core/audio/audio_interface.pyx":444 + /* "mpfmc/core/audio/audio_interface.pyx":445 * Shuts down the audio device * """ * self.disable() # <<<<<<<<<<<<<< * Mix_CloseAudio() * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_disable); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 444, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_disable); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 445, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -9127,12 +9128,12 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 444, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 445, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":445 + /* "mpfmc/core/audio/audio_interface.pyx":446 * """ * self.disable() * Mix_CloseAudio() # <<<<<<<<<<<<<< @@ -9141,7 +9142,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ Mix_CloseAudio(); - /* "mpfmc/core/audio/audio_interface.pyx":440 + /* "mpfmc/core/audio/audio_interface.pyx":441 * Mix_HookMusic(NULL, NULL) * * def shutdown(self): # <<<<<<<<<<<<<< @@ -9164,7 +9165,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":448 +/* "mpfmc/core/audio/audio_interface.pyx":449 * * @staticmethod * def get_max_tracks(): # <<<<<<<<<<<<<< @@ -9195,7 +9196,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("get_max_tracks", 0); - /* "mpfmc/core/audio/audio_interface.pyx":450 + /* "mpfmc/core/audio/audio_interface.pyx":451 * def get_max_tracks(): * """ Returns the maximum number of tracks allowed. """ * return MAX_TRACKS # <<<<<<<<<<<<<< @@ -9207,7 +9208,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_r = __pyx_int_8; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":448 + /* "mpfmc/core/audio/audio_interface.pyx":449 * * @staticmethod * def get_max_tracks(): # <<<<<<<<<<<<<< @@ -9222,7 +9223,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":453 +/* "mpfmc/core/audio/audio_interface.pyx":454 * * @staticmethod * def get_max_markers(): # <<<<<<<<<<<<<< @@ -9253,7 +9254,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("get_max_markers", 0); - /* "mpfmc/core/audio/audio_interface.pyx":455 + /* "mpfmc/core/audio/audio_interface.pyx":456 * def get_max_markers(): * """Return the maximum number of markers allowed per sound""" * return MAX_MARKERS # <<<<<<<<<<<<<< @@ -9265,7 +9266,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_r = __pyx_int_16; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":453 + /* "mpfmc/core/audio/audio_interface.pyx":454 * * @staticmethod * def get_max_markers(): # <<<<<<<<<<<<<< @@ -9280,7 +9281,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":457 +/* "mpfmc/core/audio/audio_interface.pyx":458 * return MAX_MARKERS * * def get_track_count(self): # <<<<<<<<<<<<<< @@ -9312,7 +9313,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("get_track_count", 0); - /* "mpfmc/core/audio/audio_interface.pyx":459 + /* "mpfmc/core/audio/audio_interface.pyx":460 * def get_track_count(self): * """Returns the number of tracks that have been created.""" * return len(self.tracks) # <<<<<<<<<<<<<< @@ -9324,17 +9325,17 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(0, 459, __pyx_L1_error) + __PYX_ERR(0, 460, __pyx_L1_error) } - __pyx_t_2 = PyList_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(0, 459, __pyx_L1_error) + __pyx_t_2 = PyList_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(0, 460, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = PyInt_FromSsize_t(__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 459, __pyx_L1_error) + __pyx_t_1 = PyInt_FromSsize_t(__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 460, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":457 + /* "mpfmc/core/audio/audio_interface.pyx":458 * return MAX_MARKERS * * def get_track_count(self): # <<<<<<<<<<<<<< @@ -9353,7 +9354,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":461 +/* "mpfmc/core/audio/audio_interface.pyx":462 * return len(self.tracks) * * def get_track_names(self): # <<<<<<<<<<<<<< @@ -9388,7 +9389,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("get_track_names", 0); - /* "mpfmc/core/audio/audio_interface.pyx":463 + /* "mpfmc/core/audio/audio_interface.pyx":464 * def get_track_names(self): * """Return the list of names of tracks that have been created.""" * return [track.name for track in self.tracks] # <<<<<<<<<<<<<< @@ -9397,26 +9398,26 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ __Pyx_XDECREF(__pyx_r); { /* enter inner scope */ - __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 463, __pyx_L5_error) + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 464, __pyx_L5_error) __Pyx_GOTREF(__pyx_t_1); if (unlikely(__pyx_v_self->tracks == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(0, 463, __pyx_L5_error) + __PYX_ERR(0, 464, __pyx_L5_error) } __pyx_t_2 = __pyx_v_self->tracks; __Pyx_INCREF(__pyx_t_2); __pyx_t_3 = 0; for (;;) { if (__pyx_t_3 >= PyList_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_4 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_4); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(0, 463, __pyx_L5_error) + __pyx_t_4 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_4); __pyx_t_3++; if (unlikely(0 < 0)) __PYX_ERR(0, 464, __pyx_L5_error) #else - __pyx_t_4 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 463, __pyx_L5_error) + __pyx_t_4 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 464, __pyx_L5_error) __Pyx_GOTREF(__pyx_t_4); #endif __Pyx_XDECREF_SET(__pyx_8genexpr6__pyx_v_track, __pyx_t_4); __pyx_t_4 = 0; - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_8genexpr6__pyx_v_track, __pyx_n_s_name); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 463, __pyx_L5_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_8genexpr6__pyx_v_track, __pyx_n_s_name); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 464, __pyx_L5_error) __Pyx_GOTREF(__pyx_t_4); - if (unlikely(__Pyx_ListComp_Append(__pyx_t_1, (PyObject*)__pyx_t_4))) __PYX_ERR(0, 463, __pyx_L5_error) + if (unlikely(__Pyx_ListComp_Append(__pyx_t_1, (PyObject*)__pyx_t_4))) __PYX_ERR(0, 464, __pyx_L5_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; @@ -9431,7 +9432,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":461 + /* "mpfmc/core/audio/audio_interface.pyx":462 * return len(self.tracks) * * def get_track_names(self): # <<<<<<<<<<<<<< @@ -9453,7 +9454,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":465 +/* "mpfmc/core/audio/audio_interface.pyx":466 * return [track.name for track in self.tracks] * * def get_track(self, int track_num): # <<<<<<<<<<<<<< @@ -9473,7 +9474,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("get_track (wrapper)", 0); assert(__pyx_arg_track_num); { - __pyx_v_track_num = __Pyx_PyInt_As_int(__pyx_arg_track_num); if (unlikely((__pyx_v_track_num == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 465, __pyx_L3_error) + __pyx_v_track_num = __Pyx_PyInt_As_int(__pyx_arg_track_num); if (unlikely((__pyx_v_track_num == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 466, __pyx_L3_error) } goto __pyx_L4_argument_unpacking_done; __pyx_L3_error:; @@ -9503,7 +9504,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("get_track", 0); - /* "mpfmc/core/audio/audio_interface.pyx":471 + /* "mpfmc/core/audio/audio_interface.pyx":472 * track_num: The track number to retrieve * """ * try: # <<<<<<<<<<<<<< @@ -9519,7 +9520,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { - /* "mpfmc/core/audio/audio_interface.pyx":472 + /* "mpfmc/core/audio/audio_interface.pyx":473 * """ * try: * return self.tracks[track_num] # <<<<<<<<<<<<<< @@ -9529,15 +9530,15 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_XDECREF(__pyx_r); if (unlikely(__pyx_v_self->tracks == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(0, 472, __pyx_L3_error) + __PYX_ERR(0, 473, __pyx_L3_error) } - __pyx_t_4 = __Pyx_GetItemInt_List(__pyx_v_self->tracks, __pyx_v_track_num, int, 1, __Pyx_PyInt_From_int, 1, 1, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 472, __pyx_L3_error) + __pyx_t_4 = __Pyx_GetItemInt_List(__pyx_v_self->tracks, __pyx_v_track_num, int, 1, __Pyx_PyInt_From_int, 1, 1, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 473, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_r = __pyx_t_4; __pyx_t_4 = 0; goto __pyx_L7_try_return; - /* "mpfmc/core/audio/audio_interface.pyx":471 + /* "mpfmc/core/audio/audio_interface.pyx":472 * track_num: The track number to retrieve * """ * try: # <<<<<<<<<<<<<< @@ -9548,7 +9549,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_L3_error:; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":473 + /* "mpfmc/core/audio/audio_interface.pyx":474 * try: * return self.tracks[track_num] * except IndexError: # <<<<<<<<<<<<<< @@ -9558,12 +9559,12 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_5 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_IndexError); if (__pyx_t_5) { __Pyx_AddTraceback("mpfmc.core.audio.audio_interface.AudioInterface.get_track", __pyx_clineno, __pyx_lineno, __pyx_filename); - if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_7) < 0) __PYX_ERR(0, 473, __pyx_L5_except_error) + if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_7) < 0) __PYX_ERR(0, 474, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_7); - /* "mpfmc/core/audio/audio_interface.pyx":474 + /* "mpfmc/core/audio/audio_interface.pyx":475 * return self.tracks[track_num] * except IndexError: * return None # <<<<<<<<<<<<<< @@ -9580,7 +9581,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface goto __pyx_L5_except_error; __pyx_L5_except_error:; - /* "mpfmc/core/audio/audio_interface.pyx":471 + /* "mpfmc/core/audio/audio_interface.pyx":472 * track_num: The track number to retrieve * """ * try: # <<<<<<<<<<<<<< @@ -9606,7 +9607,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface goto __pyx_L0; } - /* "mpfmc/core/audio/audio_interface.pyx":465 + /* "mpfmc/core/audio/audio_interface.pyx":466 * return [track.name for track in self.tracks] * * def get_track(self, int track_num): # <<<<<<<<<<<<<< @@ -9627,7 +9628,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":476 +/* "mpfmc/core/audio/audio_interface.pyx":477 * return None * * def get_track_type(self, str name not None): # <<<<<<<<<<<<<< @@ -9645,7 +9646,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("get_track_type (wrapper)", 0); - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyUnicode_Type), 0, "name", 1))) __PYX_ERR(0, 476, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyUnicode_Type), 0, "name", 1))) __PYX_ERR(0, 477, __pyx_L1_error) __pyx_r = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_58get_track_type(((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface_AudioInterface *)__pyx_v_self), ((PyObject*)__pyx_v_name)); /* function exit code */ @@ -9670,14 +9671,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("get_track_type", 0); - /* "mpfmc/core/audio/audio_interface.pyx":482 + /* "mpfmc/core/audio/audio_interface.pyx":483 * name: The name of the track * """ * track = self.get_track_by_name(name) # <<<<<<<<<<<<<< * if track: * return track.type */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_get_track_by_name); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 482, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_get_track_by_name); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 483, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -9691,23 +9692,23 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_v_name) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_name); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 482, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 483, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_v_track = __pyx_t_1; __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":483 + /* "mpfmc/core/audio/audio_interface.pyx":484 * """ * track = self.get_track_by_name(name) * if track: # <<<<<<<<<<<<<< * return track.type * else: */ - __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_v_track); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(0, 483, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_v_track); if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(0, 484, __pyx_L1_error) if (__pyx_t_4) { - /* "mpfmc/core/audio/audio_interface.pyx":484 + /* "mpfmc/core/audio/audio_interface.pyx":485 * track = self.get_track_by_name(name) * if track: * return track.type # <<<<<<<<<<<<<< @@ -9715,13 +9716,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * return None */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_type); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 484, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_type); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 485, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":483 + /* "mpfmc/core/audio/audio_interface.pyx":484 * """ * track = self.get_track_by_name(name) * if track: # <<<<<<<<<<<<<< @@ -9730,7 +9731,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":486 + /* "mpfmc/core/audio/audio_interface.pyx":487 * return track.type * else: * return None # <<<<<<<<<<<<<< @@ -9743,7 +9744,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface goto __pyx_L0; } - /* "mpfmc/core/audio/audio_interface.pyx":476 + /* "mpfmc/core/audio/audio_interface.pyx":477 * return None * * def get_track_type(self, str name not None): # <<<<<<<<<<<<<< @@ -9765,7 +9766,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":488 +/* "mpfmc/core/audio/audio_interface.pyx":489 * return None * * def get_track_by_name(self, str name not None): # <<<<<<<<<<<<<< @@ -9783,7 +9784,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("get_track_by_name (wrapper)", 0); - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyUnicode_Type), 0, "name", 1))) __PYX_ERR(0, 488, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyUnicode_Type), 0, "name", 1))) __PYX_ERR(0, 489, __pyx_L1_error) __pyx_r = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_60get_track_by_name(((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface_AudioInterface *)__pyx_v_self), ((PyObject*)__pyx_v_name)); /* function exit code */ @@ -9810,14 +9811,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_RefNannySetupContext("get_track_by_name", 0); __Pyx_INCREF(__pyx_v_name); - /* "mpfmc/core/audio/audio_interface.pyx":494 + /* "mpfmc/core/audio/audio_interface.pyx":495 * name: The track name to retrieve * """ * name = name.lower() # <<<<<<<<<<<<<< * for track in self.tracks: * if name == track.name: */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_lower); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 494, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_lower); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 495, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { @@ -9831,14 +9832,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; - if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 494, __pyx_L1_error) + if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 495, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (!(likely(PyUnicode_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(0, 494, __pyx_L1_error) + if (!(likely(PyUnicode_CheckExact(__pyx_t_1))||((__pyx_t_1) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_1)->tp_name), 0))) __PYX_ERR(0, 495, __pyx_L1_error) __Pyx_DECREF_SET(__pyx_v_name, ((PyObject*)__pyx_t_1)); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":495 + /* "mpfmc/core/audio/audio_interface.pyx":496 * """ * name = name.lower() * for track in self.tracks: # <<<<<<<<<<<<<< @@ -9847,34 +9848,34 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_v_self->tracks == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(0, 495, __pyx_L1_error) + __PYX_ERR(0, 496, __pyx_L1_error) } __pyx_t_1 = __pyx_v_self->tracks; __Pyx_INCREF(__pyx_t_1); __pyx_t_4 = 0; for (;;) { if (__pyx_t_4 >= PyList_GET_SIZE(__pyx_t_1)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_2 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_4); __Pyx_INCREF(__pyx_t_2); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 495, __pyx_L1_error) + __pyx_t_2 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_4); __Pyx_INCREF(__pyx_t_2); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 496, __pyx_L1_error) #else - __pyx_t_2 = PySequence_ITEM(__pyx_t_1, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 495, __pyx_L1_error) + __pyx_t_2 = PySequence_ITEM(__pyx_t_1, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 496, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); #endif __Pyx_XDECREF_SET(__pyx_v_track, __pyx_t_2); __pyx_t_2 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":496 + /* "mpfmc/core/audio/audio_interface.pyx":497 * name = name.lower() * for track in self.tracks: * if name == track.name: # <<<<<<<<<<<<<< * return track * */ - __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_name); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 496, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_name); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 497, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_5 = (__Pyx_PyUnicode_Equals(__pyx_v_name, __pyx_t_2, Py_EQ)); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(0, 496, __pyx_L1_error) + __pyx_t_5 = (__Pyx_PyUnicode_Equals(__pyx_v_name, __pyx_t_2, Py_EQ)); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(0, 497, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (__pyx_t_5) { - /* "mpfmc/core/audio/audio_interface.pyx":497 + /* "mpfmc/core/audio/audio_interface.pyx":498 * for track in self.tracks: * if name == track.name: * return track # <<<<<<<<<<<<<< @@ -9887,7 +9888,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":496 + /* "mpfmc/core/audio/audio_interface.pyx":497 * name = name.lower() * for track in self.tracks: * if name == track.name: # <<<<<<<<<<<<<< @@ -9896,7 +9897,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":495 + /* "mpfmc/core/audio/audio_interface.pyx":496 * """ * name = name.lower() * for track in self.tracks: # <<<<<<<<<<<<<< @@ -9906,7 +9907,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":499 + /* "mpfmc/core/audio/audio_interface.pyx":500 * return track * * return None # <<<<<<<<<<<<<< @@ -9917,7 +9918,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":488 + /* "mpfmc/core/audio/audio_interface.pyx":489 * return None * * def get_track_by_name(self, str name not None): # <<<<<<<<<<<<<< @@ -9940,7 +9941,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":501 +/* "mpfmc/core/audio/audio_interface.pyx":502 * return None * * def create_standard_track(self, object mc, str name not None, # <<<<<<<<<<<<<< @@ -9989,7 +9990,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("create_standard_track", 0, 2, 4, 1); __PYX_ERR(0, 501, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("create_standard_track", 0, 2, 4, 1); __PYX_ERR(0, 502, __pyx_L3_error) } CYTHON_FALLTHROUGH; case 2: @@ -10005,7 +10006,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "create_standard_track") < 0)) __PYX_ERR(0, 501, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "create_standard_track") < 0)) __PYX_ERR(0, 502, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -10022,25 +10023,25 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_v_mc = values[0]; __pyx_v_name = ((PyObject*)values[1]); if (values[2]) { - __pyx_v_max_simultaneous_sounds = __Pyx_PyInt_As_int(values[2]); if (unlikely((__pyx_v_max_simultaneous_sounds == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 502, __pyx_L3_error) + __pyx_v_max_simultaneous_sounds = __Pyx_PyInt_As_int(values[2]); if (unlikely((__pyx_v_max_simultaneous_sounds == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 503, __pyx_L3_error) } else { __pyx_v_max_simultaneous_sounds = __pyx_k__2; } if (values[3]) { - __pyx_v_volume = __pyx_PyFloat_AsFloat(values[3]); if (unlikely((__pyx_v_volume == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 503, __pyx_L3_error) + __pyx_v_volume = __pyx_PyFloat_AsFloat(values[3]); if (unlikely((__pyx_v_volume == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 504, __pyx_L3_error) } else { __pyx_v_volume = ((float)1.0); } } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("create_standard_track", 0, 2, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 501, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("create_standard_track", 0, 2, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 502, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("mpfmc.core.audio.audio_interface.AudioInterface.create_standard_track", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyUnicode_Type), 0, "name", 1))) __PYX_ERR(0, 501, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyUnicode_Type), 0, "name", 1))) __PYX_ERR(0, 502, __pyx_L1_error) __pyx_r = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_62create_standard_track(((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface_AudioInterface *)__pyx_v_self), __pyx_v_mc, __pyx_v_name, __pyx_v_max_simultaneous_sounds, __pyx_v_volume); /* function exit code */ @@ -10075,7 +10076,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_RefNannySetupContext("create_standard_track", 0); __Pyx_INCREF(__pyx_v_name); - /* "mpfmc/core/audio/audio_interface.pyx":515 + /* "mpfmc/core/audio/audio_interface.pyx":516 * A Track object for the newly created track * """ * cdef int track_num = len(self.tracks) # <<<<<<<<<<<<<< @@ -10086,13 +10087,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(0, 515, __pyx_L1_error) + __PYX_ERR(0, 516, __pyx_L1_error) } - __pyx_t_2 = PyList_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(0, 515, __pyx_L1_error) + __pyx_t_2 = PyList_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(0, 516, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_track_num = __pyx_t_2; - /* "mpfmc/core/audio/audio_interface.pyx":516 + /* "mpfmc/core/audio/audio_interface.pyx":517 * """ * cdef int track_num = len(self.tracks) * if track_num == MAX_TRACKS: # <<<<<<<<<<<<<< @@ -10102,21 +10103,21 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_3 = ((__pyx_v_track_num == 8) != 0); if (__pyx_t_3) { - /* "mpfmc/core/audio/audio_interface.pyx":517 + /* "mpfmc/core/audio/audio_interface.pyx":518 * cdef int track_num = len(self.tracks) * if track_num == MAX_TRACKS: * self.log.error("Add track failed - the maximum number of tracks " # <<<<<<<<<<<<<< * "(%d) has been reached.", MAX_TRACKS) * return None */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_error); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 517, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_error); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 518, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 517, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 518, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":519 + /* "mpfmc/core/audio/audio_interface.pyx":520 * self.log.error("Add track failed - the maximum number of tracks " * "(%d) has been reached.", MAX_TRACKS) * return None # <<<<<<<<<<<<<< @@ -10127,7 +10128,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":516 + /* "mpfmc/core/audio/audio_interface.pyx":517 * """ * cdef int track_num = len(self.tracks) * if track_num == MAX_TRACKS: # <<<<<<<<<<<<<< @@ -10136,14 +10137,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":522 + /* "mpfmc/core/audio/audio_interface.pyx":523 * * # Make sure track name does not already exist (no duplicates allowed) * name = name.lower() # <<<<<<<<<<<<<< * for track in self.tracks: * if name == track.name: */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_lower); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 522, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_lower); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 523, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) { @@ -10157,14 +10158,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_4 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_1); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 522, __pyx_L1_error) + if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 523, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (!(likely(PyUnicode_CheckExact(__pyx_t_4))||((__pyx_t_4) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_4)->tp_name), 0))) __PYX_ERR(0, 522, __pyx_L1_error) + if (!(likely(PyUnicode_CheckExact(__pyx_t_4))||((__pyx_t_4) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_4)->tp_name), 0))) __PYX_ERR(0, 523, __pyx_L1_error) __Pyx_DECREF_SET(__pyx_v_name, ((PyObject*)__pyx_t_4)); __pyx_t_4 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":523 + /* "mpfmc/core/audio/audio_interface.pyx":524 * # Make sure track name does not already exist (no duplicates allowed) * name = name.lower() * for track in self.tracks: # <<<<<<<<<<<<<< @@ -10173,41 +10174,41 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_v_self->tracks == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(0, 523, __pyx_L1_error) + __PYX_ERR(0, 524, __pyx_L1_error) } __pyx_t_4 = __pyx_v_self->tracks; __Pyx_INCREF(__pyx_t_4); __pyx_t_2 = 0; for (;;) { if (__pyx_t_2 >= PyList_GET_SIZE(__pyx_t_4)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_4, __pyx_t_2); __Pyx_INCREF(__pyx_t_1); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 523, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_4, __pyx_t_2); __Pyx_INCREF(__pyx_t_1); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 524, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_4, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 523, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_4, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 524, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif __Pyx_XDECREF_SET(__pyx_v_track, __pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":524 + /* "mpfmc/core/audio/audio_interface.pyx":525 * name = name.lower() * for track in self.tracks: * if name == track.name: # <<<<<<<<<<<<<< * self.log.error("Add track failed - the track name '%s' already exists.", name) * return None */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_name); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 524, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_name); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 525, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_v_name, __pyx_t_1, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 524, __pyx_L1_error) + __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_v_name, __pyx_t_1, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 525, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; if (__pyx_t_3) { - /* "mpfmc/core/audio/audio_interface.pyx":525 + /* "mpfmc/core/audio/audio_interface.pyx":526 * for track in self.tracks: * if name == track.name: * self.log.error("Add track failed - the track name '%s' already exists.", name) # <<<<<<<<<<<<<< * return None * */ - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_error); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 525, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_error); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 526, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_6 = NULL; __pyx_t_7 = 0; @@ -10224,7 +10225,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_5)) { PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_kp_u_Add_track_failed_the_track_name, __pyx_v_name}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 525, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 526, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_1); } else @@ -10232,13 +10233,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_5)) { PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_kp_u_Add_track_failed_the_track_name, __pyx_v_name}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 525, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 526, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_1); } else #endif { - __pyx_t_8 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 525, __pyx_L1_error) + __pyx_t_8 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 526, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_6) { __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_6); __pyx_t_6 = NULL; @@ -10249,14 +10250,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(__pyx_v_name); __Pyx_GIVEREF(__pyx_v_name); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_7, __pyx_v_name); - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 525, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 526, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":526 + /* "mpfmc/core/audio/audio_interface.pyx":527 * if name == track.name: * self.log.error("Add track failed - the track name '%s' already exists.", name) * return None # <<<<<<<<<<<<<< @@ -10268,7 +10269,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":524 + /* "mpfmc/core/audio/audio_interface.pyx":525 * name = name.lower() * for track in self.tracks: * if name == track.name: # <<<<<<<<<<<<<< @@ -10277,7 +10278,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":523 + /* "mpfmc/core/audio/audio_interface.pyx":524 * # Make sure track name does not already exist (no duplicates allowed) * name = name.lower() * for track in self.tracks: # <<<<<<<<<<<<<< @@ -10287,7 +10288,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":529 + /* "mpfmc/core/audio/audio_interface.pyx":530 * * # Make sure audio callback function cannot be called while we are changing the track data * SDL_LockAudio() # <<<<<<<<<<<<<< @@ -10296,64 +10297,64 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ SDL_LockAudio(); - /* "mpfmc/core/audio/audio_interface.pyx":533 + /* "mpfmc/core/audio/audio_interface.pyx":534 * # Create the new standard track * new_track = TrackStandard(mc, * pycapsule.PyCapsule_New(&self.audio_callback_data, NULL, NULL), # <<<<<<<<<<<<<< * name, * track_num, */ - __pyx_t_4 = PyCapsule_New((&__pyx_v_self->audio_callback_data), NULL, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 533, __pyx_L1_error) + __pyx_t_4 = PyCapsule_New((&__pyx_v_self->audio_callback_data), NULL, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 534, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - /* "mpfmc/core/audio/audio_interface.pyx":535 + /* "mpfmc/core/audio/audio_interface.pyx":536 * pycapsule.PyCapsule_New(&self.audio_callback_data, NULL, NULL), * name, * track_num, # <<<<<<<<<<<<<< * self.audio_callback_data.buffer_size, * max_simultaneous_sounds, */ - __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_track_num); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 535, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_track_num); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 536, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - /* "mpfmc/core/audio/audio_interface.pyx":536 + /* "mpfmc/core/audio/audio_interface.pyx":537 * name, * track_num, * self.audio_callback_data.buffer_size, # <<<<<<<<<<<<<< * max_simultaneous_sounds, * volume) */ - __pyx_t_5 = __Pyx_PyInt_From_Uint32(__pyx_v_self->audio_callback_data.buffer_size); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 536, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyInt_From_Uint32(__pyx_v_self->audio_callback_data.buffer_size); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 537, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - /* "mpfmc/core/audio/audio_interface.pyx":537 + /* "mpfmc/core/audio/audio_interface.pyx":538 * track_num, * self.audio_callback_data.buffer_size, * max_simultaneous_sounds, # <<<<<<<<<<<<<< * volume) * self.tracks.append(new_track) */ - __pyx_t_8 = __Pyx_PyInt_From_int(__pyx_v_max_simultaneous_sounds); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 537, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyInt_From_int(__pyx_v_max_simultaneous_sounds); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 538, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - /* "mpfmc/core/audio/audio_interface.pyx":538 + /* "mpfmc/core/audio/audio_interface.pyx":539 * self.audio_callback_data.buffer_size, * max_simultaneous_sounds, * volume) # <<<<<<<<<<<<<< * self.tracks.append(new_track) * */ - __pyx_t_6 = PyFloat_FromDouble(__pyx_v_volume); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 538, __pyx_L1_error) + __pyx_t_6 = PyFloat_FromDouble(__pyx_v_volume); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 539, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - /* "mpfmc/core/audio/audio_interface.pyx":532 + /* "mpfmc/core/audio/audio_interface.pyx":533 * * # Create the new standard track * new_track = TrackStandard(mc, # <<<<<<<<<<<<<< * pycapsule.PyCapsule_New(&self.audio_callback_data, NULL, NULL), * name, */ - __pyx_t_9 = PyTuple_New(7); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 532, __pyx_L1_error) + __pyx_t_9 = PyTuple_New(7); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 533, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_INCREF(__pyx_v_mc); __Pyx_GIVEREF(__pyx_v_mc); @@ -10376,13 +10377,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_5 = 0; __pyx_t_8 = 0; __pyx_t_6 = 0; - __pyx_t_6 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_14track_standard_TrackStandard), __pyx_t_9, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 532, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_14track_standard_TrackStandard), __pyx_t_9, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 533, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __pyx_v_new_track = ((struct __pyx_obj_5mpfmc_4core_5audio_14track_standard_TrackStandard *)__pyx_t_6); __pyx_t_6 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":539 + /* "mpfmc/core/audio/audio_interface.pyx":540 * max_simultaneous_sounds, * volume) * self.tracks.append(new_track) # <<<<<<<<<<<<<< @@ -10391,11 +10392,11 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_v_self->tracks == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "append"); - __PYX_ERR(0, 539, __pyx_L1_error) + __PYX_ERR(0, 540, __pyx_L1_error) } - __pyx_t_10 = __Pyx_PyList_Append(__pyx_v_self->tracks, ((PyObject *)__pyx_v_new_track)); if (unlikely(__pyx_t_10 == ((int)-1))) __PYX_ERR(0, 539, __pyx_L1_error) + __pyx_t_10 = __Pyx_PyList_Append(__pyx_v_self->tracks, ((PyObject *)__pyx_v_new_track)); if (unlikely(__pyx_t_10 == ((int)-1))) __PYX_ERR(0, 540, __pyx_L1_error) - /* "mpfmc/core/audio/audio_interface.pyx":542 + /* "mpfmc/core/audio/audio_interface.pyx":543 * * # Update audio callback data with new track * self.audio_callback_data.track_count = len(self.tracks) # <<<<<<<<<<<<<< @@ -10406,13 +10407,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(__pyx_t_6); if (unlikely(__pyx_t_6 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(0, 542, __pyx_L1_error) + __PYX_ERR(0, 543, __pyx_L1_error) } - __pyx_t_2 = PyList_GET_SIZE(__pyx_t_6); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(0, 542, __pyx_L1_error) + __pyx_t_2 = PyList_GET_SIZE(__pyx_t_6); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(0, 543, __pyx_L1_error) __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_v_self->audio_callback_data.track_count = __pyx_t_2; - /* "mpfmc/core/audio/audio_interface.pyx":543 + /* "mpfmc/core/audio/audio_interface.pyx":544 * # Update audio callback data with new track * self.audio_callback_data.track_count = len(self.tracks) * self.audio_callback_data.tracks[track_num] = new_track.state # <<<<<<<<<<<<<< @@ -10422,7 +10423,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_11 = __pyx_v_new_track->__pyx_base.state; (__pyx_v_self->audio_callback_data.tracks[__pyx_v_track_num]) = __pyx_t_11; - /* "mpfmc/core/audio/audio_interface.pyx":546 + /* "mpfmc/core/audio/audio_interface.pyx":547 * * # Allow audio callback function to be called again * SDL_UnlockAudio() # <<<<<<<<<<<<<< @@ -10431,14 +10432,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ SDL_UnlockAudio(); - /* "mpfmc/core/audio/audio_interface.pyx":548 + /* "mpfmc/core/audio/audio_interface.pyx":549 * SDL_UnlockAudio() * * self.log.debug("The '%s' standard track has successfully been created.", name) # <<<<<<<<<<<<<< * * return new_track */ - __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_debug); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 548, __pyx_L1_error) + __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_debug); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 549, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __pyx_t_8 = NULL; __pyx_t_7 = 0; @@ -10455,7 +10456,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_9)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_The_s_standard_track_has_success, __pyx_v_name}; - __pyx_t_6 = __Pyx_PyFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 548, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 549, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_6); } else @@ -10463,13 +10464,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_9)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_The_s_standard_track_has_success, __pyx_v_name}; - __pyx_t_6 = __Pyx_PyCFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 548, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyCFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 549, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_6); } else #endif { - __pyx_t_5 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 548, __pyx_L1_error) + __pyx_t_5 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 549, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_8); __pyx_t_8 = NULL; @@ -10480,14 +10481,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(__pyx_v_name); __Pyx_GIVEREF(__pyx_v_name); PyTuple_SET_ITEM(__pyx_t_5, 1+__pyx_t_7, __pyx_v_name); - __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_5, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 548, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_5, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 549, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":550 + /* "mpfmc/core/audio/audio_interface.pyx":551 * self.log.debug("The '%s' standard track has successfully been created.", name) * * return new_track # <<<<<<<<<<<<<< @@ -10499,7 +10500,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_r = ((PyObject *)__pyx_v_new_track); goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":501 + /* "mpfmc/core/audio/audio_interface.pyx":502 * return None * * def create_standard_track(self, object mc, str name not None, # <<<<<<<<<<<<<< @@ -10526,7 +10527,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":552 +/* "mpfmc/core/audio/audio_interface.pyx":553 * return new_track * * def create_sound_loop_track(self, object mc, str name not None, # <<<<<<<<<<<<<< @@ -10575,7 +10576,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("create_sound_loop_track", 0, 2, 4, 1); __PYX_ERR(0, 552, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("create_sound_loop_track", 0, 2, 4, 1); __PYX_ERR(0, 553, __pyx_L3_error) } CYTHON_FALLTHROUGH; case 2: @@ -10591,7 +10592,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "create_sound_loop_track") < 0)) __PYX_ERR(0, 552, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "create_sound_loop_track") < 0)) __PYX_ERR(0, 553, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -10608,25 +10609,25 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_v_mc = values[0]; __pyx_v_name = ((PyObject*)values[1]); if (values[2]) { - __pyx_v_max_layers = __Pyx_PyInt_As_int(values[2]); if (unlikely((__pyx_v_max_layers == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 553, __pyx_L3_error) + __pyx_v_max_layers = __Pyx_PyInt_As_int(values[2]); if (unlikely((__pyx_v_max_layers == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 554, __pyx_L3_error) } else { __pyx_v_max_layers = ((int)8); } if (values[3]) { - __pyx_v_volume = __pyx_PyFloat_AsFloat(values[3]); if (unlikely((__pyx_v_volume == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 554, __pyx_L3_error) + __pyx_v_volume = __pyx_PyFloat_AsFloat(values[3]); if (unlikely((__pyx_v_volume == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 555, __pyx_L3_error) } else { __pyx_v_volume = ((float)1.0); } } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("create_sound_loop_track", 0, 2, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 552, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("create_sound_loop_track", 0, 2, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 553, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("mpfmc.core.audio.audio_interface.AudioInterface.create_sound_loop_track", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyUnicode_Type), 0, "name", 1))) __PYX_ERR(0, 552, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyUnicode_Type), 0, "name", 1))) __PYX_ERR(0, 553, __pyx_L1_error) __pyx_r = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_64create_sound_loop_track(((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface_AudioInterface *)__pyx_v_self), __pyx_v_mc, __pyx_v_name, __pyx_v_max_layers, __pyx_v_volume); /* function exit code */ @@ -10661,7 +10662,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_RefNannySetupContext("create_sound_loop_track", 0); __Pyx_INCREF(__pyx_v_name); - /* "mpfmc/core/audio/audio_interface.pyx":566 + /* "mpfmc/core/audio/audio_interface.pyx":567 * A Track object for the newly created track * """ * cdef int track_num = len(self.tracks) # <<<<<<<<<<<<<< @@ -10672,13 +10673,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(0, 566, __pyx_L1_error) + __PYX_ERR(0, 567, __pyx_L1_error) } - __pyx_t_2 = PyList_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(0, 566, __pyx_L1_error) + __pyx_t_2 = PyList_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(0, 567, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_track_num = __pyx_t_2; - /* "mpfmc/core/audio/audio_interface.pyx":567 + /* "mpfmc/core/audio/audio_interface.pyx":568 * """ * cdef int track_num = len(self.tracks) * if track_num == MAX_TRACKS: # <<<<<<<<<<<<<< @@ -10688,21 +10689,21 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_3 = ((__pyx_v_track_num == 8) != 0); if (__pyx_t_3) { - /* "mpfmc/core/audio/audio_interface.pyx":568 + /* "mpfmc/core/audio/audio_interface.pyx":569 * cdef int track_num = len(self.tracks) * if track_num == MAX_TRACKS: * self.log.error("Add track failed - the maximum number of tracks " # <<<<<<<<<<<<<< * "(%d) has been reached.", MAX_TRACKS) * return None */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_error); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 568, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_error); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 569, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 568, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 569, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":570 + /* "mpfmc/core/audio/audio_interface.pyx":571 * self.log.error("Add track failed - the maximum number of tracks " * "(%d) has been reached.", MAX_TRACKS) * return None # <<<<<<<<<<<<<< @@ -10713,7 +10714,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":567 + /* "mpfmc/core/audio/audio_interface.pyx":568 * """ * cdef int track_num = len(self.tracks) * if track_num == MAX_TRACKS: # <<<<<<<<<<<<<< @@ -10722,14 +10723,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":573 + /* "mpfmc/core/audio/audio_interface.pyx":574 * * # Make sure track name does not already exist (no duplicates allowed) * name = name.lower() # <<<<<<<<<<<<<< * for track in self.tracks: * if name == track.name: */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_lower); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 573, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_lower); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 574, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) { @@ -10743,14 +10744,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_4 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_1); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 573, __pyx_L1_error) + if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 574, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (!(likely(PyUnicode_CheckExact(__pyx_t_4))||((__pyx_t_4) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_4)->tp_name), 0))) __PYX_ERR(0, 573, __pyx_L1_error) + if (!(likely(PyUnicode_CheckExact(__pyx_t_4))||((__pyx_t_4) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_4)->tp_name), 0))) __PYX_ERR(0, 574, __pyx_L1_error) __Pyx_DECREF_SET(__pyx_v_name, ((PyObject*)__pyx_t_4)); __pyx_t_4 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":574 + /* "mpfmc/core/audio/audio_interface.pyx":575 * # Make sure track name does not already exist (no duplicates allowed) * name = name.lower() * for track in self.tracks: # <<<<<<<<<<<<<< @@ -10759,41 +10760,41 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_v_self->tracks == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(0, 574, __pyx_L1_error) + __PYX_ERR(0, 575, __pyx_L1_error) } __pyx_t_4 = __pyx_v_self->tracks; __Pyx_INCREF(__pyx_t_4); __pyx_t_2 = 0; for (;;) { if (__pyx_t_2 >= PyList_GET_SIZE(__pyx_t_4)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_4, __pyx_t_2); __Pyx_INCREF(__pyx_t_1); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 574, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_4, __pyx_t_2); __Pyx_INCREF(__pyx_t_1); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 575, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_4, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 574, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_4, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 575, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif __Pyx_XDECREF_SET(__pyx_v_track, __pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":575 + /* "mpfmc/core/audio/audio_interface.pyx":576 * name = name.lower() * for track in self.tracks: * if name == track.name: # <<<<<<<<<<<<<< * self.log.error("Add track failed - the track name '%s' already exists.", name) * return None */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_name); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 575, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_name); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 576, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_v_name, __pyx_t_1, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 575, __pyx_L1_error) + __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_v_name, __pyx_t_1, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 576, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; if (__pyx_t_3) { - /* "mpfmc/core/audio/audio_interface.pyx":576 + /* "mpfmc/core/audio/audio_interface.pyx":577 * for track in self.tracks: * if name == track.name: * self.log.error("Add track failed - the track name '%s' already exists.", name) # <<<<<<<<<<<<<< * return None * */ - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_error); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 576, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_error); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 577, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_6 = NULL; __pyx_t_7 = 0; @@ -10810,7 +10811,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_5)) { PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_kp_u_Add_track_failed_the_track_name, __pyx_v_name}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 576, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 577, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_1); } else @@ -10818,13 +10819,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_5)) { PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_kp_u_Add_track_failed_the_track_name, __pyx_v_name}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 576, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 577, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_1); } else #endif { - __pyx_t_8 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 576, __pyx_L1_error) + __pyx_t_8 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 577, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_6) { __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_6); __pyx_t_6 = NULL; @@ -10835,14 +10836,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(__pyx_v_name); __Pyx_GIVEREF(__pyx_v_name); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_7, __pyx_v_name); - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 576, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 577, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":577 + /* "mpfmc/core/audio/audio_interface.pyx":578 * if name == track.name: * self.log.error("Add track failed - the track name '%s' already exists.", name) * return None # <<<<<<<<<<<<<< @@ -10854,7 +10855,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":575 + /* "mpfmc/core/audio/audio_interface.pyx":576 * name = name.lower() * for track in self.tracks: * if name == track.name: # <<<<<<<<<<<<<< @@ -10863,7 +10864,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":574 + /* "mpfmc/core/audio/audio_interface.pyx":575 * # Make sure track name does not already exist (no duplicates allowed) * name = name.lower() * for track in self.tracks: # <<<<<<<<<<<<<< @@ -10873,7 +10874,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":580 + /* "mpfmc/core/audio/audio_interface.pyx":581 * * # Make sure audio callback function cannot be called while we are changing the track data * SDL_LockAudio() # <<<<<<<<<<<<<< @@ -10882,64 +10883,64 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ SDL_LockAudio(); - /* "mpfmc/core/audio/audio_interface.pyx":584 + /* "mpfmc/core/audio/audio_interface.pyx":585 * # Create the new live loop track * new_track = TrackSoundLoop(mc, * pycapsule.PyCapsule_New(&self.audio_callback_data, NULL, NULL), # <<<<<<<<<<<<<< * name, * track_num, */ - __pyx_t_4 = PyCapsule_New((&__pyx_v_self->audio_callback_data), NULL, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 584, __pyx_L1_error) + __pyx_t_4 = PyCapsule_New((&__pyx_v_self->audio_callback_data), NULL, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 585, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - /* "mpfmc/core/audio/audio_interface.pyx":586 + /* "mpfmc/core/audio/audio_interface.pyx":587 * pycapsule.PyCapsule_New(&self.audio_callback_data, NULL, NULL), * name, * track_num, # <<<<<<<<<<<<<< * self.audio_callback_data.buffer_size, * max_layers, */ - __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_track_num); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 586, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_track_num); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 587, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - /* "mpfmc/core/audio/audio_interface.pyx":587 + /* "mpfmc/core/audio/audio_interface.pyx":588 * name, * track_num, * self.audio_callback_data.buffer_size, # <<<<<<<<<<<<<< * max_layers, * volume) */ - __pyx_t_5 = __Pyx_PyInt_From_Uint32(__pyx_v_self->audio_callback_data.buffer_size); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 587, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyInt_From_Uint32(__pyx_v_self->audio_callback_data.buffer_size); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 588, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - /* "mpfmc/core/audio/audio_interface.pyx":588 + /* "mpfmc/core/audio/audio_interface.pyx":589 * track_num, * self.audio_callback_data.buffer_size, * max_layers, # <<<<<<<<<<<<<< * volume) * self.tracks.append(new_track) */ - __pyx_t_8 = __Pyx_PyInt_From_int(__pyx_v_max_layers); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 588, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyInt_From_int(__pyx_v_max_layers); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 589, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - /* "mpfmc/core/audio/audio_interface.pyx":589 + /* "mpfmc/core/audio/audio_interface.pyx":590 * self.audio_callback_data.buffer_size, * max_layers, * volume) # <<<<<<<<<<<<<< * self.tracks.append(new_track) * */ - __pyx_t_6 = PyFloat_FromDouble(__pyx_v_volume); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 589, __pyx_L1_error) + __pyx_t_6 = PyFloat_FromDouble(__pyx_v_volume); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 590, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - /* "mpfmc/core/audio/audio_interface.pyx":583 + /* "mpfmc/core/audio/audio_interface.pyx":584 * * # Create the new live loop track * new_track = TrackSoundLoop(mc, # <<<<<<<<<<<<<< * pycapsule.PyCapsule_New(&self.audio_callback_data, NULL, NULL), * name, */ - __pyx_t_9 = PyTuple_New(7); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 583, __pyx_L1_error) + __pyx_t_9 = PyTuple_New(7); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 584, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_INCREF(__pyx_v_mc); __Pyx_GIVEREF(__pyx_v_mc); @@ -10962,13 +10963,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_5 = 0; __pyx_t_8 = 0; __pyx_t_6 = 0; - __pyx_t_6 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_16track_sound_loop_TrackSoundLoop), __pyx_t_9, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 583, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_16track_sound_loop_TrackSoundLoop), __pyx_t_9, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 584, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __pyx_v_new_track = ((struct __pyx_obj_5mpfmc_4core_5audio_16track_sound_loop_TrackSoundLoop *)__pyx_t_6); __pyx_t_6 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":590 + /* "mpfmc/core/audio/audio_interface.pyx":591 * max_layers, * volume) * self.tracks.append(new_track) # <<<<<<<<<<<<<< @@ -10977,11 +10978,11 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_v_self->tracks == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "append"); - __PYX_ERR(0, 590, __pyx_L1_error) + __PYX_ERR(0, 591, __pyx_L1_error) } - __pyx_t_10 = __Pyx_PyList_Append(__pyx_v_self->tracks, ((PyObject *)__pyx_v_new_track)); if (unlikely(__pyx_t_10 == ((int)-1))) __PYX_ERR(0, 590, __pyx_L1_error) + __pyx_t_10 = __Pyx_PyList_Append(__pyx_v_self->tracks, ((PyObject *)__pyx_v_new_track)); if (unlikely(__pyx_t_10 == ((int)-1))) __PYX_ERR(0, 591, __pyx_L1_error) - /* "mpfmc/core/audio/audio_interface.pyx":593 + /* "mpfmc/core/audio/audio_interface.pyx":594 * * # Update audio callback data with new track * self.audio_callback_data.track_count = len(self.tracks) # <<<<<<<<<<<<<< @@ -10992,13 +10993,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(__pyx_t_6); if (unlikely(__pyx_t_6 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(0, 593, __pyx_L1_error) + __PYX_ERR(0, 594, __pyx_L1_error) } - __pyx_t_2 = PyList_GET_SIZE(__pyx_t_6); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(0, 593, __pyx_L1_error) + __pyx_t_2 = PyList_GET_SIZE(__pyx_t_6); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(0, 594, __pyx_L1_error) __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_v_self->audio_callback_data.track_count = __pyx_t_2; - /* "mpfmc/core/audio/audio_interface.pyx":594 + /* "mpfmc/core/audio/audio_interface.pyx":595 * # Update audio callback data with new track * self.audio_callback_data.track_count = len(self.tracks) * self.audio_callback_data.tracks[track_num] = new_track.state # <<<<<<<<<<<<<< @@ -11008,7 +11009,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_11 = __pyx_v_new_track->__pyx_base.state; (__pyx_v_self->audio_callback_data.tracks[__pyx_v_track_num]) = __pyx_t_11; - /* "mpfmc/core/audio/audio_interface.pyx":597 + /* "mpfmc/core/audio/audio_interface.pyx":598 * * # Allow audio callback function to be called again * SDL_UnlockAudio() # <<<<<<<<<<<<<< @@ -11017,14 +11018,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ SDL_UnlockAudio(); - /* "mpfmc/core/audio/audio_interface.pyx":599 + /* "mpfmc/core/audio/audio_interface.pyx":600 * SDL_UnlockAudio() * * self.log.debug("The '%s' live loop track has successfully been created.", name) # <<<<<<<<<<<<<< * * return new_track */ - __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_debug); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 599, __pyx_L1_error) + __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_debug); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 600, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __pyx_t_8 = NULL; __pyx_t_7 = 0; @@ -11041,7 +11042,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_9)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_The_s_live_loop_track_has_succes, __pyx_v_name}; - __pyx_t_6 = __Pyx_PyFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 599, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 600, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_6); } else @@ -11049,13 +11050,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_9)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_The_s_live_loop_track_has_succes, __pyx_v_name}; - __pyx_t_6 = __Pyx_PyCFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 599, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyCFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 600, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_6); } else #endif { - __pyx_t_5 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 599, __pyx_L1_error) + __pyx_t_5 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 600, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_8); __pyx_t_8 = NULL; @@ -11066,14 +11067,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(__pyx_v_name); __Pyx_GIVEREF(__pyx_v_name); PyTuple_SET_ITEM(__pyx_t_5, 1+__pyx_t_7, __pyx_v_name); - __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_5, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 599, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_5, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 600, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":601 + /* "mpfmc/core/audio/audio_interface.pyx":602 * self.log.debug("The '%s' live loop track has successfully been created.", name) * * return new_track # <<<<<<<<<<<<<< @@ -11085,7 +11086,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_r = ((PyObject *)__pyx_v_new_track); goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":552 + /* "mpfmc/core/audio/audio_interface.pyx":553 * return new_track * * def create_sound_loop_track(self, object mc, str name not None, # <<<<<<<<<<<<<< @@ -11112,7 +11113,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":603 +/* "mpfmc/core/audio/audio_interface.pyx":604 * return new_track * * def create_playlist_track(self, object mc, str name not None, float crossfade_time=0.0, float volume=1.0): # <<<<<<<<<<<<<< @@ -11161,7 +11162,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface case 1: if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { - __Pyx_RaiseArgtupleInvalid("create_playlist_track", 0, 2, 4, 1); __PYX_ERR(0, 603, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("create_playlist_track", 0, 2, 4, 1); __PYX_ERR(0, 604, __pyx_L3_error) } CYTHON_FALLTHROUGH; case 2: @@ -11177,7 +11178,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "create_playlist_track") < 0)) __PYX_ERR(0, 603, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "create_playlist_track") < 0)) __PYX_ERR(0, 604, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -11194,25 +11195,25 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_v_mc = values[0]; __pyx_v_name = ((PyObject*)values[1]); if (values[2]) { - __pyx_v_crossfade_time = __pyx_PyFloat_AsFloat(values[2]); if (unlikely((__pyx_v_crossfade_time == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 603, __pyx_L3_error) + __pyx_v_crossfade_time = __pyx_PyFloat_AsFloat(values[2]); if (unlikely((__pyx_v_crossfade_time == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 604, __pyx_L3_error) } else { __pyx_v_crossfade_time = ((float)0.0); } if (values[3]) { - __pyx_v_volume = __pyx_PyFloat_AsFloat(values[3]); if (unlikely((__pyx_v_volume == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 603, __pyx_L3_error) + __pyx_v_volume = __pyx_PyFloat_AsFloat(values[3]); if (unlikely((__pyx_v_volume == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 604, __pyx_L3_error) } else { __pyx_v_volume = ((float)1.0); } } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("create_playlist_track", 0, 2, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 603, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("create_playlist_track", 0, 2, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 604, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("mpfmc.core.audio.audio_interface.AudioInterface.create_playlist_track", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyUnicode_Type), 0, "name", 1))) __PYX_ERR(0, 603, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyUnicode_Type), 0, "name", 1))) __PYX_ERR(0, 604, __pyx_L1_error) __pyx_r = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_66create_playlist_track(((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface_AudioInterface *)__pyx_v_self), __pyx_v_mc, __pyx_v_name, __pyx_v_crossfade_time, __pyx_v_volume); /* function exit code */ @@ -11247,7 +11248,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_RefNannySetupContext("create_playlist_track", 0); __Pyx_INCREF(__pyx_v_name); - /* "mpfmc/core/audio/audio_interface.pyx":620 + /* "mpfmc/core/audio/audio_interface.pyx":621 * all sound actions on the track. * """ * cdef int track_num = len(self.tracks) # <<<<<<<<<<<<<< @@ -11258,13 +11259,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(0, 620, __pyx_L1_error) + __PYX_ERR(0, 621, __pyx_L1_error) } - __pyx_t_2 = PyList_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(0, 620, __pyx_L1_error) + __pyx_t_2 = PyList_GET_SIZE(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(0, 621, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_track_num = __pyx_t_2; - /* "mpfmc/core/audio/audio_interface.pyx":621 + /* "mpfmc/core/audio/audio_interface.pyx":622 * """ * cdef int track_num = len(self.tracks) * if track_num == MAX_TRACKS: # <<<<<<<<<<<<<< @@ -11274,21 +11275,21 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_3 = ((__pyx_v_track_num == 8) != 0); if (__pyx_t_3) { - /* "mpfmc/core/audio/audio_interface.pyx":622 + /* "mpfmc/core/audio/audio_interface.pyx":623 * cdef int track_num = len(self.tracks) * if track_num == MAX_TRACKS: * self.log.error("Add track failed - the maximum number of tracks " # <<<<<<<<<<<<<< * "(%d) has been reached.", MAX_TRACKS) * return None */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_error); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 622, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_error); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 623, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 622, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 623, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":624 + /* "mpfmc/core/audio/audio_interface.pyx":625 * self.log.error("Add track failed - the maximum number of tracks " * "(%d) has been reached.", MAX_TRACKS) * return None # <<<<<<<<<<<<<< @@ -11299,7 +11300,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":621 + /* "mpfmc/core/audio/audio_interface.pyx":622 * """ * cdef int track_num = len(self.tracks) * if track_num == MAX_TRACKS: # <<<<<<<<<<<<<< @@ -11308,14 +11309,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":627 + /* "mpfmc/core/audio/audio_interface.pyx":628 * * # Make sure track name does not already exist (no duplicates allowed) * name = name.lower() # <<<<<<<<<<<<<< * for track in self.tracks: * if name == track.name: */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_lower); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 627, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_lower); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 628, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) { @@ -11329,14 +11330,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_4 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_1); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 627, __pyx_L1_error) + if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 628, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (!(likely(PyUnicode_CheckExact(__pyx_t_4))||((__pyx_t_4) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_4)->tp_name), 0))) __PYX_ERR(0, 627, __pyx_L1_error) + if (!(likely(PyUnicode_CheckExact(__pyx_t_4))||((__pyx_t_4) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_4)->tp_name), 0))) __PYX_ERR(0, 628, __pyx_L1_error) __Pyx_DECREF_SET(__pyx_v_name, ((PyObject*)__pyx_t_4)); __pyx_t_4 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":628 + /* "mpfmc/core/audio/audio_interface.pyx":629 * # Make sure track name does not already exist (no duplicates allowed) * name = name.lower() * for track in self.tracks: # <<<<<<<<<<<<<< @@ -11345,41 +11346,41 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_v_self->tracks == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(0, 628, __pyx_L1_error) + __PYX_ERR(0, 629, __pyx_L1_error) } __pyx_t_4 = __pyx_v_self->tracks; __Pyx_INCREF(__pyx_t_4); __pyx_t_2 = 0; for (;;) { if (__pyx_t_2 >= PyList_GET_SIZE(__pyx_t_4)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_1 = PyList_GET_ITEM(__pyx_t_4, __pyx_t_2); __Pyx_INCREF(__pyx_t_1); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 628, __pyx_L1_error) + __pyx_t_1 = PyList_GET_ITEM(__pyx_t_4, __pyx_t_2); __Pyx_INCREF(__pyx_t_1); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 629, __pyx_L1_error) #else - __pyx_t_1 = PySequence_ITEM(__pyx_t_4, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 628, __pyx_L1_error) + __pyx_t_1 = PySequence_ITEM(__pyx_t_4, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 629, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif __Pyx_XDECREF_SET(__pyx_v_track, __pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":629 + /* "mpfmc/core/audio/audio_interface.pyx":630 * name = name.lower() * for track in self.tracks: * if name == track.name: # <<<<<<<<<<<<<< * self.log.error("Add track failed - the track name '%s' already exists.", name) * return None */ - __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_name); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 629, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_name); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 630, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_v_name, __pyx_t_1, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 629, __pyx_L1_error) + __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_v_name, __pyx_t_1, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 630, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; if (__pyx_t_3) { - /* "mpfmc/core/audio/audio_interface.pyx":630 + /* "mpfmc/core/audio/audio_interface.pyx":631 * for track in self.tracks: * if name == track.name: * self.log.error("Add track failed - the track name '%s' already exists.", name) # <<<<<<<<<<<<<< * return None * */ - __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_error); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 630, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_error); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 631, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_6 = NULL; __pyx_t_7 = 0; @@ -11396,7 +11397,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_5)) { PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_kp_u_Add_track_failed_the_track_name, __pyx_v_name}; - __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 630, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 631, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_1); } else @@ -11404,13 +11405,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_5)) { PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_kp_u_Add_track_failed_the_track_name, __pyx_v_name}; - __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 630, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 631, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_1); } else #endif { - __pyx_t_8 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 630, __pyx_L1_error) + __pyx_t_8 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 631, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_6) { __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_6); __pyx_t_6 = NULL; @@ -11421,14 +11422,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(__pyx_v_name); __Pyx_GIVEREF(__pyx_v_name); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_7, __pyx_v_name); - __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 630, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 631, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":631 + /* "mpfmc/core/audio/audio_interface.pyx":632 * if name == track.name: * self.log.error("Add track failed - the track name '%s' already exists.", name) * return None # <<<<<<<<<<<<<< @@ -11440,7 +11441,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":629 + /* "mpfmc/core/audio/audio_interface.pyx":630 * name = name.lower() * for track in self.tracks: * if name == track.name: # <<<<<<<<<<<<<< @@ -11449,7 +11450,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":628 + /* "mpfmc/core/audio/audio_interface.pyx":629 * # Make sure track name does not already exist (no duplicates allowed) * name = name.lower() * for track in self.tracks: # <<<<<<<<<<<<<< @@ -11459,7 +11460,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":634 + /* "mpfmc/core/audio/audio_interface.pyx":635 * * # Make sure audio callback function cannot be called while we are changing the track data * SDL_LockAudio() # <<<<<<<<<<<<<< @@ -11468,54 +11469,54 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ SDL_LockAudio(); - /* "mpfmc/core/audio/audio_interface.pyx":638 + /* "mpfmc/core/audio/audio_interface.pyx":639 * # Create the new standard track * new_track = TrackStandard(mc, * pycapsule.PyCapsule_New(&self.audio_callback_data, NULL, NULL), # <<<<<<<<<<<<<< * name, * track_num, */ - __pyx_t_4 = PyCapsule_New((&__pyx_v_self->audio_callback_data), NULL, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 638, __pyx_L1_error) + __pyx_t_4 = PyCapsule_New((&__pyx_v_self->audio_callback_data), NULL, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 639, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - /* "mpfmc/core/audio/audio_interface.pyx":640 + /* "mpfmc/core/audio/audio_interface.pyx":641 * pycapsule.PyCapsule_New(&self.audio_callback_data, NULL, NULL), * name, * track_num, # <<<<<<<<<<<<<< * self.audio_callback_data.buffer_size, * 2, */ - __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_track_num); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 640, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_track_num); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 641, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - /* "mpfmc/core/audio/audio_interface.pyx":641 + /* "mpfmc/core/audio/audio_interface.pyx":642 * name, * track_num, * self.audio_callback_data.buffer_size, # <<<<<<<<<<<<<< * 2, * volume) */ - __pyx_t_5 = __Pyx_PyInt_From_Uint32(__pyx_v_self->audio_callback_data.buffer_size); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 641, __pyx_L1_error) + __pyx_t_5 = __Pyx_PyInt_From_Uint32(__pyx_v_self->audio_callback_data.buffer_size); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 642, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); - /* "mpfmc/core/audio/audio_interface.pyx":643 + /* "mpfmc/core/audio/audio_interface.pyx":644 * self.audio_callback_data.buffer_size, * 2, * volume) # <<<<<<<<<<<<<< * self.tracks.append(new_track) * */ - __pyx_t_8 = PyFloat_FromDouble(__pyx_v_volume); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 643, __pyx_L1_error) + __pyx_t_8 = PyFloat_FromDouble(__pyx_v_volume); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 644, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); - /* "mpfmc/core/audio/audio_interface.pyx":637 + /* "mpfmc/core/audio/audio_interface.pyx":638 * * # Create the new standard track * new_track = TrackStandard(mc, # <<<<<<<<<<<<<< * pycapsule.PyCapsule_New(&self.audio_callback_data, NULL, NULL), * name, */ - __pyx_t_6 = PyTuple_New(7); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 637, __pyx_L1_error) + __pyx_t_6 = PyTuple_New(7); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 638, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_INCREF(__pyx_v_mc); __Pyx_GIVEREF(__pyx_v_mc); @@ -11538,13 +11539,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_1 = 0; __pyx_t_5 = 0; __pyx_t_8 = 0; - __pyx_t_8 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_14track_standard_TrackStandard), __pyx_t_6, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 637, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_14track_standard_TrackStandard), __pyx_t_6, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 638, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_v_new_track = ((struct __pyx_obj_5mpfmc_4core_5audio_14track_standard_TrackStandard *)__pyx_t_8); __pyx_t_8 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":644 + /* "mpfmc/core/audio/audio_interface.pyx":645 * 2, * volume) * self.tracks.append(new_track) # <<<<<<<<<<<<<< @@ -11553,11 +11554,11 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_v_self->tracks == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "append"); - __PYX_ERR(0, 644, __pyx_L1_error) + __PYX_ERR(0, 645, __pyx_L1_error) } - __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_self->tracks, ((PyObject *)__pyx_v_new_track)); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(0, 644, __pyx_L1_error) + __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_self->tracks, ((PyObject *)__pyx_v_new_track)); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(0, 645, __pyx_L1_error) - /* "mpfmc/core/audio/audio_interface.pyx":647 + /* "mpfmc/core/audio/audio_interface.pyx":648 * * # Update audio callback data with new track * self.audio_callback_data.track_count = len(self.tracks) # <<<<<<<<<<<<<< @@ -11568,13 +11569,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(__pyx_t_8); if (unlikely(__pyx_t_8 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(0, 647, __pyx_L1_error) + __PYX_ERR(0, 648, __pyx_L1_error) } - __pyx_t_2 = PyList_GET_SIZE(__pyx_t_8); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(0, 647, __pyx_L1_error) + __pyx_t_2 = PyList_GET_SIZE(__pyx_t_8); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(0, 648, __pyx_L1_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __pyx_v_self->audio_callback_data.track_count = __pyx_t_2; - /* "mpfmc/core/audio/audio_interface.pyx":648 + /* "mpfmc/core/audio/audio_interface.pyx":649 * # Update audio callback data with new track * self.audio_callback_data.track_count = len(self.tracks) * self.audio_callback_data.tracks[track_num] = new_track.state # <<<<<<<<<<<<<< @@ -11584,7 +11585,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_10 = __pyx_v_new_track->__pyx_base.state; (__pyx_v_self->audio_callback_data.tracks[__pyx_v_track_num]) = __pyx_t_10; - /* "mpfmc/core/audio/audio_interface.pyx":651 + /* "mpfmc/core/audio/audio_interface.pyx":652 * * # Allow audio callback function to be called again * SDL_UnlockAudio() # <<<<<<<<<<<<<< @@ -11593,16 +11594,16 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ SDL_UnlockAudio(); - /* "mpfmc/core/audio/audio_interface.pyx":654 + /* "mpfmc/core/audio/audio_interface.pyx":655 * * # Create playlist controller for the track * playlist_controller = PlaylistController(mc, new_track, crossfade_time) # <<<<<<<<<<<<<< * self.playlist_controllers[name] = playlist_controller * */ - __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_PlaylistController); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 654, __pyx_L1_error) + __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_PlaylistController); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 655, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); - __pyx_t_5 = PyFloat_FromDouble(__pyx_v_crossfade_time); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 654, __pyx_L1_error) + __pyx_t_5 = PyFloat_FromDouble(__pyx_v_crossfade_time); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 655, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_1 = NULL; __pyx_t_7 = 0; @@ -11619,7 +11620,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_1, __pyx_v_mc, ((PyObject *)__pyx_v_new_track), __pyx_t_5}; - __pyx_t_8 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 654, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 655, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; @@ -11628,14 +11629,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_1, __pyx_v_mc, ((PyObject *)__pyx_v_new_track), __pyx_t_5}; - __pyx_t_8 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 654, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_7, 3+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 655, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } else #endif { - __pyx_t_4 = PyTuple_New(3+__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 654, __pyx_L1_error) + __pyx_t_4 = PyTuple_New(3+__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 655, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); if (__pyx_t_1) { __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_1); __pyx_t_1 = NULL; @@ -11649,7 +11650,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_4, 2+__pyx_t_7, __pyx_t_5); __pyx_t_5 = 0; - __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_4, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 654, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_4, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 655, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } @@ -11657,7 +11658,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_v_playlist_controller = __pyx_t_8; __pyx_t_8 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":655 + /* "mpfmc/core/audio/audio_interface.pyx":656 * # Create playlist controller for the track * playlist_controller = PlaylistController(mc, new_track, crossfade_time) * self.playlist_controllers[name] = playlist_controller # <<<<<<<<<<<<<< @@ -11666,18 +11667,18 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_v_self->playlist_controllers == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(0, 655, __pyx_L1_error) + __PYX_ERR(0, 656, __pyx_L1_error) } - if (unlikely(PyDict_SetItem(__pyx_v_self->playlist_controllers, __pyx_v_name, __pyx_v_playlist_controller) < 0)) __PYX_ERR(0, 655, __pyx_L1_error) + if (unlikely(PyDict_SetItem(__pyx_v_self->playlist_controllers, __pyx_v_name, __pyx_v_playlist_controller) < 0)) __PYX_ERR(0, 656, __pyx_L1_error) - /* "mpfmc/core/audio/audio_interface.pyx":657 + /* "mpfmc/core/audio/audio_interface.pyx":658 * self.playlist_controllers[name] = playlist_controller * * self.log.debug("The '%s' playlist track and controller have successfully been created.", name) # <<<<<<<<<<<<<< * * return new_track */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_debug); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 657, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->log, __pyx_n_s_debug); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 658, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = NULL; __pyx_t_7 = 0; @@ -11694,7 +11695,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_kp_u_The_s_playlist_track_and_control, __pyx_v_name}; - __pyx_t_8 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 657, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 658, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_8); } else @@ -11702,13 +11703,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_kp_u_The_s_playlist_track_and_control, __pyx_v_name}; - __pyx_t_8 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 657, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 658, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_8); } else #endif { - __pyx_t_5 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 657, __pyx_L1_error) + __pyx_t_5 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 658, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_4); __pyx_t_4 = NULL; @@ -11719,14 +11720,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(__pyx_v_name); __Pyx_GIVEREF(__pyx_v_name); PyTuple_SET_ITEM(__pyx_t_5, 1+__pyx_t_7, __pyx_v_name); - __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_5, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 657, __pyx_L1_error) + __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_5, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 658, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":659 + /* "mpfmc/core/audio/audio_interface.pyx":660 * self.log.debug("The '%s' playlist track and controller have successfully been created.", name) * * return new_track # <<<<<<<<<<<<<< @@ -11738,7 +11739,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_r = ((PyObject *)__pyx_v_new_track); goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":603 + /* "mpfmc/core/audio/audio_interface.pyx":604 * return new_track * * def create_playlist_track(self, object mc, str name not None, float crossfade_time=0.0, float volume=1.0): # <<<<<<<<<<<<<< @@ -11765,7 +11766,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":661 +/* "mpfmc/core/audio/audio_interface.pyx":662 * return new_track * * def get_playlist_controller_count(self): # <<<<<<<<<<<<<< @@ -11797,7 +11798,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("get_playlist_controller_count", 0); - /* "mpfmc/core/audio/audio_interface.pyx":663 + /* "mpfmc/core/audio/audio_interface.pyx":664 * def get_playlist_controller_count(self): * """Returns the number of playlist controllers that have been created.""" * return len(self.playlist_controllers) # <<<<<<<<<<<<<< @@ -11809,17 +11810,17 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(__pyx_t_1); if (unlikely(__pyx_t_1 == Py_None)) { PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()"); - __PYX_ERR(0, 663, __pyx_L1_error) + __PYX_ERR(0, 664, __pyx_L1_error) } - __pyx_t_2 = PyDict_Size(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(0, 663, __pyx_L1_error) + __pyx_t_2 = PyDict_Size(__pyx_t_1); if (unlikely(__pyx_t_2 == ((Py_ssize_t)-1))) __PYX_ERR(0, 664, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = PyInt_FromSsize_t(__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 663, __pyx_L1_error) + __pyx_t_1 = PyInt_FromSsize_t(__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 664, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":661 + /* "mpfmc/core/audio/audio_interface.pyx":662 * return new_track * * def get_playlist_controller_count(self): # <<<<<<<<<<<<<< @@ -11838,7 +11839,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":665 +/* "mpfmc/core/audio/audio_interface.pyx":666 * return len(self.playlist_controllers) * * def get_playlist_controller_names(self): # <<<<<<<<<<<<<< @@ -11876,7 +11877,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("get_playlist_controller_names", 0); - /* "mpfmc/core/audio/audio_interface.pyx":667 + /* "mpfmc/core/audio/audio_interface.pyx":668 * def get_playlist_controller_names(self): * """Return the list of names of the playlist controllers that have been created.""" * return [controller for controller in self.playlist_controllers.keys()] # <<<<<<<<<<<<<< @@ -11885,14 +11886,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ __Pyx_XDECREF(__pyx_r); { /* enter inner scope */ - __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 667, __pyx_L5_error) + __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 668, __pyx_L5_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_3 = 0; if (unlikely(__pyx_v_self->playlist_controllers == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%.30s'", "keys"); - __PYX_ERR(0, 667, __pyx_L5_error) + __PYX_ERR(0, 668, __pyx_L5_error) } - __pyx_t_6 = __Pyx_dict_iterator(__pyx_v_self->playlist_controllers, 1, __pyx_n_s_keys, (&__pyx_t_4), (&__pyx_t_5)); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 667, __pyx_L5_error) + __pyx_t_6 = __Pyx_dict_iterator(__pyx_v_self->playlist_controllers, 1, __pyx_n_s_keys, (&__pyx_t_4), (&__pyx_t_5)); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 668, __pyx_L5_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = __pyx_t_6; @@ -11900,11 +11901,11 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface while (1) { __pyx_t_7 = __Pyx_dict_iter_next(__pyx_t_2, __pyx_t_4, &__pyx_t_3, &__pyx_t_6, NULL, NULL, __pyx_t_5); if (unlikely(__pyx_t_7 == 0)) break; - if (unlikely(__pyx_t_7 == -1)) __PYX_ERR(0, 667, __pyx_L5_error) + if (unlikely(__pyx_t_7 == -1)) __PYX_ERR(0, 668, __pyx_L5_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_XDECREF_SET(__pyx_8genexpr7__pyx_v_controller, __pyx_t_6); __pyx_t_6 = 0; - if (unlikely(__Pyx_ListComp_Append(__pyx_t_1, (PyObject*)__pyx_8genexpr7__pyx_v_controller))) __PYX_ERR(0, 667, __pyx_L5_error) + if (unlikely(__Pyx_ListComp_Append(__pyx_t_1, (PyObject*)__pyx_8genexpr7__pyx_v_controller))) __PYX_ERR(0, 668, __pyx_L5_error) } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_8genexpr7__pyx_v_controller); __pyx_8genexpr7__pyx_v_controller = 0; @@ -11918,7 +11919,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":665 + /* "mpfmc/core/audio/audio_interface.pyx":666 * return len(self.playlist_controllers) * * def get_playlist_controller_names(self): # <<<<<<<<<<<<<< @@ -11940,7 +11941,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":669 +/* "mpfmc/core/audio/audio_interface.pyx":670 * return [controller for controller in self.playlist_controllers.keys()] * * def get_playlist_controller(self, str controller_name): # <<<<<<<<<<<<<< @@ -11958,7 +11959,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("get_playlist_controller (wrapper)", 0); - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_controller_name), (&PyUnicode_Type), 1, "controller_name", 1))) __PYX_ERR(0, 669, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_controller_name), (&PyUnicode_Type), 1, "controller_name", 1))) __PYX_ERR(0, 670, __pyx_L1_error) __pyx_r = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_72get_playlist_controller(((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface_AudioInterface *)__pyx_v_self), ((PyObject*)__pyx_v_controller_name)); /* function exit code */ @@ -11985,7 +11986,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("get_playlist_controller", 0); - /* "mpfmc/core/audio/audio_interface.pyx":675 + /* "mpfmc/core/audio/audio_interface.pyx":676 * controller_name: The playlist controller name to retrieve * """ * try: # <<<<<<<<<<<<<< @@ -12001,7 +12002,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { - /* "mpfmc/core/audio/audio_interface.pyx":676 + /* "mpfmc/core/audio/audio_interface.pyx":677 * """ * try: * return self.playlist_controllers[controller_name] # <<<<<<<<<<<<<< @@ -12011,15 +12012,15 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_XDECREF(__pyx_r); if (unlikely(__pyx_v_self->playlist_controllers == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); - __PYX_ERR(0, 676, __pyx_L3_error) + __PYX_ERR(0, 677, __pyx_L3_error) } - __pyx_t_4 = __Pyx_PyDict_GetItem(__pyx_v_self->playlist_controllers, __pyx_v_controller_name); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 676, __pyx_L3_error) + __pyx_t_4 = __Pyx_PyDict_GetItem(__pyx_v_self->playlist_controllers, __pyx_v_controller_name); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 677, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_r = __pyx_t_4; __pyx_t_4 = 0; goto __pyx_L7_try_return; - /* "mpfmc/core/audio/audio_interface.pyx":675 + /* "mpfmc/core/audio/audio_interface.pyx":676 * controller_name: The playlist controller name to retrieve * """ * try: # <<<<<<<<<<<<<< @@ -12030,7 +12031,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_L3_error:; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":677 + /* "mpfmc/core/audio/audio_interface.pyx":678 * try: * return self.playlist_controllers[controller_name] * except KeyError: # <<<<<<<<<<<<<< @@ -12040,12 +12041,12 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_5 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_KeyError); if (__pyx_t_5) { __Pyx_AddTraceback("mpfmc.core.audio.audio_interface.AudioInterface.get_playlist_controller", __pyx_clineno, __pyx_lineno, __pyx_filename); - if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_7) < 0) __PYX_ERR(0, 677, __pyx_L5_except_error) + if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_7) < 0) __PYX_ERR(0, 678, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_7); - /* "mpfmc/core/audio/audio_interface.pyx":678 + /* "mpfmc/core/audio/audio_interface.pyx":679 * return self.playlist_controllers[controller_name] * except KeyError: * return None # <<<<<<<<<<<<<< @@ -12062,7 +12063,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface goto __pyx_L5_except_error; __pyx_L5_except_error:; - /* "mpfmc/core/audio/audio_interface.pyx":675 + /* "mpfmc/core/audio/audio_interface.pyx":676 * controller_name: The playlist controller name to retrieve * """ * try: # <<<<<<<<<<<<<< @@ -12088,7 +12089,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface goto __pyx_L0; } - /* "mpfmc/core/audio/audio_interface.pyx":669 + /* "mpfmc/core/audio/audio_interface.pyx":670 * return [controller for controller in self.playlist_controllers.keys()] * * def get_playlist_controller(self, str controller_name): # <<<<<<<<<<<<<< @@ -12109,7 +12110,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":680 +/* "mpfmc/core/audio/audio_interface.pyx":681 * return None * * def load_sound_file_to_memory(self, str file_name): # <<<<<<<<<<<<<< @@ -12127,7 +12128,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("load_sound_file_to_memory (wrapper)", 0); - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_file_name), (&PyUnicode_Type), 1, "file_name", 1))) __PYX_ERR(0, 680, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_file_name), (&PyUnicode_Type), 1, "file_name", 1))) __PYX_ERR(0, 681, __pyx_L1_error) __pyx_r = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_74load_sound_file_to_memory(((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface_AudioInterface *)__pyx_v_self), ((PyObject*)__pyx_v_file_name)); /* function exit code */ @@ -12149,7 +12150,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("load_sound_file_to_memory", 0); - /* "mpfmc/core/audio/audio_interface.pyx":691 + /* "mpfmc/core/audio/audio_interface.pyx":692 * data in memory. An exception is thrown if the sound is unable to be loaded. * """ * return SoundMemoryFile(file_name, pycapsule.PyCapsule_New(&self.audio_callback_data, NULL, NULL)) # <<<<<<<<<<<<<< @@ -12157,9 +12158,9 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * def load_sound_file_for_streaming(self, str file_name): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyCapsule_New((&__pyx_v_self->audio_callback_data), NULL, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 691, __pyx_L1_error) + __pyx_t_1 = PyCapsule_New((&__pyx_v_self->audio_callback_data), NULL, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 692, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 691, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 692, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v_file_name); __Pyx_GIVEREF(__pyx_v_file_name); @@ -12167,14 +12168,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_10sound_file_SoundMemoryFile), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 691, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_10sound_file_SoundMemoryFile), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 692, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":680 + /* "mpfmc/core/audio/audio_interface.pyx":681 * return None * * def load_sound_file_to_memory(self, str file_name): # <<<<<<<<<<<<<< @@ -12194,7 +12195,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":693 +/* "mpfmc/core/audio/audio_interface.pyx":694 * return SoundMemoryFile(file_name, pycapsule.PyCapsule_New(&self.audio_callback_data, NULL, NULL)) * * def load_sound_file_for_streaming(self, str file_name): # <<<<<<<<<<<<<< @@ -12212,7 +12213,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("load_sound_file_for_streaming (wrapper)", 0); - if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_file_name), (&PyUnicode_Type), 1, "file_name", 1))) __PYX_ERR(0, 693, __pyx_L1_error) + if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_file_name), (&PyUnicode_Type), 1, "file_name", 1))) __PYX_ERR(0, 694, __pyx_L1_error) __pyx_r = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_76load_sound_file_for_streaming(((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface_AudioInterface *)__pyx_v_self), ((PyObject*)__pyx_v_file_name)); /* function exit code */ @@ -12234,7 +12235,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("load_sound_file_for_streaming", 0); - /* "mpfmc/core/audio/audio_interface.pyx":704 + /* "mpfmc/core/audio/audio_interface.pyx":705 * data in memory. An exception is thrown if the sound is unable to be loaded. * """ * return SoundStreamingFile(file_name, pycapsule.PyCapsule_New(&self.audio_callback_data, NULL, NULL)) # <<<<<<<<<<<<<< @@ -12242,9 +12243,9 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface * def unload_sound_file(self, container not None): */ __Pyx_XDECREF(__pyx_r); - __pyx_t_1 = PyCapsule_New((&__pyx_v_self->audio_callback_data), NULL, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 704, __pyx_L1_error) + __pyx_t_1 = PyCapsule_New((&__pyx_v_self->audio_callback_data), NULL, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 705, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 704, __pyx_L1_error) + __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 705, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_v_file_name); __Pyx_GIVEREF(__pyx_v_file_name); @@ -12252,14 +12253,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_1); __pyx_t_1 = 0; - __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_10sound_file_SoundStreamingFile), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 704, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_10sound_file_SoundStreamingFile), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 705, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":693 + /* "mpfmc/core/audio/audio_interface.pyx":694 * return SoundMemoryFile(file_name, pycapsule.PyCapsule_New(&self.audio_callback_data, NULL, NULL)) * * def load_sound_file_for_streaming(self, str file_name): # <<<<<<<<<<<<<< @@ -12279,7 +12280,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":706 +/* "mpfmc/core/audio/audio_interface.pyx":707 * return SoundStreamingFile(file_name, pycapsule.PyCapsule_New(&self.audio_callback_data, NULL, NULL)) * * def unload_sound_file(self, container not None): # <<<<<<<<<<<<<< @@ -12298,7 +12299,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("unload_sound_file (wrapper)", 0); if (unlikely(((PyObject *)__pyx_v_container) == Py_None)) { - PyErr_Format(PyExc_TypeError, "Argument '%.200s' must not be None", "container"); __PYX_ERR(0, 706, __pyx_L1_error) + PyErr_Format(PyExc_TypeError, "Argument '%.200s' must not be None", "container"); __PYX_ERR(0, 707, __pyx_L1_error) } __pyx_r = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_78unload_sound_file(((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface_AudioInterface *)__pyx_v_self), ((PyObject *)__pyx_v_container)); @@ -12324,7 +12325,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("unload_sound_file", 0); - /* "mpfmc/core/audio/audio_interface.pyx":713 + /* "mpfmc/core/audio/audio_interface.pyx":714 * container: A SoundFile object * """ * if not isinstance(container, SoundFile): # <<<<<<<<<<<<<< @@ -12335,7 +12336,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_2 = ((!(__pyx_t_1 != 0)) != 0); if (__pyx_t_2) { - /* "mpfmc/core/audio/audio_interface.pyx":714 + /* "mpfmc/core/audio/audio_interface.pyx":715 * """ * if not isinstance(container, SoundFile): * return # <<<<<<<<<<<<<< @@ -12346,7 +12347,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":713 + /* "mpfmc/core/audio/audio_interface.pyx":714 * container: A SoundFile object * """ * if not isinstance(container, SoundFile): # <<<<<<<<<<<<<< @@ -12355,14 +12356,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":716 + /* "mpfmc/core/audio/audio_interface.pyx":717 * return * * container.unload() # <<<<<<<<<<<<<< * * def stop_all_sounds(self, float fade_out_seconds = 0.0): */ - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_container, __pyx_n_s_unload); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 716, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_container, __pyx_n_s_unload); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 717, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { @@ -12376,12 +12377,12 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 716, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 717, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":706 + /* "mpfmc/core/audio/audio_interface.pyx":707 * return SoundStreamingFile(file_name, pycapsule.PyCapsule_New(&self.audio_callback_data, NULL, NULL)) * * def unload_sound_file(self, container not None): # <<<<<<<<<<<<<< @@ -12404,7 +12405,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":718 +/* "mpfmc/core/audio/audio_interface.pyx":719 * container.unload() * * def stop_all_sounds(self, float fade_out_seconds = 0.0): # <<<<<<<<<<<<<< @@ -12444,7 +12445,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "stop_all_sounds") < 0)) __PYX_ERR(0, 718, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "stop_all_sounds") < 0)) __PYX_ERR(0, 719, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -12455,14 +12456,14 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } } if (values[0]) { - __pyx_v_fade_out_seconds = __pyx_PyFloat_AsFloat(values[0]); if (unlikely((__pyx_v_fade_out_seconds == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 718, __pyx_L3_error) + __pyx_v_fade_out_seconds = __pyx_PyFloat_AsFloat(values[0]); if (unlikely((__pyx_v_fade_out_seconds == (float)-1) && PyErr_Occurred())) __PYX_ERR(0, 719, __pyx_L3_error) } else { __pyx_v_fade_out_seconds = ((float)0.0); } } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("stop_all_sounds", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 718, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("stop_all_sounds", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 719, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("mpfmc.core.audio.audio_interface.AudioInterface.stop_all_sounds", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); @@ -12490,7 +12491,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("stop_all_sounds", 0); - /* "mpfmc/core/audio/audio_interface.pyx":720 + /* "mpfmc/core/audio/audio_interface.pyx":721 * def stop_all_sounds(self, float fade_out_seconds = 0.0): * """Stops all playing and pending sounds in all tracks""" * for track in self.tracks: # <<<<<<<<<<<<<< @@ -12499,30 +12500,30 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_v_self->tracks == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(0, 720, __pyx_L1_error) + __PYX_ERR(0, 721, __pyx_L1_error) } __pyx_t_1 = __pyx_v_self->tracks; __Pyx_INCREF(__pyx_t_1); __pyx_t_2 = 0; for (;;) { if (__pyx_t_2 >= PyList_GET_SIZE(__pyx_t_1)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_3 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 720, __pyx_L1_error) + __pyx_t_3 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 721, __pyx_L1_error) #else - __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 720, __pyx_L1_error) + __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 721, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); #endif __Pyx_XDECREF_SET(__pyx_v_track, __pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":721 + /* "mpfmc/core/audio/audio_interface.pyx":722 * """Stops all playing and pending sounds in all tracks""" * for track in self.tracks: * track.stop_all_sounds(fade_out_seconds) # <<<<<<<<<<<<<< * * def stop_sound_instance(self, sound_instance not None, fade_out=None): */ - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_stop_all_sounds); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 721, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_stop_all_sounds); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 722, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); - __pyx_t_5 = PyFloat_FromDouble(__pyx_v_fade_out_seconds); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 721, __pyx_L1_error) + __pyx_t_5 = PyFloat_FromDouble(__pyx_v_fade_out_seconds); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 722, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_6 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { @@ -12537,12 +12538,12 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 721, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 722, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":720 + /* "mpfmc/core/audio/audio_interface.pyx":721 * def stop_all_sounds(self, float fade_out_seconds = 0.0): * """Stops all playing and pending sounds in all tracks""" * for track in self.tracks: # <<<<<<<<<<<<<< @@ -12552,7 +12553,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":718 + /* "mpfmc/core/audio/audio_interface.pyx":719 * container.unload() * * def stop_all_sounds(self, float fade_out_seconds = 0.0): # <<<<<<<<<<<<<< @@ -12578,7 +12579,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":723 +/* "mpfmc/core/audio/audio_interface.pyx":724 * track.stop_all_sounds(fade_out_seconds) * * def stop_sound_instance(self, sound_instance not None, fade_out=None): # <<<<<<<<<<<<<< @@ -12626,7 +12627,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "stop_sound_instance") < 0)) __PYX_ERR(0, 723, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "stop_sound_instance") < 0)) __PYX_ERR(0, 724, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -12642,14 +12643,14 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("stop_sound_instance", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 723, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("stop_sound_instance", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 724, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("mpfmc.core.audio.audio_interface.AudioInterface.stop_sound_instance", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; if (unlikely(((PyObject *)__pyx_v_sound_instance) == Py_None)) { - PyErr_Format(PyExc_TypeError, "Argument '%.200s' must not be None", "sound_instance"); __PYX_ERR(0, 723, __pyx_L1_error) + PyErr_Format(PyExc_TypeError, "Argument '%.200s' must not be None", "sound_instance"); __PYX_ERR(0, 724, __pyx_L1_error) } __pyx_r = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_82stop_sound_instance(((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface_AudioInterface *)__pyx_v_self), __pyx_v_sound_instance, __pyx_v_fade_out); @@ -12680,7 +12681,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("stop_sound_instance", 0); - /* "mpfmc/core/audio/audio_interface.pyx":725 + /* "mpfmc/core/audio/audio_interface.pyx":726 * def stop_sound_instance(self, sound_instance not None, fade_out=None): * """Stops the specified sound instance""" * for track in self.tracks: # <<<<<<<<<<<<<< @@ -12689,39 +12690,39 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_v_self->tracks == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(0, 725, __pyx_L1_error) + __PYX_ERR(0, 726, __pyx_L1_error) } __pyx_t_1 = __pyx_v_self->tracks; __Pyx_INCREF(__pyx_t_1); __pyx_t_2 = 0; for (;;) { if (__pyx_t_2 >= PyList_GET_SIZE(__pyx_t_1)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_3 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 725, __pyx_L1_error) + __pyx_t_3 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 726, __pyx_L1_error) #else - __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 725, __pyx_L1_error) + __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 726, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); #endif __Pyx_XDECREF_SET(__pyx_v_track, __pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":726 + /* "mpfmc/core/audio/audio_interface.pyx":727 * """Stops the specified sound instance""" * for track in self.tracks: * if hasattr(track, "stop_sound_instance"): # <<<<<<<<<<<<<< * track.stop_sound_instance(sound_instance, fade_out) * */ - __pyx_t_4 = __Pyx_HasAttr(__pyx_v_track, __pyx_n_u_stop_sound_instance); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(0, 726, __pyx_L1_error) + __pyx_t_4 = __Pyx_HasAttr(__pyx_v_track, __pyx_n_u_stop_sound_instance); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(0, 727, __pyx_L1_error) __pyx_t_5 = (__pyx_t_4 != 0); if (__pyx_t_5) { - /* "mpfmc/core/audio/audio_interface.pyx":727 + /* "mpfmc/core/audio/audio_interface.pyx":728 * for track in self.tracks: * if hasattr(track, "stop_sound_instance"): * track.stop_sound_instance(sound_instance, fade_out) # <<<<<<<<<<<<<< * * def stop_sound(self, sound not None, fade_out=None): */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_stop_sound_instance); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 727, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_stop_sound_instance); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 728, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; __pyx_t_8 = 0; @@ -12738,7 +12739,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_v_sound_instance, __pyx_v_fade_out}; - __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 727, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 728, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_3); } else @@ -12746,13 +12747,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_v_sound_instance, __pyx_v_fade_out}; - __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 727, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 728, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_3); } else #endif { - __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 727, __pyx_L1_error) + __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 728, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_7); __pyx_t_7 = NULL; @@ -12763,14 +12764,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(__pyx_v_fade_out); __Pyx_GIVEREF(__pyx_v_fade_out); PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_8, __pyx_v_fade_out); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 727, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 728, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":726 + /* "mpfmc/core/audio/audio_interface.pyx":727 * """Stops the specified sound instance""" * for track in self.tracks: * if hasattr(track, "stop_sound_instance"): # <<<<<<<<<<<<<< @@ -12779,7 +12780,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":725 + /* "mpfmc/core/audio/audio_interface.pyx":726 * def stop_sound_instance(self, sound_instance not None, fade_out=None): * """Stops the specified sound instance""" * for track in self.tracks: # <<<<<<<<<<<<<< @@ -12789,7 +12790,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":723 + /* "mpfmc/core/audio/audio_interface.pyx":724 * track.stop_all_sounds(fade_out_seconds) * * def stop_sound_instance(self, sound_instance not None, fade_out=None): # <<<<<<<<<<<<<< @@ -12815,7 +12816,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":729 +/* "mpfmc/core/audio/audio_interface.pyx":730 * track.stop_sound_instance(sound_instance, fade_out) * * def stop_sound(self, sound not None, fade_out=None): # <<<<<<<<<<<<<< @@ -12863,7 +12864,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } } if (unlikely(kw_args > 0)) { - if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "stop_sound") < 0)) __PYX_ERR(0, 729, __pyx_L3_error) + if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "stop_sound") < 0)) __PYX_ERR(0, 730, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { @@ -12879,14 +12880,14 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; - __Pyx_RaiseArgtupleInvalid("stop_sound", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 729, __pyx_L3_error) + __Pyx_RaiseArgtupleInvalid("stop_sound", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 730, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("mpfmc.core.audio.audio_interface.AudioInterface.stop_sound", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; if (unlikely(((PyObject *)__pyx_v_sound) == Py_None)) { - PyErr_Format(PyExc_TypeError, "Argument '%.200s' must not be None", "sound"); __PYX_ERR(0, 729, __pyx_L1_error) + PyErr_Format(PyExc_TypeError, "Argument '%.200s' must not be None", "sound"); __PYX_ERR(0, 730, __pyx_L1_error) } __pyx_r = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_84stop_sound(((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface_AudioInterface *)__pyx_v_self), __pyx_v_sound, __pyx_v_fade_out); @@ -12917,7 +12918,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("stop_sound", 0); - /* "mpfmc/core/audio/audio_interface.pyx":731 + /* "mpfmc/core/audio/audio_interface.pyx":732 * def stop_sound(self, sound not None, fade_out=None): * """Stops all instances of the specified sound on all tracks""" * for track in self.tracks: # <<<<<<<<<<<<<< @@ -12926,39 +12927,39 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_v_self->tracks == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(0, 731, __pyx_L1_error) + __PYX_ERR(0, 732, __pyx_L1_error) } __pyx_t_1 = __pyx_v_self->tracks; __Pyx_INCREF(__pyx_t_1); __pyx_t_2 = 0; for (;;) { if (__pyx_t_2 >= PyList_GET_SIZE(__pyx_t_1)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_3 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 731, __pyx_L1_error) + __pyx_t_3 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 732, __pyx_L1_error) #else - __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 731, __pyx_L1_error) + __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 732, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); #endif __Pyx_XDECREF_SET(__pyx_v_track, __pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":732 + /* "mpfmc/core/audio/audio_interface.pyx":733 * """Stops all instances of the specified sound on all tracks""" * for track in self.tracks: * if hasattr(track, "stop_sound"): # <<<<<<<<<<<<<< * track.stop_sound(sound, fade_out) * */ - __pyx_t_4 = __Pyx_HasAttr(__pyx_v_track, __pyx_n_u_stop_sound); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(0, 732, __pyx_L1_error) + __pyx_t_4 = __Pyx_HasAttr(__pyx_v_track, __pyx_n_u_stop_sound); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(0, 733, __pyx_L1_error) __pyx_t_5 = (__pyx_t_4 != 0); if (__pyx_t_5) { - /* "mpfmc/core/audio/audio_interface.pyx":733 + /* "mpfmc/core/audio/audio_interface.pyx":734 * for track in self.tracks: * if hasattr(track, "stop_sound"): * track.stop_sound(sound, fade_out) # <<<<<<<<<<<<<< * * def stop_sound(self, sound not None): */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_stop_sound); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 733, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_stop_sound); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 734, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; __pyx_t_8 = 0; @@ -12975,7 +12976,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_v_sound, __pyx_v_fade_out}; - __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 733, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 734, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_3); } else @@ -12983,13 +12984,13 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_v_sound, __pyx_v_fade_out}; - __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 733, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 734, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_3); } else #endif { - __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 733, __pyx_L1_error) + __pyx_t_9 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 734, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_7); __pyx_t_7 = NULL; @@ -13000,14 +13001,14 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_INCREF(__pyx_v_fade_out); __Pyx_GIVEREF(__pyx_v_fade_out); PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_8, __pyx_v_fade_out); - __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 733, __pyx_L1_error) + __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 734, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":732 + /* "mpfmc/core/audio/audio_interface.pyx":733 * """Stops all instances of the specified sound on all tracks""" * for track in self.tracks: * if hasattr(track, "stop_sound"): # <<<<<<<<<<<<<< @@ -13016,7 +13017,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":731 + /* "mpfmc/core/audio/audio_interface.pyx":732 * def stop_sound(self, sound not None, fade_out=None): * """Stops all instances of the specified sound on all tracks""" * for track in self.tracks: # <<<<<<<<<<<<<< @@ -13026,7 +13027,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":729 + /* "mpfmc/core/audio/audio_interface.pyx":730 * track.stop_sound_instance(sound_instance, fade_out) * * def stop_sound(self, sound not None, fade_out=None): # <<<<<<<<<<<<<< @@ -13052,7 +13053,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":735 +/* "mpfmc/core/audio/audio_interface.pyx":736 * track.stop_sound(sound, fade_out) * * def stop_sound(self, sound not None): # <<<<<<<<<<<<<< @@ -13071,7 +13072,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("stop_sound (wrapper)", 0); if (unlikely(((PyObject *)__pyx_v_sound) == Py_None)) { - PyErr_Format(PyExc_TypeError, "Argument '%.200s' must not be None", "sound"); __PYX_ERR(0, 735, __pyx_L1_error) + PyErr_Format(PyExc_TypeError, "Argument '%.200s' must not be None", "sound"); __PYX_ERR(0, 736, __pyx_L1_error) } __pyx_r = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_86stop_sound(((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface_AudioInterface *)__pyx_v_self), ((PyObject *)__pyx_v_sound)); @@ -13100,7 +13101,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("stop_sound", 0); - /* "mpfmc/core/audio/audio_interface.pyx":737 + /* "mpfmc/core/audio/audio_interface.pyx":738 * def stop_sound(self, sound not None): * """Stops all instances of the specified sound from continuing to loop on all tracks""" * for track in self.tracks: # <<<<<<<<<<<<<< @@ -13109,39 +13110,39 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_v_self->tracks == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(0, 737, __pyx_L1_error) + __PYX_ERR(0, 738, __pyx_L1_error) } __pyx_t_1 = __pyx_v_self->tracks; __Pyx_INCREF(__pyx_t_1); __pyx_t_2 = 0; for (;;) { if (__pyx_t_2 >= PyList_GET_SIZE(__pyx_t_1)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_3 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 737, __pyx_L1_error) + __pyx_t_3 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 738, __pyx_L1_error) #else - __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 737, __pyx_L1_error) + __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 738, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); #endif __Pyx_XDECREF_SET(__pyx_v_track, __pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":738 + /* "mpfmc/core/audio/audio_interface.pyx":739 * """Stops all instances of the specified sound from continuing to loop on all tracks""" * for track in self.tracks: * if hasattr(track, "stop_sound_looping"): # <<<<<<<<<<<<<< * track.stop_sound_looping(sound) * */ - __pyx_t_4 = __Pyx_HasAttr(__pyx_v_track, __pyx_n_u_stop_sound_looping); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(0, 738, __pyx_L1_error) + __pyx_t_4 = __Pyx_HasAttr(__pyx_v_track, __pyx_n_u_stop_sound_looping); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(0, 739, __pyx_L1_error) __pyx_t_5 = (__pyx_t_4 != 0); if (__pyx_t_5) { - /* "mpfmc/core/audio/audio_interface.pyx":739 + /* "mpfmc/core/audio/audio_interface.pyx":740 * for track in self.tracks: * if hasattr(track, "stop_sound_looping"): * track.stop_sound_looping(sound) # <<<<<<<<<<<<<< * * def stop_sound_instance_looping(self, sound_instance not None): */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_stop_sound_looping); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 739, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_stop_sound_looping); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 740, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -13155,12 +13156,12 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_3 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_7, __pyx_v_sound) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_sound); __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 739, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 740, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":738 + /* "mpfmc/core/audio/audio_interface.pyx":739 * """Stops all instances of the specified sound from continuing to loop on all tracks""" * for track in self.tracks: * if hasattr(track, "stop_sound_looping"): # <<<<<<<<<<<<<< @@ -13169,7 +13170,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":737 + /* "mpfmc/core/audio/audio_interface.pyx":738 * def stop_sound(self, sound not None): * """Stops all instances of the specified sound from continuing to loop on all tracks""" * for track in self.tracks: # <<<<<<<<<<<<<< @@ -13179,7 +13180,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":735 + /* "mpfmc/core/audio/audio_interface.pyx":736 * track.stop_sound(sound, fade_out) * * def stop_sound(self, sound not None): # <<<<<<<<<<<<<< @@ -13204,7 +13205,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":741 +/* "mpfmc/core/audio/audio_interface.pyx":742 * track.stop_sound_looping(sound) * * def stop_sound_instance_looping(self, sound_instance not None): # <<<<<<<<<<<<<< @@ -13223,7 +13224,7 @@ static PyObject *__pyx_pw_5mpfmc_4core_5audio_15audio_interface_14AudioInterface __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("stop_sound_instance_looping (wrapper)", 0); if (unlikely(((PyObject *)__pyx_v_sound_instance) == Py_None)) { - PyErr_Format(PyExc_TypeError, "Argument '%.200s' must not be None", "sound_instance"); __PYX_ERR(0, 741, __pyx_L1_error) + PyErr_Format(PyExc_TypeError, "Argument '%.200s' must not be None", "sound_instance"); __PYX_ERR(0, 742, __pyx_L1_error) } __pyx_r = __pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_88stop_sound_instance_looping(((struct __pyx_obj_5mpfmc_4core_5audio_15audio_interface_AudioInterface *)__pyx_v_self), ((PyObject *)__pyx_v_sound_instance)); @@ -13252,7 +13253,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("stop_sound_instance_looping", 0); - /* "mpfmc/core/audio/audio_interface.pyx":743 + /* "mpfmc/core/audio/audio_interface.pyx":744 * def stop_sound_instance_looping(self, sound_instance not None): * """Stops the specified sound instance from continuing to loop.""" * for track in self.tracks: # <<<<<<<<<<<<<< @@ -13261,39 +13262,39 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_v_self->tracks == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(0, 743, __pyx_L1_error) + __PYX_ERR(0, 744, __pyx_L1_error) } __pyx_t_1 = __pyx_v_self->tracks; __Pyx_INCREF(__pyx_t_1); __pyx_t_2 = 0; for (;;) { if (__pyx_t_2 >= PyList_GET_SIZE(__pyx_t_1)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_3 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 743, __pyx_L1_error) + __pyx_t_3 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 744, __pyx_L1_error) #else - __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 743, __pyx_L1_error) + __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 744, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); #endif __Pyx_XDECREF_SET(__pyx_v_track, __pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":744 + /* "mpfmc/core/audio/audio_interface.pyx":745 * """Stops the specified sound instance from continuing to loop.""" * for track in self.tracks: * if hasattr(track, "stop_sound_instance_looping"): # <<<<<<<<<<<<<< * track.stop_sound_instance_looping(sound_instance) * */ - __pyx_t_4 = __Pyx_HasAttr(__pyx_v_track, __pyx_n_u_stop_sound_instance_looping); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(0, 744, __pyx_L1_error) + __pyx_t_4 = __Pyx_HasAttr(__pyx_v_track, __pyx_n_u_stop_sound_instance_looping); if (unlikely(__pyx_t_4 == ((int)-1))) __PYX_ERR(0, 745, __pyx_L1_error) __pyx_t_5 = (__pyx_t_4 != 0); if (__pyx_t_5) { - /* "mpfmc/core/audio/audio_interface.pyx":745 + /* "mpfmc/core/audio/audio_interface.pyx":746 * for track in self.tracks: * if hasattr(track, "stop_sound_instance_looping"): * track.stop_sound_instance_looping(sound_instance) # <<<<<<<<<<<<<< * * def clear_context(self, context): */ - __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_stop_sound_instance_looping); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 745, __pyx_L1_error) + __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_stop_sound_instance_looping); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 746, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { @@ -13307,12 +13308,12 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_3 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_6, __pyx_t_7, __pyx_v_sound_instance) : __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_sound_instance); __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 745, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 746, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":744 + /* "mpfmc/core/audio/audio_interface.pyx":745 * """Stops the specified sound instance from continuing to loop.""" * for track in self.tracks: * if hasattr(track, "stop_sound_instance_looping"): # <<<<<<<<<<<<<< @@ -13321,7 +13322,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ } - /* "mpfmc/core/audio/audio_interface.pyx":743 + /* "mpfmc/core/audio/audio_interface.pyx":744 * def stop_sound_instance_looping(self, sound_instance not None): * """Stops the specified sound instance from continuing to loop.""" * for track in self.tracks: # <<<<<<<<<<<<<< @@ -13331,7 +13332,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":741 + /* "mpfmc/core/audio/audio_interface.pyx":742 * track.stop_sound_looping(sound) * * def stop_sound_instance_looping(self, sound_instance not None): # <<<<<<<<<<<<<< @@ -13356,7 +13357,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":747 +/* "mpfmc/core/audio/audio_interface.pyx":748 * track.stop_sound_instance_looping(sound_instance) * * def clear_context(self, context): # <<<<<<<<<<<<<< @@ -13392,7 +13393,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("clear_context", 0); - /* "mpfmc/core/audio/audio_interface.pyx":749 + /* "mpfmc/core/audio/audio_interface.pyx":750 * def clear_context(self, context): * """Clears the context in all tracks""" * for track in self.tracks: # <<<<<<<<<<<<<< @@ -13401,28 +13402,28 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_v_self->tracks == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(0, 749, __pyx_L1_error) + __PYX_ERR(0, 750, __pyx_L1_error) } __pyx_t_1 = __pyx_v_self->tracks; __Pyx_INCREF(__pyx_t_1); __pyx_t_2 = 0; for (;;) { if (__pyx_t_2 >= PyList_GET_SIZE(__pyx_t_1)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_3 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 749, __pyx_L1_error) + __pyx_t_3 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 750, __pyx_L1_error) #else - __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 749, __pyx_L1_error) + __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 750, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); #endif __Pyx_XDECREF_SET(__pyx_v_track, __pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":750 + /* "mpfmc/core/audio/audio_interface.pyx":751 * """Clears the context in all tracks""" * for track in self.tracks: * track.clear_context(context) # <<<<<<<<<<<<<< * * def process(self): */ - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_clear_context); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 750, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_clear_context); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 751, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { @@ -13436,12 +13437,12 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_v_context) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_context); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 750, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 751, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":749 + /* "mpfmc/core/audio/audio_interface.pyx":750 * def clear_context(self, context): * """Clears the context in all tracks""" * for track in self.tracks: # <<<<<<<<<<<<<< @@ -13451,7 +13452,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":747 + /* "mpfmc/core/audio/audio_interface.pyx":748 * track.stop_sound_instance_looping(sound_instance) * * def clear_context(self, context): # <<<<<<<<<<<<<< @@ -13476,7 +13477,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":752 +/* "mpfmc/core/audio/audio_interface.pyx":753 * track.clear_context(context) * * def process(self): # <<<<<<<<<<<<<< @@ -13512,7 +13513,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface int __pyx_clineno = 0; __Pyx_RefNannySetupContext("process", 0); - /* "mpfmc/core/audio/audio_interface.pyx":754 + /* "mpfmc/core/audio/audio_interface.pyx":755 * def process(self): * """Process tick function for the audio interface.""" * for track in self.tracks: # <<<<<<<<<<<<<< @@ -13521,28 +13522,28 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface */ if (unlikely(__pyx_v_self->tracks == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); - __PYX_ERR(0, 754, __pyx_L1_error) + __PYX_ERR(0, 755, __pyx_L1_error) } __pyx_t_1 = __pyx_v_self->tracks; __Pyx_INCREF(__pyx_t_1); __pyx_t_2 = 0; for (;;) { if (__pyx_t_2 >= PyList_GET_SIZE(__pyx_t_1)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS - __pyx_t_3 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 754, __pyx_L1_error) + __pyx_t_3 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(0, 755, __pyx_L1_error) #else - __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 754, __pyx_L1_error) + __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 755, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); #endif __Pyx_XDECREF_SET(__pyx_v_track, __pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":755 + /* "mpfmc/core/audio/audio_interface.pyx":756 * """Process tick function for the audio interface.""" * for track in self.tracks: * track.process() # <<<<<<<<<<<<<< * * @staticmethod */ - __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_process); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 755, __pyx_L1_error) + __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_track, __pyx_n_s_process); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 756, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { @@ -13556,12 +13557,12 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5) : __Pyx_PyObject_CallNoArg(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; - if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 755, __pyx_L1_error) + if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 756, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":754 + /* "mpfmc/core/audio/audio_interface.pyx":755 * def process(self): * """Process tick function for the audio interface.""" * for track in self.tracks: # <<<<<<<<<<<<<< @@ -13571,7 +13572,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":752 + /* "mpfmc/core/audio/audio_interface.pyx":753 * track.clear_context(context) * * def process(self): # <<<<<<<<<<<<<< @@ -13596,7 +13597,7 @@ static PyObject *__pyx_pf_5mpfmc_4core_5audio_15audio_interface_14AudioInterface return __pyx_r; } -/* "mpfmc/core/audio/audio_interface.pyx":758 +/* "mpfmc/core/audio/audio_interface.pyx":759 * * @staticmethod * cdef void audio_callback(void* data, Uint8 *output_buffer, int length) nogil: # <<<<<<<<<<<<<< @@ -13618,7 +13619,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio int __pyx_t_6; long __pyx_t_7; - /* "mpfmc/core/audio/audio_interface.pyx":773 + /* "mpfmc/core/audio/audio_interface.pyx":774 * track buffers are maintained in each Track object and are processed during this callback. * """ * cdef Uint32 buffer_length = length # <<<<<<<<<<<<<< @@ -13627,7 +13628,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio */ __pyx_v_buffer_length = ((Uint32)__pyx_v_length); - /* "mpfmc/core/audio/audio_interface.pyx":774 + /* "mpfmc/core/audio/audio_interface.pyx":775 * """ * cdef Uint32 buffer_length = length * cdef AudioCallbackData *callback_data = data # <<<<<<<<<<<<<< @@ -13636,7 +13637,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio */ __pyx_v_callback_data = ((__pyx_t_5mpfmc_4core_5audio_4sdl2_AudioCallbackData *)__pyx_v_data); - /* "mpfmc/core/audio/audio_interface.pyx":777 + /* "mpfmc/core/audio/audio_interface.pyx":778 * cdef TrackState *track * * if callback_data == NULL: # <<<<<<<<<<<<<< @@ -13646,7 +13647,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio __pyx_t_1 = ((__pyx_v_callback_data == NULL) != 0); if (__pyx_t_1) { - /* "mpfmc/core/audio/audio_interface.pyx":778 + /* "mpfmc/core/audio/audio_interface.pyx":779 * * if callback_data == NULL: * return # <<<<<<<<<<<<<< @@ -13655,7 +13656,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio */ goto __pyx_L0; - /* "mpfmc/core/audio/audio_interface.pyx":777 + /* "mpfmc/core/audio/audio_interface.pyx":778 * cdef TrackState *track * * if callback_data == NULL: # <<<<<<<<<<<<<< @@ -13664,7 +13665,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio */ } - /* "mpfmc/core/audio/audio_interface.pyx":781 + /* "mpfmc/core/audio/audio_interface.pyx":782 * * # Initialize master output buffer with silence as it arrives uninitialized * memset(output_buffer, 0, buffer_length) # <<<<<<<<<<<<<< @@ -13673,7 +13674,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio */ (void)(memset(__pyx_v_output_buffer, 0, __pyx_v_buffer_length)); - /* "mpfmc/core/audio/audio_interface.pyx":788 + /* "mpfmc/core/audio/audio_interface.pyx":789 * * # Loop over tracks, initializing the status, track buffer, and track ducking. * for track_num in range(callback_data.track_count): # <<<<<<<<<<<<<< @@ -13685,7 +13686,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) { __pyx_v_track_num = __pyx_t_4; - /* "mpfmc/core/audio/audio_interface.pyx":789 + /* "mpfmc/core/audio/audio_interface.pyx":790 * # Loop over tracks, initializing the status, track buffer, and track ducking. * for track_num in range(callback_data.track_count): * track = callback_data.tracks[track_num] # <<<<<<<<<<<<<< @@ -13694,7 +13695,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio */ __pyx_v_track = ((__pyx_t_5mpfmc_4core_5audio_5track_TrackState *)(__pyx_v_callback_data->tracks[__pyx_v_track_num])); - /* "mpfmc/core/audio/audio_interface.pyx":791 + /* "mpfmc/core/audio/audio_interface.pyx":792 * track = callback_data.tracks[track_num] * * track.active = False # <<<<<<<<<<<<<< @@ -13703,7 +13704,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio */ __pyx_v_track->active = 0; - /* "mpfmc/core/audio/audio_interface.pyx":792 + /* "mpfmc/core/audio/audio_interface.pyx":793 * * track.active = False * memset(track.buffer, 0, buffer_length) # <<<<<<<<<<<<<< @@ -13712,7 +13713,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio */ (void)(memset(__pyx_v_track->buffer, 0, __pyx_v_buffer_length)); - /* "mpfmc/core/audio/audio_interface.pyx":794 + /* "mpfmc/core/audio/audio_interface.pyx":795 * memset(track.buffer, 0, buffer_length) * * track.ducking_is_active = False # <<<<<<<<<<<<<< @@ -13721,7 +13722,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio */ __pyx_v_track->ducking_is_active = 0; - /* "mpfmc/core/audio/audio_interface.pyx":795 + /* "mpfmc/core/audio/audio_interface.pyx":796 * * track.ducking_is_active = False * for control_point in range(CONTROL_POINTS_PER_BUFFER): # <<<<<<<<<<<<<< @@ -13733,7 +13734,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio for (__pyx_t_7 = 0; __pyx_t_7 < __pyx_t_6; __pyx_t_7+=1) { __pyx_v_control_point = __pyx_t_7; - /* "mpfmc/core/audio/audio_interface.pyx":796 + /* "mpfmc/core/audio/audio_interface.pyx":797 * track.ducking_is_active = False * for control_point in range(CONTROL_POINTS_PER_BUFFER): * g_array_set_val_uint8(track.ducking_control_points, control_point, SDL_MIX_MAXVOLUME) # <<<<<<<<<<<<<< @@ -13744,7 +13745,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio } } - /* "mpfmc/core/audio/audio_interface.pyx":799 + /* "mpfmc/core/audio/audio_interface.pyx":800 * * # Loop over tracks, mixing the playing sounds into the track's audio buffer * for track_num in range(callback_data.track_count): # <<<<<<<<<<<<<< @@ -13756,7 +13757,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) { __pyx_v_track_num = __pyx_t_4; - /* "mpfmc/core/audio/audio_interface.pyx":800 + /* "mpfmc/core/audio/audio_interface.pyx":801 * # Loop over tracks, mixing the playing sounds into the track's audio buffer * for track_num in range(callback_data.track_count): * track = callback_data.tracks[track_num] # <<<<<<<<<<<<<< @@ -13765,7 +13766,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio */ __pyx_v_track = ((__pyx_t_5mpfmc_4core_5audio_5track_TrackState *)(__pyx_v_callback_data->tracks[__pyx_v_track_num])); - /* "mpfmc/core/audio/audio_interface.pyx":803 + /* "mpfmc/core/audio/audio_interface.pyx":804 * * # No need to process/mix the track if the track is stopped or paused * if track.status == track_status_stopped or track.status == track_status_paused: # <<<<<<<<<<<<<< @@ -13776,7 +13777,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio case __pyx_e_5mpfmc_4core_5audio_5track_track_status_stopped: case __pyx_e_5mpfmc_4core_5audio_5track_track_status_paused: - /* "mpfmc/core/audio/audio_interface.pyx":804 + /* "mpfmc/core/audio/audio_interface.pyx":805 * # No need to process/mix the track if the track is stopped or paused * if track.status == track_status_stopped or track.status == track_status_paused: * continue # <<<<<<<<<<<<<< @@ -13785,7 +13786,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio */ goto __pyx_L8_continue; - /* "mpfmc/core/audio/audio_interface.pyx":803 + /* "mpfmc/core/audio/audio_interface.pyx":804 * * # No need to process/mix the track if the track is stopped or paused * if track.status == track_status_stopped or track.status == track_status_paused: # <<<<<<<<<<<<<< @@ -13796,7 +13797,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio default: break; } - /* "mpfmc/core/audio/audio_interface.pyx":807 + /* "mpfmc/core/audio/audio_interface.pyx":808 * * # Call the track's mix callback function (generates audio into track buffer) * if track.mix_callback_function != NULL: # <<<<<<<<<<<<<< @@ -13806,7 +13807,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio __pyx_t_1 = ((__pyx_v_track->mix_callback_function != NULL) != 0); if (__pyx_t_1) { - /* "mpfmc/core/audio/audio_interface.pyx":808 + /* "mpfmc/core/audio/audio_interface.pyx":809 * # Call the track's mix callback function (generates audio into track buffer) * if track.mix_callback_function != NULL: * track.mix_callback_function(track, buffer_length, callback_data) # <<<<<<<<<<<<<< @@ -13815,7 +13816,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio */ __pyx_v_track->mix_callback_function(__pyx_v_track, __pyx_v_buffer_length, __pyx_v_callback_data); - /* "mpfmc/core/audio/audio_interface.pyx":807 + /* "mpfmc/core/audio/audio_interface.pyx":808 * * # Call the track's mix callback function (generates audio into track buffer) * if track.mix_callback_function != NULL: # <<<<<<<<<<<<<< @@ -13826,7 +13827,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio __pyx_L8_continue:; } - /* "mpfmc/core/audio/audio_interface.pyx":811 + /* "mpfmc/core/audio/audio_interface.pyx":812 * * # Loop over tracks again, applying ducking and mixing down tracks to the master output buffer * for track_num in range(callback_data.track_count): # <<<<<<<<<<<<<< @@ -13838,7 +13839,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) { __pyx_v_track_num = __pyx_t_4; - /* "mpfmc/core/audio/audio_interface.pyx":812 + /* "mpfmc/core/audio/audio_interface.pyx":813 * # Loop over tracks again, applying ducking and mixing down tracks to the master output buffer * for track_num in range(callback_data.track_count): * track = callback_data.tracks[track_num] # <<<<<<<<<<<<<< @@ -13847,7 +13848,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio */ __pyx_v_track = ((__pyx_t_5mpfmc_4core_5audio_5track_TrackState *)(__pyx_v_callback_data->tracks[__pyx_v_track_num])); - /* "mpfmc/core/audio/audio_interface.pyx":815 + /* "mpfmc/core/audio/audio_interface.pyx":816 * * # Only mix the track to the master output and apply ducking if it is active * if track.active: # <<<<<<<<<<<<<< @@ -13857,7 +13858,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio __pyx_t_1 = (__pyx_v_track->active != 0); if (__pyx_t_1) { - /* "mpfmc/core/audio/audio_interface.pyx":816 + /* "mpfmc/core/audio/audio_interface.pyx":817 * # Only mix the track to the master output and apply ducking if it is active * if track.active: * Track.mix_track_to_output(track, # <<<<<<<<<<<<<< @@ -13866,7 +13867,7 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio */ __pyx_vtabptr_5mpfmc_4core_5audio_5track_Track->mix_track_to_output(__pyx_v_track, __pyx_v_callback_data, __pyx_v_output_buffer, __pyx_v_buffer_length); - /* "mpfmc/core/audio/audio_interface.pyx":815 + /* "mpfmc/core/audio/audio_interface.pyx":816 * * # Only mix the track to the master output and apply ducking if it is active * if track.active: # <<<<<<<<<<<<<< @@ -13876,14 +13877,14 @@ static void __pyx_f_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_audio } } - /* "mpfmc/core/audio/audio_interface.pyx":822 + /* "mpfmc/core/audio/audio_interface.pyx":823 * * # Apply master volume to output buffer * Track.apply_volume(output_buffer, output_buffer, buffer_length, callback_data.master_volume) # <<<<<<<<<<<<<< */ __pyx_vtabptr_5mpfmc_4core_5audio_5track_Track->apply_volume(__pyx_v_output_buffer, __pyx_v_output_buffer, __pyx_v_buffer_length, __pyx_v_callback_data->master_volume); - /* "mpfmc/core/audio/audio_interface.pyx":758 + /* "mpfmc/core/audio/audio_interface.pyx":759 * * @staticmethod * cdef void audio_callback(void* data, Uint8 *output_buffer, int length) nogil: # <<<<<<<<<<<<<< @@ -16385,11 +16386,11 @@ static __Pyx_StringTabEntry __pyx_string_tab[] = { {0, 0, 0, 0, 0, 0, 0} }; static CYTHON_SMALL_CODE int __Pyx_InitCachedBuiltins(void) { - __pyx_builtin_staticmethod = __Pyx_GetBuiltinName(__pyx_n_s_staticmethod); if (!__pyx_builtin_staticmethod) __PYX_ERR(0, 214, __pyx_L1_error) - __pyx_builtin_round = __Pyx_GetBuiltinName(__pyx_n_s_round); if (!__pyx_builtin_round) __PYX_ERR(0, 266, __pyx_L1_error) - __pyx_builtin_IndexError = __Pyx_GetBuiltinName(__pyx_n_s_IndexError); if (!__pyx_builtin_IndexError) __PYX_ERR(0, 473, __pyx_L1_error) - __pyx_builtin_KeyError = __Pyx_GetBuiltinName(__pyx_n_s_KeyError); if (!__pyx_builtin_KeyError) __PYX_ERR(0, 677, __pyx_L1_error) - __pyx_builtin_range = __Pyx_GetBuiltinName(__pyx_n_s_range); if (!__pyx_builtin_range) __PYX_ERR(0, 788, __pyx_L1_error) + __pyx_builtin_staticmethod = __Pyx_GetBuiltinName(__pyx_n_s_staticmethod); if (!__pyx_builtin_staticmethod) __PYX_ERR(0, 215, __pyx_L1_error) + __pyx_builtin_round = __Pyx_GetBuiltinName(__pyx_n_s_round); if (!__pyx_builtin_round) __PYX_ERR(0, 267, __pyx_L1_error) + __pyx_builtin_IndexError = __Pyx_GetBuiltinName(__pyx_n_s_IndexError); if (!__pyx_builtin_IndexError) __PYX_ERR(0, 474, __pyx_L1_error) + __pyx_builtin_KeyError = __Pyx_GetBuiltinName(__pyx_n_s_KeyError); if (!__pyx_builtin_KeyError) __PYX_ERR(0, 678, __pyx_L1_error) + __pyx_builtin_range = __Pyx_GetBuiltinName(__pyx_n_s_range); if (!__pyx_builtin_range) __PYX_ERR(0, 789, __pyx_L1_error) __pyx_builtin_TypeError = __Pyx_GetBuiltinName(__pyx_n_s_TypeError); if (!__pyx_builtin_TypeError) __PYX_ERR(1, 2, __pyx_L1_error) return 0; __pyx_L1_error:; @@ -16400,14 +16401,14 @@ static CYTHON_SMALL_CODE int __Pyx_InitCachedConstants(void) { __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__Pyx_InitCachedConstants", 0); - /* "mpfmc/core/audio/audio_interface.pyx":517 + /* "mpfmc/core/audio/audio_interface.pyx":518 * cdef int track_num = len(self.tracks) * if track_num == MAX_TRACKS: * self.log.error("Add track failed - the maximum number of tracks " # <<<<<<<<<<<<<< * "(%d) has been reached.", MAX_TRACKS) * return None */ - __pyx_tuple__3 = PyTuple_Pack(2, __pyx_kp_u_Add_track_failed_the_maximum_num, __pyx_int_8); if (unlikely(!__pyx_tuple__3)) __PYX_ERR(0, 517, __pyx_L1_error) + __pyx_tuple__3 = PyTuple_Pack(2, __pyx_kp_u_Add_track_failed_the_maximum_num, __pyx_int_8); if (unlikely(!__pyx_tuple__3)) __PYX_ERR(0, 518, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__3); __Pyx_GIVEREF(__pyx_tuple__3); @@ -16454,83 +16455,83 @@ static CYTHON_SMALL_CODE int __Pyx_InitCachedConstants(void) { __Pyx_GIVEREF(__pyx_tuple__8); __pyx_codeobj__9 = (PyObject*)__Pyx_PyCode_New(0, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__8, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_mpfmc_core_audio_audio_interface_2, __pyx_n_s_get_gst_version, 56, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__9)) __PYX_ERR(0, 56, __pyx_L1_error) - /* "mpfmc/core/audio/audio_interface.pyx":215 + /* "mpfmc/core/audio/audio_interface.pyx":216 * * @staticmethod * def initialize(int rate=44100, int channels=2, int buffer_samples=4096, **kwargs): # <<<<<<<<<<<<<< * """ * Initializes and retrieves the audio interface instance. */ - __pyx_tuple__10 = PyTuple_Pack(5, __pyx_n_s_rate, __pyx_n_s_channels, __pyx_n_s_buffer_samples, __pyx_n_s_kwargs, __pyx_n_s_audio_interface_instance); if (unlikely(!__pyx_tuple__10)) __PYX_ERR(0, 215, __pyx_L1_error) + __pyx_tuple__10 = PyTuple_Pack(5, __pyx_n_s_rate, __pyx_n_s_channels, __pyx_n_s_buffer_samples, __pyx_n_s_kwargs, __pyx_n_s_audio_interface_instance); if (unlikely(!__pyx_tuple__10)) __PYX_ERR(0, 216, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__10); __Pyx_GIVEREF(__pyx_tuple__10); - __pyx_codeobj__11 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS|CO_VARKEYWORDS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__10, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_mpfmc_core_audio_audio_interface_2, __pyx_n_s_initialize, 215, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__11)) __PYX_ERR(0, 215, __pyx_L1_error) + __pyx_codeobj__11 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS|CO_VARKEYWORDS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__10, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_mpfmc_core_audio_audio_interface_2, __pyx_n_s_initialize, 216, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__11)) __PYX_ERR(0, 216, __pyx_L1_error) - /* "mpfmc/core/audio/audio_interface.pyx":234 + /* "mpfmc/core/audio/audio_interface.pyx":235 * * @staticmethod * def power_of_two(int num): # <<<<<<<<<<<<<< * """ Returns whether or not the supplied number is a power of 2 """ * return ((num & (num - 1)) == 0) and num != 0 */ - __pyx_tuple__12 = PyTuple_Pack(1, __pyx_n_s_num); if (unlikely(!__pyx_tuple__12)) __PYX_ERR(0, 234, __pyx_L1_error) + __pyx_tuple__12 = PyTuple_Pack(1, __pyx_n_s_num); if (unlikely(!__pyx_tuple__12)) __PYX_ERR(0, 235, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__12); __Pyx_GIVEREF(__pyx_tuple__12); - __pyx_codeobj__13 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__12, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_mpfmc_core_audio_audio_interface_2, __pyx_n_s_power_of_two, 234, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__13)) __PYX_ERR(0, 234, __pyx_L1_error) + __pyx_codeobj__13 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__12, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_mpfmc_core_audio_audio_interface_2, __pyx_n_s_power_of_two, 235, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__13)) __PYX_ERR(0, 235, __pyx_L1_error) - /* "mpfmc/core/audio/audio_interface.pyx":239 + /* "mpfmc/core/audio/audio_interface.pyx":240 * * @staticmethod * def db_to_gain(float db): # <<<<<<<<<<<<<< * """Converts a value in decibels (-inf to 0.0) to a gain (0.0 to 1.0)""" * return pow(10, db / 20.0) */ - __pyx_tuple__14 = PyTuple_Pack(1, __pyx_n_s_db); if (unlikely(!__pyx_tuple__14)) __PYX_ERR(0, 239, __pyx_L1_error) + __pyx_tuple__14 = PyTuple_Pack(1, __pyx_n_s_db); if (unlikely(!__pyx_tuple__14)) __PYX_ERR(0, 240, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__14); __Pyx_GIVEREF(__pyx_tuple__14); - __pyx_codeobj__15 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__14, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_mpfmc_core_audio_audio_interface_2, __pyx_n_s_db_to_gain, 239, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__15)) __PYX_ERR(0, 239, __pyx_L1_error) + __pyx_codeobj__15 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__14, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_mpfmc_core_audio_audio_interface_2, __pyx_n_s_db_to_gain, 240, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__15)) __PYX_ERR(0, 240, __pyx_L1_error) - /* "mpfmc/core/audio/audio_interface.pyx":244 + /* "mpfmc/core/audio/audio_interface.pyx":245 * * @staticmethod * def string_to_gain(gain): # <<<<<<<<<<<<<< * """Converts a string to a gain value (0.0 to 1.0)""" * cdef str gain_string = str(gain).upper() */ - __pyx_tuple__16 = PyTuple_Pack(4, __pyx_n_s_gain, __pyx_n_s_gain_string, __pyx_n_s_genexpr, __pyx_n_s_genexpr); if (unlikely(!__pyx_tuple__16)) __PYX_ERR(0, 244, __pyx_L1_error) + __pyx_tuple__16 = PyTuple_Pack(4, __pyx_n_s_gain, __pyx_n_s_gain_string, __pyx_n_s_genexpr, __pyx_n_s_genexpr); if (unlikely(!__pyx_tuple__16)) __PYX_ERR(0, 245, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__16); __Pyx_GIVEREF(__pyx_tuple__16); - __pyx_codeobj__17 = (PyObject*)__Pyx_PyCode_New(1, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__16, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_mpfmc_core_audio_audio_interface_2, __pyx_n_s_string_to_gain, 244, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__17)) __PYX_ERR(0, 244, __pyx_L1_error) + __pyx_codeobj__17 = (PyObject*)__Pyx_PyCode_New(1, 0, 4, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__16, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_mpfmc_core_audio_audio_interface_2, __pyx_n_s_string_to_gain, 245, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__17)) __PYX_ERR(0, 245, __pyx_L1_error) - /* "mpfmc/core/audio/audio_interface.pyx":269 + /* "mpfmc/core/audio/audio_interface.pyx":270 * * @staticmethod * def string_to_secs(time): # <<<<<<<<<<<<<< * """Decodes a string of real-world time into a float of seconds. * Example inputs: */ - __pyx_tuple__18 = PyTuple_Pack(8, __pyx_n_s_time, __pyx_n_s_time_string, __pyx_n_s_genexpr, __pyx_n_s_genexpr, __pyx_n_s_genexpr, __pyx_n_s_genexpr, __pyx_n_s_genexpr, __pyx_n_s_genexpr); if (unlikely(!__pyx_tuple__18)) __PYX_ERR(0, 269, __pyx_L1_error) + __pyx_tuple__18 = PyTuple_Pack(8, __pyx_n_s_time, __pyx_n_s_time_string, __pyx_n_s_genexpr, __pyx_n_s_genexpr, __pyx_n_s_genexpr, __pyx_n_s_genexpr, __pyx_n_s_genexpr, __pyx_n_s_genexpr); if (unlikely(!__pyx_tuple__18)) __PYX_ERR(0, 270, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__18); __Pyx_GIVEREF(__pyx_tuple__18); - __pyx_codeobj__19 = (PyObject*)__Pyx_PyCode_New(1, 0, 8, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__18, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_mpfmc_core_audio_audio_interface_2, __pyx_n_s_string_to_secs, 269, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__19)) __PYX_ERR(0, 269, __pyx_L1_error) + __pyx_codeobj__19 = (PyObject*)__Pyx_PyCode_New(1, 0, 8, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__18, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_mpfmc_core_audio_audio_interface_2, __pyx_n_s_string_to_secs, 270, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__19)) __PYX_ERR(0, 270, __pyx_L1_error) - /* "mpfmc/core/audio/audio_interface.pyx":448 + /* "mpfmc/core/audio/audio_interface.pyx":449 * * @staticmethod * def get_max_tracks(): # <<<<<<<<<<<<<< * """ Returns the maximum number of tracks allowed. """ * return MAX_TRACKS */ - __pyx_codeobj__20 = (PyObject*)__Pyx_PyCode_New(0, 0, 0, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_mpfmc_core_audio_audio_interface_2, __pyx_n_s_get_max_tracks, 448, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__20)) __PYX_ERR(0, 448, __pyx_L1_error) + __pyx_codeobj__20 = (PyObject*)__Pyx_PyCode_New(0, 0, 0, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_mpfmc_core_audio_audio_interface_2, __pyx_n_s_get_max_tracks, 449, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__20)) __PYX_ERR(0, 449, __pyx_L1_error) - /* "mpfmc/core/audio/audio_interface.pyx":453 + /* "mpfmc/core/audio/audio_interface.pyx":454 * * @staticmethod * def get_max_markers(): # <<<<<<<<<<<<<< * """Return the maximum number of markers allowed per sound""" * return MAX_MARKERS */ - __pyx_codeobj__21 = (PyObject*)__Pyx_PyCode_New(0, 0, 0, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_mpfmc_core_audio_audio_interface_2, __pyx_n_s_get_max_markers, 453, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__21)) __PYX_ERR(0, 453, __pyx_L1_error) + __pyx_codeobj__21 = (PyObject*)__Pyx_PyCode_New(0, 0, 0, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_mpfmc_core_audio_audio_interface_2, __pyx_n_s_get_max_markers, 454, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__21)) __PYX_ERR(0, 454, __pyx_L1_error) __Pyx_RefNannyFinishContext(); return 0; __pyx_L1_error:; @@ -16618,7 +16619,7 @@ static int __Pyx_modinit_type_init_code(void) { if (PyObject_SetAttr(__pyx_m, __pyx_n_s_AudioInterface, (PyObject *)&__pyx_type_5mpfmc_4core_5audio_15audio_interface_AudioInterface) < 0) __PYX_ERR(0, 66, __pyx_L1_error) if (__Pyx_setup_reduce((PyObject*)&__pyx_type_5mpfmc_4core_5audio_15audio_interface_AudioInterface) < 0) __PYX_ERR(0, 66, __pyx_L1_error) __pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface = &__pyx_type_5mpfmc_4core_5audio_15audio_interface_AudioInterface; - if (PyType_Ready(&__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct__string_to_gain) < 0) __PYX_ERR(0, 244, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct__string_to_gain) < 0) __PYX_ERR(0, 245, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct__string_to_gain.tp_print = 0; #endif @@ -16626,7 +16627,7 @@ static int __Pyx_modinit_type_init_code(void) { __pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct__string_to_gain.tp_getattro = __Pyx_PyObject_GenericGetAttrNoDict; } __pyx_ptype_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct__string_to_gain = &__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct__string_to_gain; - if (PyType_Ready(&__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_1_genexpr) < 0) __PYX_ERR(0, 249, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_1_genexpr) < 0) __PYX_ERR(0, 250, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_1_genexpr.tp_print = 0; #endif @@ -16634,7 +16635,7 @@ static int __Pyx_modinit_type_init_code(void) { __pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_1_genexpr.tp_getattro = __Pyx_PyObject_GenericGetAttrNoDict; } __pyx_ptype_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_1_genexpr = &__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_1_genexpr; - if (PyType_Ready(&__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_2_string_to_secs) < 0) __PYX_ERR(0, 269, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_2_string_to_secs) < 0) __PYX_ERR(0, 270, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_2_string_to_secs.tp_print = 0; #endif @@ -16642,7 +16643,7 @@ static int __Pyx_modinit_type_init_code(void) { __pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_2_string_to_secs.tp_getattro = __Pyx_PyObject_GenericGetAttrNoDict; } __pyx_ptype_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_2_string_to_secs = &__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_2_string_to_secs; - if (PyType_Ready(&__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_3_genexpr) < 0) __PYX_ERR(0, 288, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_3_genexpr) < 0) __PYX_ERR(0, 289, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_3_genexpr.tp_print = 0; #endif @@ -16650,7 +16651,7 @@ static int __Pyx_modinit_type_init_code(void) { __pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_3_genexpr.tp_getattro = __Pyx_PyObject_GenericGetAttrNoDict; } __pyx_ptype_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_3_genexpr = &__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_3_genexpr; - if (PyType_Ready(&__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_4_genexpr) < 0) __PYX_ERR(0, 292, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_4_genexpr) < 0) __PYX_ERR(0, 293, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_4_genexpr.tp_print = 0; #endif @@ -16658,7 +16659,7 @@ static int __Pyx_modinit_type_init_code(void) { __pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_4_genexpr.tp_getattro = __Pyx_PyObject_GenericGetAttrNoDict; } __pyx_ptype_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_4_genexpr = &__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_4_genexpr; - if (PyType_Ready(&__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_5_genexpr) < 0) __PYX_ERR(0, 296, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_5_genexpr) < 0) __PYX_ERR(0, 297, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_5_genexpr.tp_print = 0; #endif @@ -16666,7 +16667,7 @@ static int __Pyx_modinit_type_init_code(void) { __pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_5_genexpr.tp_getattro = __Pyx_PyObject_GenericGetAttrNoDict; } __pyx_ptype_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_5_genexpr = &__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_5_genexpr; - if (PyType_Ready(&__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_6_genexpr) < 0) __PYX_ERR(0, 300, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_6_genexpr) < 0) __PYX_ERR(0, 301, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_6_genexpr.tp_print = 0; #endif @@ -16674,7 +16675,7 @@ static int __Pyx_modinit_type_init_code(void) { __pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_6_genexpr.tp_getattro = __Pyx_PyObject_GenericGetAttrNoDict; } __pyx_ptype_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_6_genexpr = &__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_6_genexpr; - if (PyType_Ready(&__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_7_genexpr) < 0) __PYX_ERR(0, 304, __pyx_L1_error) + if (PyType_Ready(&__pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_7_genexpr) < 0) __PYX_ERR(0, 305, __pyx_L1_error) #if PY_VERSION_HEX < 0x030800B1 __pyx_type_5mpfmc_4core_5audio_15audio_interface___pyx_scope_struct_7_genexpr.tp_print = 0; #endif @@ -17050,306 +17051,306 @@ if (!__Pyx_RefNanny) { if (PyDict_SetItem(__pyx_d, __pyx_n_s_get_gst_version, __pyx_t_2) < 0) __PYX_ERR(0, 56, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - /* "mpfmc/core/audio/audio_interface.pyx":215 + /* "mpfmc/core/audio/audio_interface.pyx":216 * * @staticmethod * def initialize(int rate=44100, int channels=2, int buffer_samples=4096, **kwargs): # <<<<<<<<<<<<<< * """ * Initializes and retrieves the audio interface instance. */ - __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_9initialize, NULL, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 215, __pyx_L1_error) + __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_9initialize, NULL, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 216, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_initialize, __pyx_t_2) < 0) __PYX_ERR(0, 215, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_initialize, __pyx_t_2) < 0) __PYX_ERR(0, 216, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; PyType_Modified(__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface); - /* "mpfmc/core/audio/audio_interface.pyx":214 + /* "mpfmc/core/audio/audio_interface.pyx":215 * raise AudioException(msg) * * @staticmethod # <<<<<<<<<<<<<< * def initialize(int rate=44100, int channels=2, int buffer_samples=4096, **kwargs): * """ */ - __Pyx_GetNameInClass(__pyx_t_2, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_initialize); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 215, __pyx_L1_error) + __Pyx_GetNameInClass(__pyx_t_2, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_initialize); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 216, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_staticmethod, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 214, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_staticmethod, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 215, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_initialize, __pyx_t_1) < 0) __PYX_ERR(0, 215, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_initialize, __pyx_t_1) < 0) __PYX_ERR(0, 216, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; PyType_Modified(__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface); - /* "mpfmc/core/audio/audio_interface.pyx":234 + /* "mpfmc/core/audio/audio_interface.pyx":235 * * @staticmethod * def power_of_two(int num): # <<<<<<<<<<<<<< * """ Returns whether or not the supplied number is a power of 2 """ * return ((num & (num - 1)) == 0) and num != 0 */ - __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_11power_of_two, NULL, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 234, __pyx_L1_error) + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_11power_of_two, NULL, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 235, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_power_of_two, __pyx_t_1) < 0) __PYX_ERR(0, 234, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_power_of_two, __pyx_t_1) < 0) __PYX_ERR(0, 235, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; PyType_Modified(__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface); - /* "mpfmc/core/audio/audio_interface.pyx":233 + /* "mpfmc/core/audio/audio_interface.pyx":234 * return audio_interface_instance * * @staticmethod # <<<<<<<<<<<<<< * def power_of_two(int num): * """ Returns whether or not the supplied number is a power of 2 """ */ - __Pyx_GetNameInClass(__pyx_t_1, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_power_of_two); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 234, __pyx_L1_error) + __Pyx_GetNameInClass(__pyx_t_1, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_power_of_two); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 235, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_builtin_staticmethod, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 233, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_builtin_staticmethod, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 234, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_power_of_two, __pyx_t_2) < 0) __PYX_ERR(0, 234, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_power_of_two, __pyx_t_2) < 0) __PYX_ERR(0, 235, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; PyType_Modified(__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface); - /* "mpfmc/core/audio/audio_interface.pyx":239 + /* "mpfmc/core/audio/audio_interface.pyx":240 * * @staticmethod * def db_to_gain(float db): # <<<<<<<<<<<<<< * """Converts a value in decibels (-inf to 0.0) to a gain (0.0 to 1.0)""" * return pow(10, db / 20.0) */ - __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_13db_to_gain, NULL, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 239, __pyx_L1_error) + __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_13db_to_gain, NULL, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 240, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_db_to_gain, __pyx_t_2) < 0) __PYX_ERR(0, 239, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_db_to_gain, __pyx_t_2) < 0) __PYX_ERR(0, 240, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; PyType_Modified(__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface); - /* "mpfmc/core/audio/audio_interface.pyx":238 + /* "mpfmc/core/audio/audio_interface.pyx":239 * return ((num & (num - 1)) == 0) and num != 0 * * @staticmethod # <<<<<<<<<<<<<< * def db_to_gain(float db): * """Converts a value in decibels (-inf to 0.0) to a gain (0.0 to 1.0)""" */ - __Pyx_GetNameInClass(__pyx_t_2, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_db_to_gain); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 239, __pyx_L1_error) + __Pyx_GetNameInClass(__pyx_t_2, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_db_to_gain); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 240, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_staticmethod, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 238, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_staticmethod, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 239, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_db_to_gain, __pyx_t_1) < 0) __PYX_ERR(0, 239, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_db_to_gain, __pyx_t_1) < 0) __PYX_ERR(0, 240, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; PyType_Modified(__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface); - /* "mpfmc/core/audio/audio_interface.pyx":244 + /* "mpfmc/core/audio/audio_interface.pyx":245 * * @staticmethod * def string_to_gain(gain): # <<<<<<<<<<<<<< * """Converts a string to a gain value (0.0 to 1.0)""" * cdef str gain_string = str(gain).upper() */ - __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_15string_to_gain, NULL, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 244, __pyx_L1_error) + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_15string_to_gain, NULL, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 245, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_string_to_gain, __pyx_t_1) < 0) __PYX_ERR(0, 244, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_string_to_gain, __pyx_t_1) < 0) __PYX_ERR(0, 245, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; PyType_Modified(__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface); - /* "mpfmc/core/audio/audio_interface.pyx":243 + /* "mpfmc/core/audio/audio_interface.pyx":244 * return pow(10, db / 20.0) * * @staticmethod # <<<<<<<<<<<<<< * def string_to_gain(gain): * """Converts a string to a gain value (0.0 to 1.0)""" */ - __Pyx_GetNameInClass(__pyx_t_1, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_string_to_gain); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 244, __pyx_L1_error) + __Pyx_GetNameInClass(__pyx_t_1, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_string_to_gain); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 245, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_builtin_staticmethod, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 243, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_builtin_staticmethod, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 244, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_string_to_gain, __pyx_t_2) < 0) __PYX_ERR(0, 244, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_string_to_gain, __pyx_t_2) < 0) __PYX_ERR(0, 245, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; PyType_Modified(__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface); - /* "mpfmc/core/audio/audio_interface.pyx":269 + /* "mpfmc/core/audio/audio_interface.pyx":270 * * @staticmethod * def string_to_secs(time): # <<<<<<<<<<<<<< * """Decodes a string of real-world time into a float of seconds. * Example inputs: */ - __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_23string_to_secs, NULL, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 269, __pyx_L1_error) + __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_23string_to_secs, NULL, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 270, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_string_to_secs, __pyx_t_2) < 0) __PYX_ERR(0, 269, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_string_to_secs, __pyx_t_2) < 0) __PYX_ERR(0, 270, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; PyType_Modified(__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface); - /* "mpfmc/core/audio/audio_interface.pyx":268 + /* "mpfmc/core/audio/audio_interface.pyx":269 * return round(buffer_length / (self.audio_callback_data.sample_rate * self.audio_callback_data.channels * self.audio_callback_data.bytes_per_sample), 3) * * @staticmethod # <<<<<<<<<<<<<< * def string_to_secs(time): * """Decodes a string of real-world time into a float of seconds. */ - __Pyx_GetNameInClass(__pyx_t_2, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_string_to_secs); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 269, __pyx_L1_error) + __Pyx_GetNameInClass(__pyx_t_2, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_string_to_secs); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 270, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_staticmethod, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 268, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_staticmethod, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 269, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_string_to_secs, __pyx_t_1) < 0) __PYX_ERR(0, 269, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_string_to_secs, __pyx_t_1) < 0) __PYX_ERR(0, 270, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; PyType_Modified(__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface); - /* "mpfmc/core/audio/audio_interface.pyx":340 + /* "mpfmc/core/audio/audio_interface.pyx":341 * * @classmethod * def get_sdl_version(cls): # <<<<<<<<<<<<<< * """ * Returns the version of the SDL library */ - __Pyx_GetNameInClass(__pyx_t_1, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_get_sdl_version); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 340, __pyx_L1_error) + __Pyx_GetNameInClass(__pyx_t_1, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_get_sdl_version); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 341, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - /* "mpfmc/core/audio/audio_interface.pyx":339 + /* "mpfmc/core/audio/audio_interface.pyx":340 * return int(self.audio_callback_data.sample_rate * seconds) * * @classmethod # <<<<<<<<<<<<<< * def get_sdl_version(cls): * """ */ - __pyx_t_2 = __Pyx_Method_ClassMethod(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 339, __pyx_L1_error) + __pyx_t_2 = __Pyx_Method_ClassMethod(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 340, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_get_sdl_version, __pyx_t_2) < 0) __PYX_ERR(0, 340, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_get_sdl_version, __pyx_t_2) < 0) __PYX_ERR(0, 341, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; PyType_Modified(__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface); - /* "mpfmc/core/audio/audio_interface.pyx":350 + /* "mpfmc/core/audio/audio_interface.pyx":351 * * @classmethod * def get_sdl_mixer_version(cls): # <<<<<<<<<<<<<< * """ * Returns the version of the dynamically linked SDL_Mixer library */ - __Pyx_GetNameInClass(__pyx_t_2, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_get_sdl_mixer_version); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 350, __pyx_L1_error) + __Pyx_GetNameInClass(__pyx_t_2, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_get_sdl_mixer_version); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 351, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - /* "mpfmc/core/audio/audio_interface.pyx":349 + /* "mpfmc/core/audio/audio_interface.pyx":350 * return 'SDL {}.{}.{}'.format(version.major, version.minor, version.patch) * * @classmethod # <<<<<<<<<<<<<< * def get_sdl_mixer_version(cls): * """ */ - __pyx_t_1 = __Pyx_Method_ClassMethod(__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 349, __pyx_L1_error) + __pyx_t_1 = __Pyx_Method_ClassMethod(__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 350, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_get_sdl_mixer_version, __pyx_t_1) < 0) __PYX_ERR(0, 350, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_get_sdl_mixer_version, __pyx_t_1) < 0) __PYX_ERR(0, 351, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; PyType_Modified(__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface); - /* "mpfmc/core/audio/audio_interface.pyx":359 + /* "mpfmc/core/audio/audio_interface.pyx":360 * * @classmethod * def get_gstreamer_version(cls): # <<<<<<<<<<<<<< * """ * Returns the version of the GStreamer library */ - __Pyx_GetNameInClass(__pyx_t_1, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_get_gstreamer_version); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 359, __pyx_L1_error) + __Pyx_GetNameInClass(__pyx_t_1, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_get_gstreamer_version); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 360, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - /* "mpfmc/core/audio/audio_interface.pyx":358 + /* "mpfmc/core/audio/audio_interface.pyx":359 * return 'SDL_Mixer {}.{}.{}'.format(version.major, version.minor, version.patch) * * @classmethod # <<<<<<<<<<<<<< * def get_gstreamer_version(cls): * """ */ - __pyx_t_2 = __Pyx_Method_ClassMethod(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 358, __pyx_L1_error) + __pyx_t_2 = __Pyx_Method_ClassMethod(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 359, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_get_gstreamer_version, __pyx_t_2) < 0) __PYX_ERR(0, 359, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_get_gstreamer_version, __pyx_t_2) < 0) __PYX_ERR(0, 360, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; PyType_Modified(__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface); - /* "mpfmc/core/audio/audio_interface.pyx":369 + /* "mpfmc/core/audio/audio_interface.pyx":370 * * @classmethod * def get_glib_version(cls): # <<<<<<<<<<<<<< * """ * Returns the version of the GLib library */ - __Pyx_GetNameInClass(__pyx_t_2, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_get_glib_version); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 369, __pyx_L1_error) + __Pyx_GetNameInClass(__pyx_t_2, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_get_glib_version); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 370, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - /* "mpfmc/core/audio/audio_interface.pyx":368 + /* "mpfmc/core/audio/audio_interface.pyx":369 * gst_version[0], gst_version[1], gst_version[2], gst_version[3]) * * @classmethod # <<<<<<<<<<<<<< * def get_glib_version(cls): * """ */ - __pyx_t_1 = __Pyx_Method_ClassMethod(__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 368, __pyx_L1_error) + __pyx_t_1 = __Pyx_Method_ClassMethod(__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 369, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_get_glib_version, __pyx_t_1) < 0) __PYX_ERR(0, 369, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_get_glib_version, __pyx_t_1) < 0) __PYX_ERR(0, 370, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; PyType_Modified(__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface); - /* "mpfmc/core/audio/audio_interface.pyx":448 + /* "mpfmc/core/audio/audio_interface.pyx":449 * * @staticmethod * def get_max_tracks(): # <<<<<<<<<<<<<< * """ Returns the maximum number of tracks allowed. """ * return MAX_TRACKS */ - __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_49get_max_tracks, NULL, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 448, __pyx_L1_error) + __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_49get_max_tracks, NULL, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_get_max_tracks, __pyx_t_1) < 0) __PYX_ERR(0, 448, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_get_max_tracks, __pyx_t_1) < 0) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; PyType_Modified(__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface); - /* "mpfmc/core/audio/audio_interface.pyx":447 + /* "mpfmc/core/audio/audio_interface.pyx":448 * Mix_CloseAudio() * * @staticmethod # <<<<<<<<<<<<<< * def get_max_tracks(): * """ Returns the maximum number of tracks allowed. """ */ - __Pyx_GetNameInClass(__pyx_t_1, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_get_max_tracks); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 448, __pyx_L1_error) + __Pyx_GetNameInClass(__pyx_t_1, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_get_max_tracks); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); - __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_builtin_staticmethod, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 447, __pyx_L1_error) + __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_builtin_staticmethod, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 448, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; - if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_get_max_tracks, __pyx_t_2) < 0) __PYX_ERR(0, 448, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_get_max_tracks, __pyx_t_2) < 0) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; PyType_Modified(__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface); - /* "mpfmc/core/audio/audio_interface.pyx":453 + /* "mpfmc/core/audio/audio_interface.pyx":454 * * @staticmethod * def get_max_markers(): # <<<<<<<<<<<<<< * """Return the maximum number of markers allowed per sound""" * return MAX_MARKERS */ - __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_51get_max_markers, NULL, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 453, __pyx_L1_error) + __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_5mpfmc_4core_5audio_15audio_interface_14AudioInterface_51get_max_markers, NULL, __pyx_n_s_mpfmc_core_audio_audio_interface); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 454, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_get_max_markers, __pyx_t_2) < 0) __PYX_ERR(0, 453, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_get_max_markers, __pyx_t_2) < 0) __PYX_ERR(0, 454, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; PyType_Modified(__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface); - /* "mpfmc/core/audio/audio_interface.pyx":452 + /* "mpfmc/core/audio/audio_interface.pyx":453 * return MAX_TRACKS * * @staticmethod # <<<<<<<<<<<<<< * def get_max_markers(): * """Return the maximum number of markers allowed per sound""" */ - __Pyx_GetNameInClass(__pyx_t_2, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_get_max_markers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 453, __pyx_L1_error) + __Pyx_GetNameInClass(__pyx_t_2, (PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface, __pyx_n_s_get_max_markers); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 454, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); - __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_staticmethod, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 452, __pyx_L1_error) + __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_builtin_staticmethod, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 453, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; - if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_get_max_markers, __pyx_t_1) < 0) __PYX_ERR(0, 453, __pyx_L1_error) + if (PyDict_SetItem((PyObject *)__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface->tp_dict, __pyx_n_s_get_max_markers, __pyx_t_1) < 0) __PYX_ERR(0, 454, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; PyType_Modified(__pyx_ptype_5mpfmc_4core_5audio_15audio_interface_AudioInterface); - /* "mpfmc/core/audio/audio_interface.pyx":502 + /* "mpfmc/core/audio/audio_interface.pyx":503 * * def create_standard_track(self, object mc, str name not None, * int max_simultaneous_sounds=MAX_SIMULTANEOUS_SOUNDS_DEFAULT, # <<<<<<<<<<<<<< diff --git a/mpfmc/core/audio/playlist_controller.c b/mpfmc/core/audio/playlist_controller.c index cf712457..2a6a3a20 100644 --- a/mpfmc/core/audio/playlist_controller.c +++ b/mpfmc/core/audio/playlist_controller.c @@ -820,8 +820,8 @@ static const char *__pyx_filename; static const char *__pyx_f[] = { - "mpfmc\\core\\audio\\playlist_controller.pyx", - "mpfmc\\core\\audio\\track.pxd", + "mpfmc/core/audio/playlist_controller.pyx", + "mpfmc/core/audio/track.pxd", }; /*--- Type declarations ---*/ @@ -1597,7 +1597,7 @@ static const char __pyx_k_set_repeat_Setting_repeat_for_cu[] = "set_repeat - Set static const char __pyx_k_stop_No_playlist_is_currently_pl[] = "stop - No playlist is currently playing. Could not stop current playlist."; static const char __pyx_k_stop_Stopping_the_current_playli[] = "stop - Stopping the current playlist ('%s')."; static const char __pyx_k_PlaylistController__on_sound_ins_2[] = "PlaylistController._on_sound_instance_about_to_finish"; -static const char __pyx_k_mpfmc_core_audio_playlist_contro_2[] = "mpfmc\\core\\audio\\playlist_controller.pyx"; +static const char __pyx_k_mpfmc_core_audio_playlist_contro_2[] = "mpfmc/core/audio/playlist_controller.pyx"; static PyObject *__pyx_kp_u_Clearing_context_s; static PyObject *__pyx_kp_u_Created_PlaylistController_s; static PyObject *__pyx_n_s_PlaylistController; diff --git a/mpfmc/core/audio/sound_file.c b/mpfmc/core/audio/sound_file.c index bfbf631b..3aa25512 100644 --- a/mpfmc/core/audio/sound_file.c +++ b/mpfmc/core/audio/sound_file.c @@ -820,7 +820,7 @@ static const char *__pyx_filename; static const char *__pyx_f[] = { - "mpfmc\\core\\audio\\sound_file.pyx", + "mpfmc/core/audio/sound_file.pyx", "stringsource", }; /* NoFastGil.proto */ diff --git a/mpfmc/core/audio/track.c b/mpfmc/core/audio/track.c index efefb0b3..7df8f970 100644 --- a/mpfmc/core/audio/track.c +++ b/mpfmc/core/audio/track.c @@ -820,7 +820,7 @@ static const char *__pyx_filename; static const char *__pyx_f[] = { - "mpfmc\\core\\audio\\track.pyx", + "mpfmc/core/audio/track.pyx", "stringsource", }; /* ForceInitThreads.proto */ diff --git a/mpfmc/core/audio/track_standard.c b/mpfmc/core/audio/track_standard.c index 29cc6169..327fae8c 100644 --- a/mpfmc/core/audio/track_standard.c +++ b/mpfmc/core/audio/track_standard.c @@ -820,9 +820,9 @@ static const char *__pyx_filename; static const char *__pyx_f[] = { - "mpfmc\\core\\audio\\track_standard.pyx", + "mpfmc/core/audio/track_standard.pyx", "stringsource", - "mpfmc\\core\\audio\\sound_file.pxd", + "mpfmc/core/audio/sound_file.pxd", }; /* NoFastGil.proto */ #define __Pyx_PyGILState_Ensure PyGILState_Ensure @@ -2245,7 +2245,7 @@ static const char __pyx_k_Sound_s_has_reached_the_maximum[] = "Sound %s has reac static const char __pyx_k_Track_play_sound_encountered_an[] = "Track {} play_sound encountered an unexpected exception while attempting to play the {} sound."; static const char __pyx_k_get_newest_playing_sound_instan[] = "_get_newest_playing_sound_instance"; static const char __pyx_k_get_oldest_playing_sound_instan[] = "_get_oldest_playing_sound_instance"; -static const char __pyx_k_mpfmc_core_audio_track_standard[] = "mpfmc\\core\\audio\\track_standard.pyx"; +static const char __pyx_k_mpfmc_core_audio_track_standard[] = "mpfmc/core/audio/track_standard.pyx"; static const char __pyx_k_play_sound_No_idle_sound_player[] = "play_sound - No idle sound player is available."; static const char __pyx_k_play_sound_on_sound_player_s_tr[] = "_play_sound_on_sound_player - %s track is not currently playing and therefore the request to play sound %s will be canceled"; static const char __pyx_k_remove_sound_instance_from_queu[] = "_remove_sound_instance_from_queue"; diff --git a/mpfmc/uix/bitmap_font/bitmap_font.c b/mpfmc/uix/bitmap_font/bitmap_font.c index d86320b9..cd69d87f 100644 --- a/mpfmc/uix/bitmap_font/bitmap_font.c +++ b/mpfmc/uix/bitmap_font/bitmap_font.c @@ -817,7 +817,7 @@ static const char *__pyx_filename; static const char *__pyx_f[] = { "stringsource", - "mpfmc\\uix\\bitmap_font\\bitmap_font.pyx", + "mpfmc/uix/bitmap_font/bitmap_font.pyx", }; /*--- Type declarations ---*/