CEF offscreen rendering with shared textures using skia

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.

Re: CEF offscreen rendering with shared textures using skia

Postby rjxray » Tue Feb 06, 2024 6:08 am

Its the same with --transparent-painting-enabled added
rjxray
Expert
 
Posts: 115
Joined: Wed Jun 07, 2017 4:31 am

Re: CEF offscreen rendering with shared textures using skia

Postby reito » Tue Feb 06, 2024 6:24 am

I'll try your buildflags and test it out. Actually on my very first debug, the OnPaint got called by some Layer->Draw() actually, but it never comes up again.
reito
Techie
 
Posts: 18
Joined: Sat Jan 27, 2024 11:19 pm

Re: CEF offscreen rendering with shared textures using skia

Postby reito » Tue Feb 06, 2024 6:41 am

Hi, do you still have a full stacktrace? And, do you have a discord like thing to communicate?
reito
Techie
 
Posts: 18
Joined: Sat Jan 27, 2024 11:19 pm

Re: CEF offscreen rendering with shared textures using skia

Postby rjxray » Tue Feb 06, 2024 7:24 am

Sorry for the slow response, but I have an issue

cefclient.exe --transparent-painting-enabled --shared-texture-enabled --off-screen-rendering-enabled ran ok the first time I tried from the command line on the server.
Subsequent attempts all failed - it just showed the window without rendering and then closed.

The issue is running from VS - it couldn't find ninja.
I found a typo in the depot_tools PATH entry that I created yesterday.
I fixed that and verified PATH was correct from a command window but on restarting VS it still doesn't find ninja?
I can't see any other depot_tools in PATH
I added the correct depot_tools path to the VS Executable directories and also merged into %PATH% in the Environment debugging properties.
Neither worked, I still can't debug.

Besides trying to fix this issue I'm now concerned that the build may be incorrect as depot_tools was not in PATH
rjxray
Expert
 
Posts: 115
Joined: Wed Jun 07, 2017 4:31 am

Re: CEF offscreen rendering with shared textures using skia

Postby rjxray » Wed Feb 07, 2024 3:12 am

I set PATH correctly and did a new build on the server but I still had exactly the same issue

So instead I tried a build on my own device (i7-13700H) it took a while but completed overnight

cefclient.exe --transparent-painting-enabled --shared-texture-enabled --off-screen-rendering-enabled runs perfectly in the chromium build folder
I still can't run the Chromium build from VS, I get 'ninja.exe' is not recognized as an internal or external command' even though PATH to depot tools is correct. There is no ninja.exe in depot_tools, just ninja.bat.
Anyway I built the binary distribution. I had a couple of errors with pragma clang unrecognised in osr_renderer.cc but I just commented them out and then it built and ran

Cefclient is running perfectly now and definitely calling OnAcceleratedPaint
It seems very fast and I'm now going to try and integrate this build with our own app

I did go back and double check the server, I still can't see anything wrong there, GN_DEFINES and GN_ARGUMENTS are the same, depot_tools folder is first in PATH, Windows SDK is the correct one, automate-git invocation is the same.

Anyway, thanks for this amazing work, much appreciated.

By the way Microsoft have been intending to develop off screen rendering for webView2 for the last couple of years now but nothing has happened yet. See https://github.com/MicrosoftEdge/WebVie ... issues/547. It would be worth bringing the Chromium patch to their attention...
rjxray
Expert
 
Posts: 115
Joined: Wed Jun 07, 2017 4:31 am

Re: CEF offscreen rendering with shared textures using skia

Postby reito » Wed Feb 07, 2024 3:22 am

Hah, hope you can sort it out soon. I also notified on the WebView2 issue now, thanks for the info.
reito
Techie
 
Posts: 18
Joined: Sat Jan 27, 2024 11:19 pm

Re: CEF offscreen rendering with shared textures using skia

Postby yutou15 » Fri Mar 08, 2024 5:14 am

reito wrote:Update: I'm goint to implement a method that supports macOS (via IOSurface) and Windows (via DXGI) using GMB buffers. My idea is implement another FrameSink that is dedicated to pop copyable resource up to the CEF layer, in parallel with existing VideoCapture method


Execute me, may I ask if you can support Linux (x64) version? I am new in CEF. It is tough for me to find where to update.
yutou15
Newbie
 
Posts: 1
Joined: Fri Mar 08, 2024 5:03 am

Re: CEF offscreen rendering with shared textures using skia

Postby reito » Fri Mar 08, 2024 9:40 am

yutou15 wrote:
reito wrote:Update: I'm goint to implement a method that supports macOS (via IOSurface) and Windows (via DXGI) using GMB buffers. My idea is implement another FrameSink that is dedicated to pop copyable resource up to the CEF layer, in parallel with existing VideoCapture method


Execute me, may I ask if you can support Linux (x64) version? I am new in CEF. It is tough for me to find where to update.


There're some one dealing with it but it is hard for us to develop and debug on linux. It is also hard to provide a good compability because of x11/wayland and all the gpu driver nonsense. You can join us in OBS discord server.
reito
Techie
 
Posts: 18
Joined: Sat Jan 27, 2024 11:19 pm

Re: CEF offscreen rendering with shared textures using skia

Postby reito » Sat Apr 27, 2024 11:34 am

Forgot to update here, this has been merged in https://bitbucket.org/chromiumembedded/ ... 0fe85d81fe
In case you missed it :)
reito
Techie
 
Posts: 18
Joined: Sat Jan 27, 2024 11:19 pm

Previous

Return to Support Forum

Who is online

Users browsing this forum: Google [Bot] and 204 guests