decentraland / decentraland/unity-explorer
Fix AudioAnalysis component returning no data for non-progressive (HLS) video streams
- Dominant language
- C#
- Stars
- 23
- Forks
- 17
- Avg merge
- 2d 16h
- Merged PRs (30d)
- 101
Description
### Build version
Not specified
### Issue Description
The `AudioAnalysis` SDK7 component receives no data when the video source is a non-progressive stream (e.g. HLS `.m3u8`). Audio from the stream is audible, but analysis values remain empty/zero — indicating the audio pipeline for HLS bypasses the source feeding `AudioAnalysis`.
Reference code (where the component is set up): https://github.com/decentraland/sdk7-test-scenes/blob/main/scenes/88%2C-10-audio-visualization/src/index.ts#L28-L32
### STR (Steps to Reproduce)
1. Download the test scene: https://github.com/decentraland/sdk7-test-scenes/tree/main/scenes/88%2C-10-audio-visualization
2. Change the `VIDEO_CLIP_URL` constant to a non-progressive HLS stream, e.g.:
```ts
const VIDEO_CLIP_URL = 'https://test-streams.mux.dev/x36xhzz/x36xhzz.m3u8'
```
3. Run the scene in the Explorer
4. Observe that audio from the HLS stream plays correctly
5. Observe that `AudioAnalysis` component receives no data / visualizer does nothing
### Expected Result
`AudioAnalysis` should receive audio data from the video stream regardless of whether it is progressive (MP4) or non-progressive (HLS), and drive the visualization accordingly.
### Actual Result with evidence
Audio is heard but `AudioAnalysis` returns no data — the visualization remains static. Reproduction index: 10/10.
### Reproduction
Always
### Operative system and additional Notes
macOS (may also affect other platforms — only tested on Mac)
---
Reported by Pravus
Requested by Dawid Krajewski (<@U079GRD9WTZ>)
Contributor guide
Research direction
Start with the AudioAnalysis setup in the referenced SDK7 test scene at scenes/88, -10-audio-visualization/src/index.ts, then reproduce the issue using the listed HLS VIDEO_CLIP_URL in the Explorer. Trace how audio from the HLS video reaches AudioAnalysis, comparing it with progressive playback. Done means analysis values are populated and the visualization responds for both MP4 and HLS sources.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp, typescript, unity
- Domain
- audio-video-rtc
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 55/100