About offscreen and onscreen speed

Having problems with building or using CEF's C/C++ APIs? This forum is here to help. Please do not post bug reports or feature requests here.

About offscreen and onscreen speed

Postby DunDunW » Wed Nov 15, 2023 12:16 am

My goal is to render the web as a video stream on linux and the requirements for rendering speed are relatively high.
There are two ways to render the web as a video stream.
One is to use xvfb or other virtual desktops and obtain the screen and encode to a video.
Another is to use offscreen rendering by rewriting OnPaint() and encode.

In my computer on windows,I did tests,and I need to run my program on linux.
In onscreen rendering mode, the frame rate can reach 120fps+. However, in off screen rendering mode, the frame rate is only 29-30fps.
But if I use onscreen rendering mode,I also need to obtain the screen content and encode to a video.This seems to be a waste of computing resources. If I use off screen rendering mode,the speed is not ideal.
If I want to use off screen rendering on linux, what can I do to improve the fps?
It is hard to decide which to use?Hope to receive your advice.
DunDunW
Newbie
 
Posts: 5
Joined: Fri Nov 03, 2023 12:41 am

Re: About offscreen and onscreen speed

Postby magreenblatt » Wed Nov 15, 2023 11:24 am

For faster off-screen rendering fps you would need to apply https://bitbucket.org/chromiumembedded/ ... quests/285. See https://github.com/obsproject/obs-browser as an example.
magreenblatt
Site Admin
 
Posts: 12409
Joined: Fri May 29, 2009 6:57 pm

Re: About offscreen and onscreen speed

Postby DunDunW » Wed Nov 15, 2023 8:52 pm

Thank you for your reply. I also want to know if shared textures can be used on Linux?
I saw the comments and shared textures seem to be currently only supported on Windows and macOS.
DunDunW
Newbie
 
Posts: 5
Joined: Fri Nov 03, 2023 12:41 am


Return to Support Forum

Who is online

Users browsing this forum: No registered users and 214 guests