H265 Unifi Protect Stream Severe Stuttering

Hi all,

I’ve had 4 cameras running in Unifi Protect for a while and all was working connected to HAOS (HAOS is running as a VM in a Hyper-V host and has been assigned 4 cores and 8GB memory). I recently had one of the cameras die so I replaced it with a newer one that has “enhanced” encoding (I believe this means H265). I noticed that when using this H265 encoding, the camera is choppy and only displays at a rate of ~2fps. If I switch the encoding back to “standard” (H264) the stuttering goes away completely.

When viewed through Chrome on my Macbook Pro, it stutters. When viewed in Safari, it’s perfect…even with the “enhanced” so the issue appears to be with Chrome.

If all I was doing was viewing on my Mac then I’d be fine but I have a number of devices that will use Chrome as their browser, namely a wallpanel I setup using an 18" touchscreen mounted on the wall with an Intel N95 miniPC that includes the N95CPU and the UHD600 integrated graphics that support H265 encoding/decoding.

I’m using the Picture Entity card with the following…

show_state: false
show_name: false
camera_view: live
type: picture-entity
camera_image: camera.front_door_high_resolution_channel
entity: camera.front_door_high_resolution_channel

I also have the following in my configuration.yaml file…

#ffmpeg
ffmpeg:

I’ve searched the community here for insights as to what may be happening and how to fix but my google-fu is failing me today. I’m hoping someone here has already found a solution and can share it with me.

I am having the same issue, though I also get severe stuttering in the HA companion app (I am using Android). Did you ever find a solution?

Unfortunately, I’ve not been able to resolve this. I could go back to H264 but the nearly 4X increase in storage requirements is just stupid so I’m not willing to do that. I’ve instead tried to setup a 720P lower resolution RTSP stream and use that in the camera view but that’s still in H265 so despite the lowered resolution, it severely stutters.

Until someone can find a fix or I replace my camera system, I suppose I’m stuck with this.

Thanks for replying. That’s interesting, doesn’t make sense why it works so poorly with H265 enabled. I am running HA on a Raspberry Pi 4 with 8GB bare metal with nothing else on the Pi. When I load up a Protect stream, the CPU hovers around 8-10%. The Pi 4 supports H265 decode for 4K streams to 60fps, so it’s not a hardware issue. I asked on the Ubiquiti Discord as well, I’ll see if anyone else chimes in and let you know.

Let me know if you find a fix.

Same here. Fresh install of HAOS, a few UniFi cams, the ones with “Enhanced” stutter. and the Standard streams do not. It looks like it just does an expensive frame grab every second when streaming enhanced.

I examined the rtsp streams in VLC and confirmed that standard is h264 and enhanced is h265. Odd since this is 2025 and h265 decoding should be… ubiquitous.

2 Likes