I was chatting with Fran莽ois Grassard over the past few days. He once showed me an AE to HTML exporter and I asked him to modify this for the current versions of AE and Caspar. I will add part of that conversation down bellow:
I spent the night on the last release of CasparCG. I can now confirm that the 2.2 release is not able to handle HTML5 well enough. The frame rate is not constant, it's impossible to use WebGl, I made several tests on pure CSS animations and other controlled by JavaScript. Il was always too laggy and abviously impossible to synchronize with audio.
Yes, for now I'm still thinking HTML5 is a great choice in general, but the HTML Producer in CasparCG is not ready yet. I you want to take look, the one integrated in OBS work really well since the last summer.
Take a look at "The browser source was majorly refactored, and is now hardware accelerated."
So I think we should investigate that ASAP,
The framerate issue I am confident is because of #1165. I feel like I'm trying to blame everything on that, but that issue was found while looking into jerky html rendering. (Fun fact, if you go against all the html in caspar advice and don't use onRequestAnimationFrame things actually render a lot smoother!)
Yes, lack of webgl is known and down to lack of gpu acceleration in cef. There is a config option to enable gpu acceleration (and have decent webgl), but that often gives much worse overall performance.
Audio in html I am hoping for 2.3, still waiting for it to get merged in cef then it should follow shortly after here. #669
I have started working on proper gpu acceleration, but havent had much time to spend on it. Again, something that I aim to have for 2.3
I think you need use cef accelerator to create caspar frame. I try to use CefRenderHandler::OnAcceleratedPaint event, enable shared texture: CefWindowInfo.shared_texture_enabled = true, browse tick time is good with enable-gpu for html, but I don't know copy D3D11Device Texture2D to caspar frame?
No shared:
https://drive.google.com/open?id=1yp8m106hg3gZwVPir05KiX50GX-nN4E6
Shared:
https://drive.google.com/open?id=1n8FHHil2uj330iJ3FXxbrazMdQZprqDp
Test webgl url:
http://pixijs.io/pixi-filters/tools/demo/
I think you need use cef accelerator to create caspar frame. I try to use CefRenderHandler::OnAcceleratedPaint event, enable shared texture: CefWindowInfo.shared_texture_enabled = true, browse tick time is good with enable-gpu for html, but I don't know copy D3D11Device Texture2D to caspar frame?
Yeah, converting the frames is not simple, but I have something working and haven't had time to finish it up yet
May be we must add support for:
But soon will be support for Viz - https://bitbucket.org/chromiumembedded/cef/issues/2575/viz-implementation-for-osr
I think you need use cef accelerator to create caspar frame. I try to use CefRenderHandler::OnAcceleratedPaint event, enable shared texture: CefWindowInfo.shared_texture_enabled = true, browse tick time is good with enable-gpu for html, but I don't know copy D3D11Device Texture2D to caspar frame?
Yeah, converting the frames is not simple, but I have something working and haven't had time to finish it up yet
Hi Julusian.
Are you finish "something"?
I think need create a d3d11 context. Then:
Html producer --> CefRenderHandler::OnAcceleratedPaint --> d3d11 context: open_shared_texture --> read image to caspar mutable frame --> draw_frame.
But I do not know how to do
@ducthiem90 I havent been able to spend any time to try and finish this up yet.
It looks like the CEF changes linked to above will break any implementation against the current accelerated rendering, so I am hoping for that change to stabilise soon before I try and make more progress
I finished shared texture from cef to Caspar. And the result is good. My solution:

Wow!!
You could do a PR against https://github.com/nrkno/tv-automation-casparcg-server
Most helpful comment
I finished shared texture from cef to Caspar. And the result is good. My solution:
But I work in Caspar 2.1 and only support for windows. I shall try in Caspar 2.2 soon.