audio-video

Implement AudioSource, AudioStream, and VideoPlayer in Decentraland SDK7 scenes.

3|Updated Apr 13, 2026
One-click install
npx skills add https://github.com/decentraland/sdk-skills --skill audio-video-decentraland
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: audio-video
Source: https://github.com/decentraland/sdk-skills/tree/main/audio-video
Command: npx skills add https://github.com/decentraland/sdk-skills --skill audio-video-decentraland

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Integrating audio and video in Decentraland scenes is complex, requiring correct component usage, texture setup, and permission handling to deliver reliable media playback.

Core Features & Use Cases

  • AudioSource supports local files with spatial audio and pitch control for responsive sound effects and ambient music.
  • AudioStream enables streaming audio from external URLs with non-spatial playback and state polling for UI feedback.
  • VideoPlayer renders video on meshes or GLTF surfaces; it uses a Video Texture mapped to a mesh material.
  • VideoState events and AudioStream state monitoring allow reactive scene behavior and UI updates.
  • Spatial controls such as spatialMinDistance and spatialMaxDistance customize how media attenuates with distance.
  • Permissions pattern for external media: ALLOW_MEDIA_HOSTNAMES and allowed hostnames to securely load remote media.

Quick Start

Configure an AudioSource, AudioStream, or VideoPlayer in your scene by following the usage patterns described.

Frequently Asked Questions about audio-video

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I add audio and video to Decentraland SDK7 scenes?

To add audio and video to Decentraland SDK7 scenes, configure AudioSource, AudioStream, or VideoPlayer components. VideoPlayer requires mapping a Video Texture to a mesh material, while audio components require setting spatial controls for distance-based attenuation.

What's the best way to stream external audio in a Decentraland scene?

Streaming external audio in a Decentraland scene is best handled using the AudioStream component, which enables non-spatial playback from external URLs. You must configure ALLOW_MEDIA_HOSTNAMES permissions for allowed hostnames to securely load remote media.

Do I need permissions to load remote media in Decentraland?

Yes, loading remote media in Decentraland requires configuring ALLOW_MEDIA_HOSTNAMES permissions. You must explicitly specify allowed hostnames in your scene to securely authorize external audio streams and video playback.

Can I play local audio files with spatial distance control in Decentraland?

Yes, you can play local audio files with spatial distance control in Decentraland using the AudioSource component. It supports spatialMinDistance and spatialMaxDistance settings to customize how audio attenuates with distance.

How does video rendering on meshes work in Decentraland SDK7?

Video rendering on meshes in Decentraland SDK7 works by using the VideoPlayer component to render video onto GLTF surfaces. The video output is mapped as a Video Texture to a mesh material, allowing multi-surface sharing.

Why is my external audio stream not playing in my Decentraland scene?

External audio streams not playing in Decentraland scenes often result from missing ALLOW_MEDIA_HOSTNAMES permissions. Ensure your scene explicitly allows the target hostnames and polls the AudioStream state for UI feedback.