Hi Moodkie Team,
I have been using esaysave for all saving related stuff in my game and its awesome to use. I have a scenario where the user adds a song in runtime from windows explorer and I save it to the disk with ES3.Save<AudioClip>() command. Next time when the user open the game the saved song will be loaded again that was saved previously. But I feel like the loading of the song takes more time.
Is there any workaround or advice to speed up the loading of the audioclip ? Will putting it in a different thread help to speed up loading?
Thank You!
Audioclip loading is slow.
Re: Audioclip loading is slow.
Hi there,
AudioClips are inherently large, so they're always going to have quite a large performance impact.
However, the first thing I would do is instead of loading the user's audio file and then using ES3.Save<AudioClip> to save it to disk, save their audio file directly using:
You can then load this audio file using:
This ensures that the data remains in encoded format, and that it's decoded by the hardware where possible.
All the best,
Joel
AudioClips are inherently large, so they're always going to have quite a large performance impact.
However, the first thing I would do is instead of loading the user's audio file and then using ES3.Save<AudioClip> to save it to disk, save their audio file directly using:
Code: Select all
ES3.SaveRaw(ES3.LoadRaw(PathToAudioFile), "MyAudioFile.wav");
Code: Select all
var audioFile = ES3.LoadAudio("MyAudioFile.wav");
All the best,
Joel
-
- Posts: 2
- Joined: Thu May 21, 2020 5:06 am
Re: Audioclip loading is slow.
Thank you so much for your quick response.
Using the process as you have mentioned solved the lag. Now the audio/song loading is instantaneous.
Using the process as you have mentioned solved the lag. Now the audio/song loading is instantaneous.