Welcome Guest Search | Active Topics | Sign In | Register

VP9/WebM Hardware/GPU support in WebBrowser Options
Zetadisplay Norway AS
Posted: Thursday, September 19, 2019 8:14:55 AM
Rank: Member
Groups: Member

Joined: 9/30/2015
Posts: 16
We are playing large (>4k vides) with WebBrowser, and it seems hardware acceleration is not enabled for webm at least.

It seems to works fine for h264, and has marginally more resource usage than chrome (might be because we use efficient crf encoding)
But for webm we max out cpu in WebBrower, but in chrome it uses almost no cpu.

Is hw video decoding enabled in WebBrowser, for h264 or webm?

In case not, can you add this?
eo_support
Posted: Thursday, September 19, 2019 4:37:25 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,067
Hi,

We do not do anything specifically about video decoding or hardware acceleration. So if the browser engine is capable of using hardware acceleration for WebM, then it should use it (unless you explicitly turned GPU off). As such this maybe related to the version of the Chromium browser engine we use. We will refresh our browser engine soon so you can check again after we update the engine and we can then go from there.

Thanks!
Zetadisplay Norway AS
Posted: Thursday, September 19, 2019 5:57:40 PM
Rank: Member
Groups: Member

Joined: 9/30/2015
Posts: 16
I am testing with the your latest version, and it behaves as if "Hardware-accelerated video decode" is set to disabled in chrome://flags for chrome.

Your latest version is based on chrome 70, and I doubt that this version lacks hw video decode, but I can try to find an old chrome and verify...

You probably won't notice unless you have a demanding video to decode, I can provide a 1 gig 4320x3840 60MBit/s 50fps webm video for you to test, where the cpu is aroung 70% in WebBrowser on my workstation, and close to nothing in chrome.
eo_support
Posted: Thursday, September 19, 2019 6:21:02 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,067
Even if we can see the problem there isn't much we can do about it ---- due to the enormous size of the browser engine, we are not in a position to dig into the browser engine to find what's wrong with a specific video format or add a format that wasn't already working.

To quickly verify whether GPU is enabled, you can run the page, then use task manager to check all the command line arguments of rundll32.exe or eowp.exe process in the task manager. If you see one with --type=gpu_process, then GPU is being used. If you do not see any, then either because you have explicitly disabled it, or because somehow the GPU process wasn't initialized properly (such as unsupported hardware). If that's the case, you can try to use our TabbedBrowser sample application to see if you see the same problem.
Zetadisplay Norway AS
Posted: Thursday, September 19, 2019 7:15:32 PM
Rank: Member
Groups: Member

Joined: 9/30/2015
Posts: 16
There is a gpu process... but in EO WebBrowser this only has the type --type=gpu_process,
but when using chrome this process also has an additional --type=renderer, and different --gpu-preferences.

btw, there is also a gpu process when setting EngineOptions.DisableGPU = false;

HW video decoding is working in CEF, but I must find an old version to verify how this is working with chromium 70.

I guess the setting in EO is for GPU rasterization, but the hw video decodeing might be a different setting not exposed in your api.
Zetadisplay Norway AS
Posted: Friday, January 17, 2020 8:08:11 AM
Rank: Member
Groups: Member

Joined: 9/30/2015
Posts: 16
Now tested in new version basen on chrome 77, still same problem... Works fine in Chrome and also in CEF, no hw decode in EO.WebBrowser...
eo_support
Posted: Friday, January 17, 2020 3:57:46 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,067
Hi,

Please check if you have enabled proprietary codecs:

https://www.essentialobjects.com/doc/webbrowser/advanced/html5.aspx

These codecs are disabled by default.

Thanks!
Zetadisplay Norway AS
Posted: Friday, January 17, 2020 4:06:27 PM
Rank: Member
Groups: Member

Joined: 9/30/2015
Posts: 16
Yes it's enabled. Webm is not proprietary , so it's allways enabled, but we need to set this to use h264...
eo_support
Posted: Friday, January 17, 2020 4:14:24 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,067
I am not sure what else we can tell you. If you can provide a test Url we will be happy to investigate further.
Zetadisplay Norway AS
Posted: Friday, January 17, 2020 5:20:24 PM
Rank: Member
Groups: Member

Joined: 9/30/2015
Posts: 16
http://distributortst2.sys.prontotv.no/webmedia/test.webm

As noted above, EO.Webbrowser behaves as if "Hardware-accelerated video decode" is set to disabled in chrome://flags
eo_support
Posted: Monday, January 20, 2020 8:53:30 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,067
Hi,

We have debugged into Chromium's source code on this issue and we do not see any hardware accelerated code path for this video. This video is encoded in VP9 and belows are a few key files related to VP9 decoding:

https://cs.chromium.org/chromium/src/media/filters/vpx_video_decoder.cc
https://cs.chromium.org/chromium/src/third_party/libvpx/source/libvpx/vpx/src/vpx_decoder.c
https://cs.chromium.org/chromium/src/third_party/libvpx/source/libvpx/vp9/vp9_dx_iface.c

We do not see any hardware involved in these files. We also tested the same file on Google Chrome browser and we see similar CPU spike and no GPU being used. The main source of the CPU spike is the high video resolution, which is 4320 by 3840. This is 8 times of the data of a typical 1080p HD video stream and twice the regular 4K video.

Thanks
Zetadisplay Norway AS
Posted: Monday, January 20, 2020 9:17:32 AM
Rank: Member
Groups: Member

Joined: 9/30/2015
Posts: 16
That probably means you tested it on a gpu not supporting webm hw decode... Both out customers and ourselves has verified chrome to use hw decode for this file...
Here are som screenshots from my desktop, which supports hw decode...

http://distributortst2.sys.prontotv.no/webmedia/hwdecode.png

http://distributortst2.sys.prontotv.no/webmedia/swdecode.png

You can see that the first link uses gpu video decode and very little cpu, as opposed to the last...


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.