We are using a Linux based server so Apple’s tools (mediafilesegmenter) are not an option.
The HLS guidelines state:
…In addition, you should provide cellular-capable clients an alternate
stream at 64 Kbps or less for slower data connections. If you cannot
provide video of acceptable quality at 64 Kbps or lower, you should
provide an audio-only stream, or audio with a still image.
We want to give the “audio with a still image” option a go.
They have a implementation FAQ which advises using their tools, which worked well:
mediafilesegmenter -a --meta-file=imgres.jpeg --meta-type=picture sample.mp3
I see an image while the audio is playing on my iPhone. I looked at one of the segments which had some nonsense at the start which probably tells the player there is an embedded jpeg.
ID3 ?PRIV 5 com.apple.streaming.transportStreamTimestamp
ª†ID3 $APIC $u image/jpeg ˇÿˇ‡ JFIF ˇ€ Ñ &$/ #')8/-150*A&+,)
How do I make a audio only segment with this embedded image without using Apple’s tools?
The relevant documentation for how images are stored in the m3u file format is found in the M3U specification. The m3u8 format is a superset of m3u, so anything supported in m3u should be supported in m3u8 files.
Winamp can create m3u files with images in them. I’m sure there must be other tools capable of it. You would then have to add the appropriate tags to the m3u file to make it an m3u8 file. Or what may be easiest is just to copy part of the m3u file into your m3u8 file.