Package org.collebol.engine.audio
Class Sound.SoundBuilder
java.lang.Object
org.collebol.engine.audio.Sound.SoundBuilder
- Enclosing class:
Sound
The SoundBuilder class is used to construct
Sound objects with specific properties.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionpitch(float pitch) refDistance(float refDistance) rollOffFactor(float factor) volume(float volume)
-
Constructor Details
-
SoundBuilder
SoundBuilder constructor.- Parameters:
id- the unique id of the sound.path- the path to the sound file.
-
-
Method Details
-
volume
- Parameters:
volume- default volume of the source.- Returns:
- instance
-
pitch
- Parameters:
pitch- default pitch of the source.- Returns:
- instance
-
refDistance
- Parameters:
refDistance- default the distance where you can hear the sound at full volume.- Returns:
- instance
-
rollOffFactor
- Parameters:
factor- default float how fast the volume decreases.- Returns:
- instance