Skip to content

Test Media and FFmpeg Live Publishing ​

Start here when you need a known source file before trying your own media. These are six-second synthetic test videos made only from FFmpeg color bars, a test pattern and a quiet generated tone. They contain no third-party footage or music. The repository includes scripts/generate_public_demo_media.sh so the files can be reproduced. They are small functional fixtures, not production-quality footage.

DownloadVideo / audioUse it to check
VR360 H.264 + AAC MP41024×512, 2:1, ERP chart, H.264 + AACFirst VR360 test, mouse/touch direction, audio, H.264 live publishing
VR360 HEVC + AAC MP41024×512, 2:1, same ERP chart, HEVC + AACHEVC VOD and VR360 fallback; browser HEVC support varies
Ordinary H.264 + AAC MP4640×360, 16:9, moving flat test pattern, H.264 + AACOrdinary VOD, seek, non-VR live playback

The VR360 chart labels FRONT, LEFT, RIGHT, TOP and BOTTOM. Its center is the default forward view. It is an ERP test chart, not a 360° camera recording. The sound is a low-level synthesized tone; keep the player muted until you intentionally test audio. The short files loop during live publishing, but their six-second duration makes them unsuitable for long-duration stability testing.

If clicking a file link plays it in the browser, right-click the link and choose Save Link As. Keep the downloaded filename used by the commands below, or update the command to match your filename.

1. Test local VOD first ​

Download the first file as media/vr360.mp4 beside the VR360 demo. Download the ordinary file as media/video.mp4 beside the VOD demo. Serve the demo directory over HTTP; do not open index.html with file://.

Or use the first download link above directly as the media URL; it is served by the GitHub-backed CDN, not your website server. projection: 'erp360' is needed only for the two ERP samples. The ordinary 16:9 video should stay flat.

Check the downloaded file before debugging the player:

bash
ffprobe -v error -show_entries stream=codec_name,width,height,sample_aspect_ratio -of compact ./media/vr360.mp4

2. Publish H.264 VR360 to ZLMediaKit ​

Start ZLMediaKit first. From the directory containing the downloaded MP4, run:

bash
# -re sends at real-time speed. -stream_loop -1 repeats this short test file.
# -c copy preserves the test video and audio; no re-encoding is needed.
ffmpeg -re -stream_loop -1 -i ./vr360-erp-h264-aac.mp4 \
  -map 0:v:0 -map 0:a:0 -c copy -f flv \
  rtmp://127.0.0.1/live/vr360

127.0.0.1 in the RTMP URL means the machine running FFmpeg. Replace it with the media server's address if FFmpeg runs elsewhere. The publishing command keeps running until you stop it.

Once ZLMediaKit shows live/vr360 as active, use one of these playback URLs from the browser's machine:

text
HTTP-FLV: http://127.0.0.1/live/vr360.live.flv
HLS:      http://127.0.0.1/live/vr360/hls.m3u8
WebRTC:   http://127.0.0.1/index/api/whep?app=live&stream=vr360

For VR360 playback, keep projection: 'erp360' in the VR360 demo and replace its MP4 URL with the chosen live URL. For WebRTC, start with H.264 because the browser must negotiate the codec. WHEP is the playback endpoint; it is not the RTMP publishing address. For RTMP-to-WebRTC timing, see the ZLMediaKit modify_stamp=1 note in Get Started. HLS requires server-side HLS output and normally has higher latency. A browser on another host cannot use 127.0.0.1 to reach your media server; cross-origin VR360 texture access also needs CORS permission.

3. Publish an ordinary live video ​

Use the flat sample and a different stream name, then open it with the live playback demo. Leave projection unset or set it to flat:

bash
ffmpeg -re -stream_loop -1 -i ./flat-h264-aac.mp4 \
  -map 0:v:0 -map 0:a:0 -c copy -f flv \
  rtmp://127.0.0.1/live/test
text
HTTP-FLV: http://127.0.0.1/live/test.live.flv
HLS:      http://127.0.0.1/live/test/hls.m3u8
WebRTC:   http://127.0.0.1/index/api/whep?app=live&stream=test

4. Optional HEVC live test and limits ​

If you specifically want to try HEVC VR360 live publishing, the generated HEVC file can be sent with the same stream-copy pattern:

bash
# Requires an FFmpeg FLV muxer and media server that both support HEVC-in-FLV.
ffmpeg -re -stream_loop -1 -i ./vr360-erp-hevc-aac.mp4 \
  -map 0:v:0 -map 0:a:0 -c copy -f flv \
  rtmp://127.0.0.1/live/vr360hevc

This is an optional compatibility experiment, not a promised WebRTC playback route. The HEVC MP4 is primarily a VOD fixture: successful MP4 playback does not prove the server supports HEVC-over-RTMP/FLV or that a browser can negotiate HEVC in WebRTC. Validate each route separately before claiming support. These files also do not test 8K texture limits, real camera stitching, ambisonic audio, or network jitter. No xinxiaomen file, song, or third-party VR footage is included in the public test set.