You've already forked CEF4Delphi
mirror of
https://github.com/salvadordf/CEF4Delphi.git
synced 2025-08-04 21:32:54 +02:00
Enable hardware acceleration in OSRExternalPumpBrowser2 and SimpleOSRBrowser2
This commit is contained in:
@@ -135,7 +135,7 @@ implementation
|
||||
|
||||
// This demo uses a CEF browser in "off-screen rendering" mode (a.k.a OSR mode)
|
||||
// but instead of copying the raw bitmap information it uses an OpenGL texture
|
||||
// to accelerate drawing the contents.
|
||||
// to accelerate drawing the contents.
|
||||
|
||||
// It's recommemded to avoid using OpenGL in multiple threads so this demo uses
|
||||
// a external message pump to execute all CEF events in the main appliction
|
||||
@@ -200,6 +200,7 @@ begin
|
||||
GlobalCEFApp.WindowlessRenderingEnabled := True;
|
||||
GlobalCEFApp.EnableHighDPISupport := True;
|
||||
GlobalCEFApp.BrowserSubprocessPath := 'OSRExternalPumpBrowser2_sp';
|
||||
GlobalCEFApp.EnableGPU := True;
|
||||
GlobalCEFApp.BackgroundColor := CefColorSetARGB($FF, $FF, $FF, $FF);
|
||||
GlobalCEFApp.ExternalMessagePump := True;
|
||||
GlobalCEFApp.MultiThreadedMessageLoop := False;
|
||||
|
@@ -204,10 +204,10 @@ begin
|
||||
GlobalCEFApp := TCefApplication.Create;
|
||||
GlobalCEFApp.WindowlessRenderingEnabled := True;
|
||||
GlobalCEFApp.EnableHighDPISupport := True;
|
||||
//GlobalCEFApp.EnableGPU := True;
|
||||
GlobalCEFApp.ExternalMessagePump := True;
|
||||
GlobalCEFApp.MultiThreadedMessageLoop := False;
|
||||
GlobalCEFApp.OnScheduleMessagePumpWork := @GlobalCEFApp_OnScheduleMessagePumpWork;
|
||||
GlobalCEFApp.EnableGPU := True;
|
||||
GlobalCEFApp.ExternalMessagePump := True;
|
||||
GlobalCEFApp.MultiThreadedMessageLoop := False;
|
||||
GlobalCEFApp.OnScheduleMessagePumpWork := @GlobalCEFApp_OnScheduleMessagePumpWork;
|
||||
end;
|
||||
|
||||
procedure TForm1.GoBtnClick(Sender: TObject);
|
||||
|
@@ -2,7 +2,7 @@
|
||||
"UpdateLazPackages" : [
|
||||
{
|
||||
"ForceNotify" : true,
|
||||
"InternalVersion" : 379,
|
||||
"InternalVersion" : 380,
|
||||
"Name" : "cef4delphi_lazarus.lpk",
|
||||
"Version" : "100.0.14.0"
|
||||
}
|
||||
|
Reference in New Issue
Block a user