SALSA LipSync with MasterAudio (Dark Tonic)

Overview

Our Master Audio (by Dark Tonic)
addon has been updated for SALSA LipSync v2 for Master Audio playlist and group functionality! This add-on includes helper scripts to leverage Master Audio's group and playlist functionality offering a method to drive dialog with the playlist functionality or enabled randomized dialog playback with the group functionality.

The asset package download contains two C# helper-scripts, one for integrating with Playlists, the other for integrating with Master Audio Groups.

PLEASE NOTE: Master Audio is an awesome, top-selling, top-rated Unity asset created by Dark Tonic and is not affiliated with, or supported by Crazy Minnow Studio. Please contact Dark Tonic Games for information about Master Audio.


Support

We (Crazy Minnow Studio) are happy to provide SALSA LipSync Suite-related support. However, we do not provide support for third-party assets. If you have problems getting the third-party asset working, please contact the asset's publisher for assistance.

NOTE: Please remember, the source is included for this free add-on and this should be considered example code that you can use to jump-start your project. It is not intended to fit all scenarios or requirements -- you are free to update it as necessary for your needs. We do provide limited support for all of our products; however, we do not make development changes to support specific project needs.

For SALSA LipSync Suite-related support, please email (assetsupport@crazyminnow.com) the following information:

  • Invoice number (support will not be provided without a Unity Invoice Number).
  • Operating System and version.
  • SALSA Suite version.
  • Add-on version (generally located in an associated readme or the script header comment).
  • Full details of your issue (steps to recreate the problem), including any error messages.
  • Full, expanded component screenshots (or video).
  • Full, expanded, associated hierarchy screenshots (or video).
  • Super helpful: video capture of issue in action if appropriate.

Requirements for This Example Implementation Tutorial

ATTENTION: These instructions require you to download and install the appropriate assets and/or add-on scripts into your Unity project. If you skip this step, you will not find the applicable option in the menu and/or component library.

NOTE: While every attempt has been made to ensure the safe content and operation of these files, they are provided as-is, without warranty or guarantee of any kind. By downloading and using these files you are accepting any and all risks associated and release Crazy Minnow Studio, LLC of any and all liability.


Installation Instructions

NOTE: For information on how to import/install Unity AssetStore packages or unitypackage files, please read the Unity documentation.

  1. Import SALSA LipSync into your project and please familiarize yourself with SALSA using the online documentation for SALSA LipSync.

  2. Import/install Master Audio (by Dark Tonic) and familiarize yourself with its use and requirements according to the third-party asset's instructions and operational guides.

  3. Import this SALSA LipSync v2 integration add-on and familiarize yourself with these instructions.

NOTE: While every attempt has been made to ensure the safe content and operation of these files, they are provided as-is, without warranty or guarantee of any kind. By downloading and using these files you are accepting any and all risks associated and release Crazy Minnow Studio, LLC of any and all liability.


Usage Instructions

Playlist Integration

The SALSA LipSync add-on asset listens for Master Audio's PlaylistController.SongChanged event and updates its AudioSource with the currently playing clip.

  • Download and import the Master Audio helper-script unitypackage into your project.
  • Add a Master Audio prefab to your scene via the Master Audio Manager window.
  • Setup a new playlist and add clips. NOTE: you may want/need to 'Override' the playlist's 'Crossfade Mode' and set the time to 0.
  • Add a Playlist Controller prefab to your scene via the Master Audio Manager window.
  • Configure the Playlist Controler GameObject to use the new playlist created in step #3.
  • Add SALSA LipSync to your GameObject.
  • Add SalsaMasterAudioPlaylist helper-script to the GameObject using SALSA (as shown in the screenshot).
    add-masteraudio-playlist
  • Choose whether to mute the Master Audio playlist (recommended).
  • Choose whether to autodetect (recommended), force, or ignore Playlist synchronization (see Release Notes section below)
  • Link the Playlist Controller (from step #4) to the helper-script's 'Playlist' slot.
  • Play your scene for some playlist-driven, lip-syncing goodness.

Groups Integration

Master Audio's PlaySoundResult is linked up with SALSA LipSync and when programatically accessed, Master Audio plays a clip from the group and SALSA is linked to the AudioSource Master Audio plays through.

NOTE: This implementation requires some sort of programmatic access to the public SalsaMasterAudioGroup.PlayDialog() method. Implementing this in your project is of personal design choice and is beyond the scope of support for this add-on and SALSA LipSync in general, see the API documentation below for reference. In the included example scene, a UGUI button is linked to call the method.

  • Download and import Master Audio, SALSA LipSync Suite, AND this add-on (SalsaMasterAudio) into your project.
  • Create and name your Master Audio Group(s) according to the Master Audio documentation.
  • Configure a character model with SALSA and confirm it is working.
  • Add SalsaMasterAudioGroup helper-script to the GameObject using SALSA (as shown in the screenshot).
    add-masteraudio-groups
  • Configure a way to call the group playback (i.e. a GUI button as in the demo scene)
  • Play the scene and invoke the PlayDialog() method (using step #5).

Master Audio Groups API Information

[SoundGroupAttribute] public string dialogSoundGroup

Set the appropriate group name.


public void PlayDialog()

Play a previously linked Master Audio Group. If no group is linked, throw a warning and exit.


public void PlayDialog(string soundGroup)

Set and play a Master Audio Group using SalsaMasterAudioGroup.PlayDialog().

Example:

SalsaMasterAudioGroup masterAudioGroupInstance;
string myGroupName = "myAwesomeNpcCharacterDialogGroup";
masterAudioGroupInstance.PlayDialog(myGroupName);

Troubleshooting and Operational Notes:

  1. Using Master Audio to drive/feed SALSA's lip-sync technology with audio clips has the side effect of both Master Audio and SALSA playing the same clip simultaneously. While this may not be perceptible on some systems, odds are it is not desirable whether it is audible or not. A boolean flag is now available that will mute the Master Audio Playlist. This is applied in Awake(), so changes during runtime will not affect script logic. However, this can be overridden at runtime, externally in other scripts or actions if desired.

  2. Master Audio's playlist synchronization feature may produce timing issues with SALSA's lip-sync audio clip timing . This effect will not be noticeable when using the "mute" feature (noted in item #1 above) and lip-synchronization itself is not affected. Master Audio Playlist Synchronization functionality is also supported in this helper script. There are two options available: "Autodetect Sync Mode" and "Force Sync Mode". Autodetect will check the current clip's SongFadeInPosition mode and if set to "Synchronize Clips", SALSA's AudioSource.time will be synchronized with the Master Audio Playlist's current AudioSource.time. If, for some reason, autodetect mode is not working correctly, use "Force Sync Mode" to indiscriminately force SALSA's AudioSource to synchronize with the Master Audio Playlist's AudioSource. NOTE: "Force Sync Mode" overrides the "autodetect" mode.


Release Notes:

NOTE: While every attempt has been made to ensure the safe content and operation of these files, they are provided as-is, without warranty or guarantee of any kind. By downloading and using these files you are accepting any and all risks associated and release Crazy Minnow Studio, LLC of any and all liability.

v2.0.0 - (2019-06-21):

+ Initial release for SALSA LipSync v2