int UnloadAt3(int channel) { if ((channel<0)||(channel>1)) { return PSPAALIB_ERROR_AT3_INVALID_CHANNEL; } StopAt3(channel); if (!streamsAt3[channel].initialized) { return PSPAALIB_SUCCESS; } streamsAt3[channel].paused=TRUE; streamsAt3[channel].stopReason=PSPAALIB_STOP_UNLOADED; free(streamsAt3[channel].data); free(streamsAt3[channel].buf); streamsAt3[channel].initialized=FALSE; return PSPAALIB_SUCCESS; }
int AalibStop(int channel) { if ((PSPAALIB_CHANNEL_WAV_1<=channel)&&(channel<=PSPAALIB_CHANNEL_WAV_32)) { return StopWav(channel-PSPAALIB_CHANNEL_WAV_1); } if ((PSPAALIB_CHANNEL_OGG_1<=channel)&&(channel<=PSPAALIB_CHANNEL_OGG_10)) { return StopOgg(channel-PSPAALIB_CHANNEL_OGG_1); } if ((PSPAALIB_CHANNEL_SCEMP3_1<=channel)&&(channel<=PSPAALIB_CHANNEL_SCEMP3_2)) { return StopSceMp3(channel-PSPAALIB_CHANNEL_SCEMP3_1); } if ((PSPAALIB_CHANNEL_AT3_1<=channel)&&(channel<=PSPAALIB_CHANNEL_AT3_2)) { return StopAt3(channel-PSPAALIB_CHANNEL_AT3_1); } return PSPAALIB_ERROR_INVALID_CHANNEL; }