All Projects → Mukarillo → UnitySoundManager

Mukarillo / UnitySoundManager

Licence: MIT license
Sound manager with 3 tracks, language system, pooling system, Fade in/out effects, EventTrigger system and more.

Programming Languages

C#
18002 projects

Projects that are alternatives of or similar to UnitySoundManager

Audio cat dog classification
Classification of WAV files from cats and dogs
Stars: ✭ 16 (-70.91%)
Mutual labels:  sound, audio-processing
Linux Audio Adjustments
Audio Tweaks for Debian Based RPi
Stars: ✭ 140 (+154.55%)
Mutual labels:  sound, audio-processing
Simple-Unity-Audio-Manager
A decentralized audio playing system for Unity, designed for simplicity and built to scale!
Stars: ✭ 100 (+81.82%)
Mutual labels:  sound, unity3d-plugin
Spectrographic
Turn an image into sound whose spectrogram looks like the image.
Stars: ✭ 147 (+167.27%)
Mutual labels:  sound, audio-processing
collision-sound
Collision Sound aims to be an easy and powerful way of adding sound to object collisions in Unity
Stars: ✭ 21 (-61.82%)
Mutual labels:  sound, unity3d-plugin
sonopy
A simple audio feature extraction library
Stars: ✭ 72 (+30.91%)
Mutual labels:  sound, audio-processing
pydiogment
📣 Python library for audio augmentation
Stars: ✭ 64 (+16.36%)
Mutual labels:  sound, audio-processing
Img Encode
Encode an image to sound and view it as a spectrogram - turn your images into music
Stars: ✭ 157 (+185.45%)
Mutual labels:  sound, audio-processing
Triton
🐳 Scripps Whale Acoustics Lab 🌎 Scripps Acoustic Ecology Lab - Triton with remoras in development
Stars: ✭ 25 (-54.55%)
Mutual labels:  sound, audio-processing
gensound
Pythonic audio processing and generation framework
Stars: ✭ 69 (+25.45%)
Mutual labels:  sound, audio-processing
Sound-based-bird-species-detection
Sound-based Bird Classification - using AI, acoustics and ornithology to classify birds in the environment, an environmental awareness project (Web Application, Flask, Python)
Stars: ✭ 56 (+1.82%)
Mutual labels:  sound, audio-processing
AnotherBadBeatSaberClone
This is a discontinued but perhaps helpful VR project created during my Master's degree at FH Wedel.
Stars: ✭ 22 (-60%)
Mutual labels:  audio-processing
uos
United Open-libraries of Sound. United procedures for open-source audio libraries. For FPC/Lazarus/fpGUI/MSEgui.
Stars: ✭ 112 (+103.64%)
Mutual labels:  sound
dsp
DSP and filtering library
Stars: ✭ 36 (-34.55%)
Mutual labels:  sound
JHSoundWaveView
音波图,声波图
Stars: ✭ 22 (-60%)
Mutual labels:  sound
matchering-web
🎚️ Self-Hosted LANDR / eMastered Alternative
Stars: ✭ 25 (-54.55%)
Mutual labels:  sound
FPSCounter
FPS counter plugin for BepInEx - measure frame time and plugin performance
Stars: ✭ 27 (-50.91%)
Mutual labels:  unity3d-plugin
spafe
🔉 spafe: Simplified Python Audio Features Extraction
Stars: ✭ 310 (+463.64%)
Mutual labels:  sound
belaonurhead
Bela On Ur Head - head-tracking for binaural audio with Bela
Stars: ✭ 22 (-60%)
Mutual labels:  audio-processing
Realtime AudioDenoise EchoCancellation
No description or website provided.
Stars: ✭ 91 (+65.45%)
Mutual labels:  audio-processing

UnitySoundManager

Simple, yet powerful, sound manager for Unity with 3 tracks, language system, pooling system, Fade in/out effects, EventTrigger system and more.

Setup Project

setup To create an instance of SoundManager, click Time Saver Tools>Sound Manager> Add SoundManager. A GameObject will be created at root with SoundManager component.

Sound Manager Properties

properties

Use this forever: when checked, the GameObject won't be destroyed when changing scenes. Use this feature if you want to have only one instance of SoundManager through out the whole project.

Project FPS: This is used to calculate events and Fade-in/out effects. If you don't know the project fps, leave it at 60.

Use Pool Feature: when checked, an array of GameObjects will be created at editor time, avoiding instantiating at run time. If not checked, it will create a GameObject every time SoundManager.Play is called.

  • Pool Quantity: the quantity of game objects to be created. (Sound will only play if there is at least one available GameObject in the pool)

Use Multi-Language Feature : Use this if your project aims multi-language target. It will allow you to swap between languages while in run time. When creating the sounds, you can have multiple instances with the same name and different language, the Sound Manager will check the current language and use the right one.

Editing Channel Tracks

editingchannel

The Sound Manager has three channels: background, Effects and Voice. These are just their names and you can use them to whatever kind of sound you want.

Volume: You can setup the initial volume for the selected channel.

Play at start: This option is only available in the Background Channel. It allows you to setup the background music for each scene in your project (the scene must be added to Build Settings > Scenes In Build)

Adding Sound Clips

dragging

You have two options to add Sound Clip, first one would be clicking Add Sound and than setting the name, dragging the Sound Clip and setting the other parameters. The second choice is to drag one (or more) Sounds Clip to the "Drag here" area, their names and clips will be filled. If you put these sounds under folders which have names like: Background, Effects or Voice, the Track will be filled automatically for you, do the same thing for Language.

Sound Configuration Panel

conf1

1- Click the arrow to hide/show more options.
2- Sound name.
3- Click to preview the sound.
4- Click to stop previewing the sound.
5- The track that the sound belongs.
6- Click to delete the sound.

conf2

7- The audio clip.
8- Name (used to refer to this song in the source code).
9- Volume.
10- Loop toggle.
11- Fade in/out effects toggle.
12- Time to fade in/out.

conf3

3DSound: If the sound is not supposed to play 2d, check this toggle. Set the Vector3 to make the sound play at a coordinate or set the GameObject to make the sound follow the object; Track: Set the track this sound belongs. This will be useful to mute/un-mute groups of sounds. Language: Set the language of the sound. If you call SoundManager.Play with the name of this sound and the SoundManager.language is not the same as set here, the sound will not play.

conf4

Trigger Event: when checked, will try to call a function called OnSoundTrigger in all components attached in the Target GameObject. If Time is set to -1, the event will trigger at the end of the sound, if set to 0, the event will be triggered at the start of the sound.

Coding - Functions

SoundManager.AddSound

  • Description: Use this method to add sounds at run-time.

  • Parameters:

name type description
clip AudioClip The AudioClip of the sound
name String The name of the sound, used to reference it
soundTrack Track The track of the sound
language String The language of the sound
loop Bool If the sound loops or not
fadeIn Bool If the sound have fade in
timeToFadeIn Float Time for fade in
fadeOut Bool If the sound have fade out
timeToFadeOut AudioClip Time for fade out
is3D Bool If the sound is 3D
posFor3D Vector3 Position coordinate for the sound
isTrigger bool If the sound have event trigger
triggerTime float Time to trigger the event (-1 represents AudioClip.Length)

SoundManager.Play

  • Description: Use this method to play an audio clip at run-time.

  • Parameters:

name type description
name String This string is a direct reference to the created sound name
delay Float Set 0 if you want the sound to be played instantly, or set a delayed time
playAt Float Set 0 if you want the sound to be played at its start, or set a time to be played (in seconds)
stopAt Float Set -1 if you want the sound to be stopped at its end, or set a time to be stopped (in seconds)

SoundManager.Mute

  • Description: Use this method to mute an audio clip or track at run-time.

  • Parameters:

name type description
mute Bool Set to true if you want to mute and to false if you want to un-mute
clipName String The name of the audio clip that you want to mute/un-mute

or

name type description
mute Bool Set to true if you want to mute and to false if you want to un-mute
compareTrack Track The track that you want to mute/un-mute

SoundManager.Stop

  • Description: Use this method to stop an audio at run-time. Use this method only if you don't want resume the audio clip.

  • Parameters:

name type description
name String The name of the clip that you want to stop

SoundManager.StopAllSounds

  • Description: Use this method to stop all audios at run-time. Use this method only if you don't want resume the audio clip.

  • Parameters: no parameters

SoundManager.Volume

  • Description: Use this method to change the volume of an audio clip or track at run-time.

  • Parameters:

name type description
volume Float The volume to change, 0 means no sound and 1 means full volume
clipName String The name of the audio clip that you want to change volume

or

name type description
volume Float The volume to change, 0 means no sound and 1 means full volume  
compareTrack Track The track that you want to change volume

Coding - Variables

SoundManager.allMuted: returns true if all tracks are muted.

SoundManager.backgroundVolume: returns a float between 0 and 1 representing the background track volume. You can set the background volume in this variable also.

SoundManager.bkgMuted: returns true if background track is muted.

SoundManager.effectsVolume: returns a float between 0 and 1 representing the effects track volume. You can set the background volume in this variable also.

SoundManager.efxMuted: returns true if effects track is muted.

SoundManager.voiceVolume: returns a float between 0 and 1 representing the voice track volume. You can set the background volume in this variable also.

SoundManager.voiceMuted: returns true if voice track is muted.

SoundManager.fps: you can check or change the value of the manager fps.

SoundManager.language: you can check or change the value of the manager language.

Credits

This asset was created by Murillo Pugliesi Lopes. For more information, please contact me at: [email protected]
Feel free to clone and mess around. If you feel that you want to contribute, please submit a merge request :)

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].