|
Post by DarkTonic Dev on Sept 12, 2016 16:18:09 GMT
If I was doing it, I would create triggers for all (i.e. use the Trigger Enter & Trigger Exit events. Just make sure the collider width is equal to the max distance in the Audio Source if you want to be able to hear the entire range.
|
|
tom
New Member
Posts: 44
Posts: 44
|
Post by tom on Sept 12, 2016 18:26:48 GMT
OK, thanks, but does described by me scene have any risk? There is no complex graphics or complex algorithms, only I wonder on this amount of sounds.
I ask because it would be really tiring for me to build large scene, and more importantly modify it as expanding during the tests. Already I can see everything is starting to get complicated. It's getting more and more and more objects and FSMs.
My work with Unity is more like fun. If I build something that I can show the world it would be great, and if not there is no tragedy :-) Currently I am preparing -> learning the tools: Unity, PlayMaker and MasterAudio.
|
|
|
Post by DarkTonic Dev on Sept 12, 2016 19:22:06 GMT
If you do it with the Trigger Enter & Exit events it will be pretty safe and I think no problems. Otherwise I fear for the performance of playing 100 sounds at once. Especially since I think you said you have to have some of them as mp3's on a different thread. I think that's asking for trouble performance-wise. If you do all wav or ogg files maybe it would be ok, but I would play it safe and use the Trigger Enter & Exit events to not put such a burden on the engine.
|
|
tom
New Member
Posts: 44
Posts: 44
|
Post by tom on Sept 13, 2016 6:59:40 GMT
Hmmm, does it matter or not that the player will be approaching only a few objects sound at once? Up to a maximum of 10 at a time. So the rest of the sound will be out of reach? In such a case, the Auto-prioritization does not help?
|
|
|
Post by DarkTonic Dev on Sept 13, 2016 7:49:55 GMT
It matters only because of the performance overhead of playing multiple mp3s or other audio at once. Especially mp3s.
Even if only 10 are within max range Unity doesn't know that and will still process the audio, taking overhead.
If you do all uncompressed audio, you can give auto-prioritization a shot and see if you still get a good frame rate. Otherwise you can go the trigger route.
If you don't do all uncompressed audio you'll probably be forced to use triggers to limit the amount that play at once.
|
|
tom
New Member
Posts: 44
Posts: 44
|
Post by tom on Sept 13, 2016 10:28:59 GMT
OK, thanks!
|
|
|
Post by DarkTonic Dev on Sept 13, 2016 19:58:24 GMT
No problem.
|
|