Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chrome is supported h265 #744

Open
liusuyi2021 opened this issue Dec 11, 2024 · 12 comments
Open

chrome is supported h265 #744

liusuyi2021 opened this issue Dec 11, 2024 · 12 comments

Comments

@liusuyi2021
Copy link

Supported browsers
The server can ingest and broadcast with WebRTC a wide variety of video and audio codecs (that are listed at the beginning of the README), but not all browsers can publish and read all codecs due to internal limitations that cannot be overcome by this or any other server.

In particular, reading and publishing H265 tracks with WebRTC was not possible until some time ago due to the lack of browser support. The situation recently improved and can be described as following:

Safari on iOS and macOS fully supports publishing and reading H265 tracks

Chrome on Windows supports publishing and reading H265 tracks when a GPU is present and when the browser is launched with the following flags:
chrome.exe --enable-features=PlatformHEVCEncoderSupport,WebRtcAllowH265Receive,WebRtcAllowH265Send --force-fieldtrials=WebRTC-Video-H26xPacketBuffer/Enabled

Mediamtx already supports the H265 WebRTC protocol, can WebRTC streamer also support it

@mpromonet
Copy link
Owner

Hi @liusuyi2021

It might work using -o to forward encoded stream and -W to set trial fields.

Best Regards
Michel

@osenbal
Copy link

osenbal commented Jan 4, 2025

Hi @mpromonet

I'm trying to stream RTSP H265 Holowith CCTV in chrome browser with -o command. And i have check H265 codec in google chorme windows. But the stream wouldn't appear.

RTSP

here is the log on the webrts-streamer
WhatsApp Image 2025-01-04 at 10 55 20

if i missing something please let me know

@mpromonet
Copy link
Owner

Hi @osenbal

The support of h265 seems closed...
You could increase log level and check webrtc-internal to understand what fails.

Best Regards
Michel

@osenbal
Copy link

osenbal commented Jan 4, 2025

@mpromonet

So the problem is in browser (chrome) ?

this is the log verbose :

image

@mpromonet
Copy link
Owner

Hi @osenbal

problems may be in each layer, it may be in webrtc-streamer, in webrtc sdk, in javascript side, in browser....
about://webrtc-internals may helps too.

Best Regards,
Michel.

@osenbal
Copy link

osenbal commented Jan 4, 2025

@mpromonet so what should i do ?

I stuck in here, i have try with mediamtx and its working but they not provide components like webrtc-streamer

@mpromonet
Copy link
Owner

mpromonet commented Jan 4, 2025

Hi @osenbal

what means stuck... need to search ?

mediamtx seems to support WHEP and allow connection from a webbrowser, you might look to https://github.com/Eyevinn/whep-video-component, that is also compatible with webrtc-streamer.

Best Regards,
Michel.

@osenbal
Copy link

osenbal commented Jan 4, 2025

I tried to troubleshoot the issue with streaming H.265 RTSP with webrtc-streamer but got stuck.

I also attempted to use WHEP in webrtc-streamer to stream H.265 RTSP, but it didn’t work either.

@mpromonet
Copy link
Owner

Hi @osenbal

In commit 213f221 I added a check that format from backend is compatible with webrtc format.

Best Regards,
Michel.

@osenbal
Copy link

osenbal commented Jan 4, 2025

Have you tested with rtsp h265 with webrtc-streamer?

@mpromonet
Copy link
Owner

Hi @osenbal

using https://github.com/mpromonet/go-whep-play h265 frames from rtsp server are received through webrtc.

Best Regards,
Michel.

@osenbal
Copy link

osenbal commented Jan 5, 2025

Hi @mpromonet
I think i got the problem from log on new version 0.8.9

I noticed an issue in the Encode function related to the video format validation. Specifically, the error log:
format name must be {m_format.name} not {format.name}

WhatsApp Image 2025-01-05 at 07 36 47

maybe this is cause rtsp h265 cannot playing in thebrowser ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants