Log in

View Full Version : HEVC and HLS Streaming


x265_Project
10th November 2017, 19:53
Are you streaming HEVC? Are you planning to? Add your voice to Streaming Media's survey, to help to drive support for HEVC streaming. http://app.surveymethods.com/EndUser.aspx?BA9EF2EABDF9EDEEBE

hajj_3
11th November 2017, 11:25
If people are going to start using h265 then surely they would use DASH?

Blue_MiSfit
11th November 2017, 19:40
You must use HLS on Apple devices, especially if you need DRM

FranceBB
11th November 2017, 23:06
The player we rely to (Fluid Player) doesn't support HEVC (yet).
We contacted them about whether they will add support or not in the future, and they said that they don't know.
Unfortunately we can't change the player due to ads compatibility and partnership, so we have to encode everything in H264 8bit,
but we will stream in HEVC 10bit as soon as the player we rely to will support it.

Blue_MiSfit
13th November 2017, 02:56
Yeah, HEVC support in-browser is entirely up to the browser via MME. As of today only Edge and Safari have HEVC decode capability. Not sure if you were talking about a JavaScript based browser player, or a native player.

Native players can do whatever they want, but there's probably licensing costs involved for HEVC.

TEB
7th December 2017, 01:28
Anyone know if the newer players for HEVC support anykind of VBR decode? How is VBR signalled in the manifests? Avg bitrate ?

Blue_MiSfit
7th December 2017, 04:41
VBR? That's literally no problem at all. In fact, it's best practice, as long as you're sane and use something like maxrate = 110% - 150% of bitrate.

As for how it's signaled, please see the following:

https://tools.ietf.org/html/rfc8216#section-4.3.4.2

TEB
8th December 2017, 08:00
VBR? That's literally no problem at all. In fact, it's best practice, as long as you're sane and use something like maxrate = 110% - 150% of bitrate.

As for how it's signaled, please see the following:

https://tools.ietf.org/html/rfc8216#section-4.3.4.2

Nice! Thx for the url!

For the sake of the discussion, how would one utilize CRF encoded streams in a HLS and DASH environment? CRF 20 for instance can give great peaks, but the total quality and overall bandwith is very good.
One can ask as if why!! one should use it, well we have a FTTH only network and a STB that supports both IPTV (rtsp or mc mpeg2ts) + Dash..
Based on my internal tests of various content compared with SSIM/PSNR, CRF without limits gives a better bang for the buck than 2pass avg bitrate and limited CRF (vbv buffer max, avg)..

Blue_MiSfit
10th December 2017, 03:20
Well sure, but good luck streaming unrestricted CRF.

Most either do CBRish VBR like maxrate = 1.1 or 1.5 * bitrate and bufsize = 2 * bitrate
OR they use capped CRF. Picking appropriate CRF values is a bit tricky though, and IMO the benefits here are probably small unless you're operating at Netflix scale.

Don't ever use CBR though unless you absolutely have to. You'll have transient quality issues, especially since ABR streaming typically uses lots of keyframes (2 second GOPs are quite common)

Golgot13
10th December 2017, 16:37
H265 over HLS (HLS with TS) work nicely, I made first last year (2016): most Android phone with H265 hardware decode chipset play the stream directly on Chrome
For iOS, for hardware decode you need HLS fMP4 version and last iOS device (> iPhone 7)

About bitrate, Live TV channels with H265 MP 1920x1080P 1Mbps/1.5Mbps are very nice (1920x1080P50 need 1Mbps for TV news, but for sport channel it need 1.7Mbps)
About HLS fMP4, GPAC team has got the best tool (both MPEG DASH and HLS in Live or VoD)

RDO is a killer codec (VP9 in live mode today can do nothing), like CABAC and VC1
It will be hard for AV1

TEB
12th December 2017, 23:41
Well sure, but good luck streaming unrestricted CRF.

Most either do CBRish VBR like maxrate = 1.1 or 1.5 * bitrate and bufsize = 2 * bitrate
OR they use capped CRF. Picking appropriate CRF values is a bit tricky though, and IMO the benefits here are probably small unless you're operating at Netflix scale.

Don't ever use CBR though unless you absolutely have to. You'll have transient quality issues, especially since ABR streaming typically uses lots of keyframes (2 second GOPs are quite common)

So for OTT/ABR, would u recommend VBV buffer constrained CRF or 2 pass VBR with limits?

TEB
12th December 2017, 23:44
Well sure, but good luck streaming unrestricted CRF.

Most either do CBRish VBR like maxrate = 1.1 or 1.5 * bitrate and bufsize = 2 * bitrate
OR they use capped CRF. Picking appropriate CRF values is a bit tricky though, and IMO the benefits here are probably small unless you're operating at Netflix scale.

Don't ever use CBR though unless you absolutely have to. You'll have transient quality issues, especially since ABR streaming typically uses lots of keyframes (2 second GOPs are quite common)

Anyone started to use 4sec segments yet?

Blue_MiSfit
13th December 2017, 02:33
6 second segments are recommended by Apple for HLS, and the Bitmovin guys found that 4 second chunks have the best throughput for most DASH clients.

TEB
13th December 2017, 09:41
6 second segments are recommended by Apple for HLS, and the Bitmovin guys found that 4 second chunks have the best throughput for most DASH clients.

Ah! Would one then do a 4 sec gop ? Or 2 sec gop to align with 6 sec segments in combination with 4 sec segments? (i have to support HLS and Dash from the same fmp4 mezz files)

Blue_MiSfit
14th December 2017, 06:40
2 second GOPs are pretty standard, that way you can easily package your content for both standards (and Smooth Streaming if you still need to make it ;))

kabelbrand
14th December 2017, 21:11
2 second GOPs are pretty standard, that way you can easily package your content for both standards (and Smooth Streaming if you still need to make it ;))
Speaking of Smooth Streaming is someone able to point me in the right direction how to get the client manifests CodecPrivateData for H.265?

Blue_MiSfit
15th December 2017, 07:57
Uh.. actually yeah forget I said anything about Smooth. I don't think you can deliver HEVC over it. Brainfart :)

kabelbrand
15th December 2017, 10:18
Uh.. actually yeah forget I said anything about Smooth. I don't think you can deliver HEVC over it. Brainfart :)
I thought so too but it seems there are embedded devices out there that support H.265 with Smooth Streaming. Not sure about additional DASH support...

Got this example of a client manifest:
<SmoothStreamingMedia MajorVersion="2" MinorVersion="2" TimeScale="10000000" Duration="112800000">
<StreamIndex Type="video" QualityLevels="3" TimeScale="10000000" Name="video" Chunks="6" Url="QualityLevels({bitrate})/Fragments(video={start time})" MaxWidth="3840" MaxHeight="2160" DisplayWidth="3840" DisplayHeight="2160">
<QualityLevel Index="0" Bitrate="2500000" CodecPrivateData="010160000000B0000000000078F000FCFDF8F832004B03A00001002340010C01FFFF016000000300B000000300000300781486030000030001000003003250A10001003D420101016000000300B00000030000030078A00280802D16C521A490A50BC05A8080808A00000300020000030064C13824DC00098960004C4BFC91C350A2000100084401C172F692FB24" MaxWidth="1280" MaxHeight="720" FourCC="hvc1"/>
<QualityLevel Index="1" Bitrate="4500000" CodecPrivateData="010160000000B000000000007BF000FCFDF8F832004B03A00001002340010C01FFFF016000000300B0000003000003007B1486030000030001000003003250A10001003C420101016000000300B0000003000003007BA003C08010E5B14869242942F016A020202280000003008000001930D6093700044AA0008957F2470E40A2000100084401C172F69BFB24" MaxWidth="1920" MaxHeight="1080" FourCC="hvc1"/>
<QualityLevel Index="2" Bitrate="15000000" CodecPrivateData="010160000000B0000000000099F000FCFDF8F832004B03A00001002340010C01FFFF016000000300B000000300000300991486030000030001000003003250A10001003F420101016000000300B00000030000030099A001E020021C5B14869242942F016A020202280000030008000003019304E09370000E4E180007270FF3C78F40A2000100084401C172F69BFB24" MaxWidth="3840" MaxHeight="2160" FourCC="hvc1"/>
<c t="0" d="20000000" r="5"/>
<c d="12800000"/>
</StreamIndex>
</SmoothStreamingMedia>

benwaggoner
15th December 2017, 18:21
You must use HLS on Apple devices, especially if you need DRM
HLS manifest, yes. But HEVC DRM requires fMP4, and not .ts fragments. Thank goodness!

Still, DRM is incompatible between FairPlay HLS and PlayReady DASH, so we don't have a universal DRM media package format yet.

TEB
15th December 2017, 22:41
Well.. if one forget about smooth, and focus on HLS and Dash, with playready 4.0, widevine and IOS 10+ version of HLS/FP will all support AES-CENC CBC over fmp4 if im not mistaken..
So all in all that will give us one storage format and one crypto format with different key sets..
but i might be mistaken..

Blue_MiSfit
16th December 2017, 00:39
And absolutely zero client support, right?