tom
New Member
Posts: 44
Posts: 44
|
Post by tom on Sept 6, 2016 9:01:19 GMT
I have set a looping sound using the action Master Audio Play Sound. Unfortunately between another reproduction of this sound in the loop is a little break.
How do I remove this gap?
What is interesting, if I have a looping sound using action Master Audio Playlist Clip by Name, there is no gap.
|
|
|
Post by DarkTonic Dev on Sept 6, 2016 16:01:16 GMT
Those should work just the same. I can't reproduce this problem. Please send me an example project to demonstrate this and I'll take a look.
|
|
tom
New Member
Posts: 44
Posts: 44
|
Post by tom on Sept 6, 2016 21:28:47 GMT
How can I sent example project, pack the project to zip and send to FTP?
|
|
|
Post by DarkTonic Dev on Sept 6, 2016 22:15:22 GMT
No need to give me ftp access. Easier to upload to dropbox / google drive and send me a link.
|
|
tom
New Member
Posts: 44
Posts: 44
|
Post by tom on Sept 9, 2016 10:45:31 GMT
Ha! I found the cause of gap problem. Audacity saves the MP3 sound files adding this gaps. Sometimes in front of the file, and sometimes in the back.
I read a little bit about this problem and it seems that I have to use a different file format. I did a small tests with OGG and everything is fine.
But there is important question -> do OGG files have any platform restrictions? Windows, Mac, IOS, Android?
|
|
|
Post by DarkTonic Dev on Sept 9, 2016 16:02:31 GMT
Not sure about ogg files, we never used them. Always wav files for us, which have no restrictions.
By the way even without the looping problem, you should never use mp3s for sound effects because it's horrible for performance. Our best practices section mentions this.
|
|
tom
New Member
Posts: 44
Posts: 44
|
Post by tom on Sept 9, 2016 18:14:47 GMT
Unfortunately, I have a few tons of sound and I have somehow to pack it.
|
|
|
Post by DarkTonic Dev on Sept 9, 2016 19:26:37 GMT
You're welcome to do so, but understand that each time you play a sound you may get frame rate skip / lag because of the Unity Engine (or target hardware) needing to decode the mp3 as it plays. And when you play several on top of each other, this effect compounds. It also takes I believe 50x as long for a sound effect to *start* playing when it's an mp3.
|
|
tom
New Member
Posts: 44
Posts: 44
|
Post by tom on Sept 9, 2016 21:37:05 GMT
OK, thanks for the explanation!
|
|
|
Post by DarkTonic Dev on Sept 9, 2016 22:18:53 GMT
No problem.
|
|