Skip to the content
Hotspots and media

Add narration or sound to a hotspot

Add a sound to a hotspot with Audio Narration: Play/Pause places it by direction, Popup Player is a plain player. What the player does when visitors move on.

Guide5 min read Updated

On this page

The short answer

To add a sound, open the Hotspots tab, click Add Infotation, choose the Variant Audio Narration (Play/Pause) and set the Audio File URL (.mp3, .wav). A visitor clicks the badge to play the sound. The sound is placed in the direction of the badge, so its direction changes as the visitor turns the view. It plays once, and stops when the visitor moves to another scene. Audio Narration (Popup Player) is a plain audio player in a panel, with no direction.

Who can do it

  • The owner, and collaborators whose role includes the Hotspots Tab and the Panoramrs Tab: Editors and Admins by default.
  • Audio Narration (Play/Pause) is in both views. Audio Narration (Popup Player) is in the Advanced view.
  • Any plan. An audio file you upload is limited by the tour owner's plan to 10 MB on Free, 50 MB on Pro, 50 MB on Agency and 50 MB on Enterprise.

Add a sound

  1. Open the tour, click the Hotspots tab and click the scene where the sound belongs.
  2. Click Add Infotation, then click the picture where the badge should sit. Put it where the sound comes from: the direction of the badge is the direction of the sound.
  3. Under Variant choose Audio Narration (Play/Pause).
  4. In Audio File URL (.mp3, .wav) paste an address, or click Browse. The picker is headed Select an audio file. It lists your audio files, with Upload new to add one. It takes .mp3 and .wav files only.
  5. Open the Preview tab and click the badge. The editor does not play sound: clicking a badge there selects it.

The two variants

Variant Fields What visitors get
Audio Narration (Play/Pause) Audio File URL (.mp3, .wav) A badge with the tour's audio icon. A click plays the sound, and a click while it plays pauses it. After it ends, a click plays it again
Audio Narration (Popup Player) Audio File URL (.mp3, .wav), Title, Description / Content A badge that opens a panel with your text and a standard audio player. The sound has no direction

What the player does with Play/Pause

  • It starts on a click. Nothing plays when a visitor enters the scene.
  • It plays once. There is no loop and no background music. Each hotspot has its own file, and starting one does not stop another.
  • It is placed by direction. The player uses the browser's Web Audio with HRTF panning and puts the sound in the direction of the badge. The sound sits at a fixed distance, so it does not fade with distance, but by the Web Audio formula it also plays at about a tenth of the file's own loudness, and there is no volume setting: prepare the file loud and clear. The Popup Player plays at the file's own loudness.
  • It stops when the visitor changes scene. The sound pauses and goes back to the start. Coming back does not restart it.

The Popup Player is different. Closing its panel does not pause it: use its own pause button first. Leaving the scene pauses it, and coming back resumes it if it was playing.

What the file needs

To place a sound the player requests the file in the browser's cross-origin mode (CORS). Its code notes that placing the sound fails when the file's server does not allow that. When the player cannot hook the file, it writes Spatial Audio: Failed to hook media element. (CORS issue?) in the browser's console. Pick or upload the file with Browse: Panoramr stores it for you.

On the live site the tour's page tells browsers where it may load things from, and sounds may come from Panoramr's own addresses and storage. A sound linked from another website stays empty.

Scenes with a heading

The player turns the view by a scene's heading but places the sound at the badge's own direction. A scene gets a heading when you click Set Position in Calibrate Radar on a floor plan (floor plans). On such a scene the sound can seem to come from the wrong side.

When visitors hear it

A save refreshes the stored copy that visitors get, unless the tour has Draft Workflows on: then they hear it after you click Publish Changes (my changes do not show).

Troubleshooting

Nothing plays when I click the badge in the editor. The editor does not play sound. Use the Preview tab.

Nothing plays in Preview or for visitors. Check that Audio File URL (.mp3, .wav) has an address and that the file is an MP3 or a WAV. Check that the file is stored by Panoramr (see above). Open the browser's console and look for the Spatial Audio: message.

The picker says "name" is not a file the library takes. It takes .mp3, .wav. Choose an .mp3 or .wav file. A file over your plan's limit gets "name" is N MB, over the M MB limit for one file.

The sound comes from the wrong side. See the section on scenes with a heading.

The sound stops when I go to the next scene. That is how Play/Pause works. Visitors click the badge again in the new scene.

I want a sound that loops, or music behind the whole tour. Panoramr does not offer one.

Was this article helpful?