Can i always use OSR mode?

Post Reply
ForestListener
Posts: 44
Joined: Sun Jul 07, 2019 1:46 pm

Can i always use OSR mode?

Post by ForestListener »

Hello.

I think, i've turned OSR mode ON by adding this code:

Code: Select all

GlobalCEFApp.WindowlessRenderingEnabled := True;
GlobalCEFApp.EnableHighDPISupport       := True;
Is it enough?

And also i want to know, why OSR mode is not turned on by default? I mean, why not use it always, what is bad in this mode?

Thank you!
User avatar
salvadordf
Posts: 2986
Joined: Thu Feb 02, 2017 12:24 pm
Location: Spain
Contact:

Re: Can i always use OSR mode?

Post by salvadordf »

The GlobalCEFApp.WindowlessRenderingEnabled property sets windowless_rendering_enabled in TCefSettings when CEF is initialized.

These are the code comments for windowless_rendering_enabled :
https://bitbucket.org/chromiumembedded/ ... #lines-206

Code: Select all

  ///
  // Set to true (1) to enable windowless (off-screen) rendering support. Do not
  // enable this value if the application does not use windowless rendering as
  // it may reduce rendering performance on some systems.
  ///
User avatar
salvadordf
Posts: 2986
Joined: Thu Feb 02, 2017 12:24 pm
Location: Spain
Contact:

Re: Can i always use OSR mode?

Post by salvadordf »

To create a browser in OSR mode you also need to call TChromium.CreateBrowser without a TCEFWindowParent parameter, and you will need to implement most of the events found in the OSR demos.
ForestListener
Posts: 44
Joined: Sun Jul 07, 2019 1:46 pm

Re: Can i always use OSR mode?

Post by ForestListener »

salvadordf wrote: Wed Jul 10, 2019 4:31 pm To create a browser in OSR mode you also need to call TChromium.CreateBrowser without a TCEFWindowParent parameter, and you will need to implement most of the events found in the OSR demos.
Got it. Thank you.
Post Reply