Class SoundEvent

All Implemented Interfaces:
CinematicEvent, Savable
Direct Known Subclasses:
SoundTrack

public class SoundEvent extends AbstractCinematicEvent
A sound track to be played in a cinematic.
  • Field Details

    • path

      protected String path
    • audioNode

      protected AudioNode audioNode
    • stream

      protected boolean stream
  • Constructor Details

    • SoundEvent

      public SoundEvent(String path)
      creates a sound track from the given resource path
      Parameters:
      path - the path to an audio file (ie : "Sounds/mySound.wav")
    • SoundEvent

      public SoundEvent(String path, boolean stream)
      creates a sound track from the given resource path
      Parameters:
      path - the path to an audio file (ie : "Sounds/mySound.wav")
      stream - true to make the audio data streamed
    • SoundEvent

      public SoundEvent(String path, boolean stream, float initialDuration)
      creates a sound track from the given resource path
      Parameters:
      path - the path to an audio file (ie : "Sounds/mySound.wav")
      stream - true to make the audio data streamed
      initialDuration - the initial duration of the event
    • SoundEvent

      public SoundEvent(String path, boolean stream, LoopMode loopMode)
      creates a sound track from the given resource path
      Parameters:
      path - the path to an audio file (ie : "Sounds/mySound.wav")
      stream - true to make the audio data streamed
      loopMode - the loopMode
      See Also:
    • SoundEvent

      public SoundEvent(String path, boolean stream, float initialDuration, LoopMode loopMode)
      creates a sound track from the given resource path
      Parameters:
      path - the path to an audio file (ie : "Sounds/mySound.wav")
      stream - true to make the audio data streamed
      initialDuration - the initial duration of the event
      loopMode - the loopMode
      See Also:
    • SoundEvent

      public SoundEvent(String path, float initialDuration)
      creates a sound track from the given resource path
      Parameters:
      path - the path to an audio file (ie : "Sounds/mySound.wav")
      initialDuration - the initial duration of the event
    • SoundEvent

      public SoundEvent(String path, LoopMode loopMode)
      creates a sound track from the given resource path
      Parameters:
      path - the path to an audio file (ie : "Sounds/mySound.wav")
      loopMode - the loopMode
      See Also:
    • SoundEvent

      public SoundEvent(String path, float initialDuration, LoopMode loopMode)
      creates a sound track from the given resource path
      Parameters:
      path - the path to an audio file (ie : "Sounds/mySound.wav")
      initialDuration - the initial duration of the event
      loopMode - the loopMode
      See Also:
    • SoundEvent

      public SoundEvent()
      creates a sound event used for serialization
  • Method Details