Class default

Hierarchy

  • Soundpad
    • default

Constructors

  • Parameters

    • options: Partial<Options> = ...

    Returns default

Properties

connectionAwaiter: null | Promise<boolean> = null
isConnected: boolean

Methods

  • Parameters

    • name: string
    • parentCategoryIndex: number = -1

    Returns Promise<boolean>

  • Adds a sound to the sound list.

    Parameters

    • url: string

      full path and file name, e.g. C:\mysounds\sound.mp3

    Returns Promise<boolean>

    true on success

  • Adds a sound to the sound list.

    Parameters

    • url: string

      full path and file name, e.g. C:\mysounds\sound.mp3

    • Optional index: number

      The index to add the sound to in the default category.

    Returns Promise<boolean>

    true on success

  • Adds a sound to the sound list.

    Parameters

    • url: string

      full path and file name, e.g. C:\mysounds\sound.mp3

    • index: number

      The category to add the sound to.

    • insertAtPosition: number

      The index to add the sound to.

    Returns Promise<boolean>

    true on success

  • Parameters

    • dataDriver: ((query) => Promise<string>) = ...
        • (query): Promise<string>
        • Parameters

          • query: string

          Returns Promise<string>

    Returns Promise<boolean>

  • Returns void

  • Get the category tree.

    Parameters

    • Optional withSounds: boolean = false

      includes all sound entries of each category into the response

    • Optional withIcons: boolean = false

      base64 encoded PNGs

    Returns Promise<string>

    xml formatted category list

  • Get the category tree.

    Parameters

    • Optional withSounds: boolean = false

      includes all sound entries of each category into the response

    • Optional withIcons: boolean = false

      base64 encoded PNGs

    Returns Promise<Category[]>

    category list

  • Get a category identified by its index. Use getCategories to get the index.

    Parameters

    • categoryIndex: number
    • withSounds: boolean

      includes all sound entries associated to that category

    • withIcons: boolean

      base64 encoded PNG

    Returns Promise<string>

    xml formatted category list

  • Get a category identified by its index. Use getCategoriesJSON to get the index.

    Parameters

    • categoryIndex: number
    • withSounds: boolean

      includes all sound entries of each category into the response

    • withIcons: boolean

      base64 encoded PNGs

    Returns Promise<null | Category>

    category list

  • Returns Promise<string>

  • Returns duration of currently played sound file in milliseconds.

    Returns Promise<number>

  • Returns playback position of currently played sound file in milliseconds.

    Returns Promise<number>

  • Returns current recording peak.

    Returns Promise<number>

  • Returns recording position in milliseconds.

    Returns Promise<number>

  • Returns Promise<string>

  • Returns the total amount of sounds over all categories independent of currently selected category.

    Returns Promise<number>

  • Returns Promise<Sound[]>

  • Get a section of the sound list.

    Parameters

    • Optional fromIndex: number

      starts with 1

    • Optional toIndex: number

      the sound file at toIndex is included in the response

    Returns Promise<string>

    xml formatted sound list

    See

    getSoundlist()

  • Returns Promise<string>

  • Returns the version of Soundpad. Not the version of the remote control interface.

    Returns Promise<string>

  • Returns Promise<number>

    volume between 0 and 100.

  • Returns Promise<boolean>

    true if Soundpad is running and the remote control interface is accessible.

  • Returns Promise<boolean>

    true if the volume of the speakers is 0 or muted.

  • Returns Promise<null | boolean>

    true if the client is using the trial version, false if it is the full version or null if undermined.

  • Use negative values to jump backwards.

    Parameters

    • timeMillis: number

      e.g. 5000 to jump 5 seconds forward.

    Returns Promise<boolean>

  • Returns Promise<void>

  • Returns Promise<boolean>

  • Returns Promise<boolean>

    See

    playPreviousSound()

  • Play previous sound in the list. The play mode is the same as it was for the last played file. Means, if a sound was played on speakers only, then this function will play on speakers only as well.

    Returns Promise<boolean>

  • Returns Promise<boolean>

  • Let Soundpad play a random sound from any category.

    Parameters

    • renderLine: boolean

      set to true to play on speakers so you hear it.

    • captureLine: boolean

      set to true to play on microphone so others hear it.

    Returns Promise<boolean>

    true on success

  • Let Soundpad play a random sound from a particular category.

    Parameters

    • categoryIndex: number

      set to -1 to play a random sound from the currently selected category or use #getCategories(boolean, boolean) to find the index of a category.

    • renderLine: boolean

      set to true to play on speakers so you hear it.

    • captureLine: boolean

      set to true to play on microphone so others hear it.

    Returns Promise<boolean>

    true on success

  • Returns Promise<boolean>

  • Play a sound by index.

    Parameters

    Returns Promise<boolean>

    true on success

  • Play a sound by index.

    Parameters

    • index: number

      Get the index by calling getSoundlist first.

    • renderLine: boolean

      set to true to play on speakers so you hear it.

    • captureLine: boolean

      set to true to play on microphone so others hear it.

    Returns Promise<boolean>

    true on success

  • Let Soundpad play a sound from a particular category.

    Parameters

    • categoryIndex: number

      set to -1 to play a sound from the currently selected category or use getCategories to find the index of a category.

    • soundIndex: number

      it's not the index as used in playSound, but the position in the category, e.g. 5 = 5th sound in the category.

    • renderLine: boolean

      set to true to play on speakers so you hear it.

    • captureLine: boolean

      set to true to play on microphone so others hear it.

    Returns Promise<boolean>

    true on success

  • Redo last action. Same as Edit > Redo in Soundpad.

    Returns Promise<boolean>

  • Remove a category identified by its index. Use getCategories to get the index.

    Parameters

    • categoryIndex: number

      The index of the category to be removed.

    Returns Promise<boolean>

    true on success

  • Parameters

    • removeOnDiskToo: boolean = false

    Returns Promise<boolean>

  • Closes search panel.

    Returns Promise<boolean>

  • Shows file selection dialog if sound list was never saved before.

    Returns Promise<boolean>

  • Scroll down or up by this many rows. Use negative values to scroll upwards.

    Parameters

    • rows: number

    Returns Promise<boolean>

  • Scroll to a particular row.

    Parameters

    • row: number

    Returns Promise<boolean>

  • Uses Soundpad's instant search to highlight sounds.

    Parameters

    • searchTerm: string

    Returns Promise<boolean>

  • Jump to a particular position in the currently played sound.

    Parameters

    • timeMillis: number

      e.g. 5000 to jump to the 5th second of the sound.

    Returns Promise<boolean>

  • Select the category identified by its index. Use getCategories to get the index.

    Parameters

    • categoryIndex: number

      The index of the category to be selected.

    Returns Promise<boolean>

    true on success

  • Returns Promise<boolean>

  • Returns Promise<boolean>

    See

    selectPreviousHit()

  • Returns Promise<boolean>

  • Select previous search hit. Search is always wrapped. Means it starts again at the first hit if the last hit is reached.

    Returns Promise<boolean>

  • Select the sound at the given row in the list. This method was created before categories were introduced, as such the row is not the sound index, but the position in the currently selected category.

    Parameters

    • row: number

    Returns Promise<boolean>

  • Parameters

    • query: string

    Returns Promise<string>

  • Parameters

    • options: Partial<Options>

    Returns void

  • Change volume of the speakers.

    Parameters

    • volume: number

      a value between 0 and 100.

    Returns Promise<boolean>

  • Start recording. This call is handled the same way as if a recording is started by hotkeys, which means a notification sound is played. This is the default behavior, but the notification sound can be turned off in Soundpad.

    Returns Promise<boolean>

  • Start recording of the microphone. Method might fail if the speakers are currently being recorded. This call is handled the same way as if a recording is started by hotkeys, which means a notification sound is played. This is the default behavior, but the notification sound can be turned off in Soundpad.

    Returns Promise<boolean>

    true if recording was started or was already running

  • Start recording of the speakers. Method might fail if the microphone is currently being recorded. This call is handled the same way as if a recording is started by hotkeys, which means a notification sound is played. This is the default behavior, but the notification sound can be turned off in Soundpad.

    Returns Promise<boolean>

    true if recording was started or was already running

  • Returns Promise<boolean>

  • Returns Promise<boolean>

  • Mutes or unmutes speakers in Soundpad.

    Returns Promise<boolean>

  • Returns Promise<boolean>

  • Undo last action. Same as Edit > Undo in Soundpad.

    Returns Promise<boolean>

  • Parameters

    • status: PlayStatus = PlayStatus.STOPPED

      The status to wait for (default: STOPPED)

    • pollInterval: number = 100

      The interval to poll the status (default: 100ms)

    Returns Promise<void>

    A promise that resolves when the status is reached