h265 encoding -> HLS playback on Safari

I’m using the gstreamer nvv4l2h265enc encoder (have tried omxh265enc as well) to encode h265 video. It plays back fine in VLC, but somehow I can’t get it to play correctly in Safari as an HLS.

Using the exact same GStreamer pipelines, except encoding using the standard x265enc encoder, everything works perfectly.

Any known issues with the hardware h265 encoder?


We have verified H264 in the following two posts:

The key point is to enable AU delimiter. Please also enable ‘insert-aud’ in nvv4l2h265enc and try again.

Thanks for the response! I’ve done a lot of experimenting (and reading) and did indeed try insert-aud. It helps (it is necessary) but it doesn’t fix all of the issues:

In this case the HLS stream starts correctly, but seems to break at segment boundaries, which makes me think that it is some sort of time-stamp issue. I’ve also tried some of the other options like “insert-sps-pps”.

The exact same pipelines work correctly for nvv4l2h264enc and x265, so I assuming something specific to nvv4l2h265enc…

Thanks again for the help. Any other suggestions for things I can try?

Looks not expected that ‘insert-sps-pps’ does not help. Please share the pipeline so that we can reproduce the issue. Are you on r32.2?

Hi Dane. Yes, I am on 32.2.1.

I will do my best to come up with a self-contained repro. For now I can tell you that I have two pipelines. The first encodes as follows:

src -> nvvidconv -> nvv4l2h265enc -> h265parse -> matroskamux -> filesync

The pipeline that does the HLS takes the output from above like so:

src -> matroskademux -> h265parse -> mp4mux -> hlssink

Thanks again.