Updated log output info

This commit is contained in:
raysan5
2016-07-26 12:44:33 +02:00
parent 9e8232d750
commit 6d68c78989

View File

@@ -528,7 +528,7 @@ Sound LoadSound(char *fileName)
// Attach sound buffer to source
alSourcei(source, AL_BUFFER, buffer);
TraceLog(INFO, "[%s] Sound file loaded successfully (SampleRate: %i, BitRate: %i, Channels: %i)", fileName, wave.sampleRate, wave.bitsPerSample, wave.channels);
TraceLog(INFO, "[SND ID %i][BUFR ID %i] Sound file loaded successfully (SampleRate: %i, BitRate: %i, Channels: %i)", source, buffer, wave.sampleRate, wave.bitsPerSample, wave.channels);
// Unallocate WAV data
UnloadWave(wave);
@@ -759,7 +759,7 @@ void UnloadSound(Sound sound)
alDeleteSources(1, &sound.source);
alDeleteBuffers(1, &sound.buffer);
TraceLog(INFO, "Unloaded sound data");
TraceLog(INFO, "[SND ID %i][BUFR ID %i] Unloaded sound data from RAM", sound.source, sound.buffer);
}
// Play a sound
@@ -852,14 +852,13 @@ int PlayMusicStream(int index, char *fileName)
// Get file info
stb_vorbis_info info = stb_vorbis_get_info(musicStreams[index].stream);
TraceLog(INFO, "[%s] Ogg sample rate: %i", fileName, info.sample_rate);
TraceLog(INFO, "[%s] Ogg channels: %i", fileName, info.channels);
TraceLog(DEBUG, "[%s] Ogg sample rate: %i", fileName, info.sample_rate);
TraceLog(DEBUG, "[%s] Ogg channels: %i", fileName, info.channels);
TraceLog(DEBUG, "[%s] Temp memory required: %i", fileName, info.temp_memory_required);
musicStreams[index].loop = true; // We loop by default
musicStreams[index].enabled = true;
musicStreams[index].totalSamplesLeft = (unsigned int)stb_vorbis_stream_length_in_samples(musicStreams[index].stream) * info.channels;
musicStreams[index].totalLengthSeconds = stb_vorbis_stream_length_in_seconds(musicStreams[index].stream);
@@ -1369,7 +1368,7 @@ static void UnloadWave(Wave wave)
{
free(wave.data);
TraceLog(INFO, "Unloaded wave data");
TraceLog(INFO, "Unloaded wave data from RAM");
}
// Some required functions for audio standalone module version