Forum Discussion

johnmarsden's avatar
10 years ago

How to specify format for item in "Streams" content metadata

Content Meta-data has the "StreamFormat" which allows me to set HLS vs MP4.

I'm using the "Streams" array to specify videos. Some are MP4, some are HLS.. so the StreamFormat has to be set on each item, not across the board. I don't see it listed in the docs unless I'm overlooking something.

I tried

{
url : m.url
format : m.stream_format
streamFormat: m.stream_format
quality : true
}


But I still get errors when trying to play the videos unless I set the static "StreamFormat" key. Is there a way to do this?

1 Reply

  • You can't mix formats within a single content-meta-data. All the renditions in your streams array must have the same format.

    Further, with HLS you should never have more than 1 stream item in the content-meta-data since the different bitrate variants are defined in the HLS manifest.