Learn Spark AR Studio

Everything you need to know to create an interactive augmented reality experience.

Clear
Back

Adding Audio to Your Effect

You can easily add sound to your effect using an asset called a playback controller, and an object called a speaker.

Once an audio clip is applied to a playback controller, and a playback controller is applied to a speaker, sound will be rendered in your scene.

Learn about:

Once you've added audio to your project, you can add interactivity and logic in the Patch Editor, or with scripting. You can also use audio effect patches to alter how your audio clips sound.

Before you start

Spark AR Studio supportss mono M4A files. Use files with a 44.1kHz sample rate and 16-bit-depth resolution, to make the size of the effect as small as possible but keep the quality. You can do this through a DAW or a program like iTunes.

Audio clips should be prepped. If you're converting ambient or music beds from stereo tracks to mono, convert to summed mono rather than dropping one of the tracks - to avoid losing elements of the audio file. Convert files to the lowest kbps possible, while testing clips through the device. We don't recommend going lower than 64kbps when converting to m4as.

You can choose from range of free audio clips in the AR Library.

Adding a continuous audio clip

1. Import an audio clip

First, import your audio clip into the Assets Panel:



2. Create an audio playback controller

Next, create a playback controller in the Assets Panel:



When a playback controller is selected in the Scene Panel, you'll see its properties in the Inspector.

3. Apply the audio clip to the audio playback controller

To make your audio clip play continuously, select the audio playback controller. In the Inspector:

  1. Click the dropdown next to Audio.
  2. Select your audio clip.


To make the sound play continuously, check the box next to Loop.

4. Insert and configure the speaker

Insert a speaker by clicking Add Object, and selecting Speaker.

Then, in the Inspector:

  1. Go to Audio. By default, it'll be set to None.
  2. Apply the playback controller you've added to the speaker.


You'll now have a continuous looping sound in your effect.

Audio playback controller properties

Audio

Apply an audio clip to the playback controller.

Play

Clicking the circle next to Play will create a patch in the Patch Editor. The patch can be used to play your audio clip based on a specific instruction.

Loop

Checking the box next to Loop will play the audio clip assigned to the playback controller continuously as soon as your effect is opened, without creating a patch.

Clicking the arrow next to Loop will create a patch in the Patch Editor. Your audio clip will loop continuously, based on a specific instruction.

Stop

Clicking the arrow next to Stop will create a patch in the Patch Editor. The patch can be used to stop your audio clip in response to a specific instruction.

Speaker properties

Visible

If you uncheck this box, the speaker will be hidden from the scene.

Audio

Add an audio clip from your computer, select a playback controller from the Assets panel or select the Microphone.

Volume

Adjust the volume level of the sound in the scene.

Transformations

Edit the position of the audio source in your scene.

Enable For

Choose the camera or cameras on a mobile device in which the audio should play.

Testing audio

It's best to test effects on a device throughout the creation process, using the Spark AR Player app.

When testing, check:

  • You can hear the sounds you've added.
  • Ambient sound plays during preview and playback, and sits below your voice in the mix.
  • There's no popping sound or gap when a sound loops.
  • Scripted sounds play when they're supposed to, and aren't startling or too repetitive.

Learn more

Join the Spark AR Creator's community

Find inspiration, see examples, get support, and share your work with a network of creators.

Join Community

Frequently asked questions

Have a specific question? Maybe it's been answered.


Read FAQs
Was this document helpful?