From ffcf0ecadc6243360a49831c45c1338e6d3dc638 Mon Sep 17 00:00:00 2001 From: amaitland Date: Wed, 23 Mar 2016 15:27:16 +1000 Subject: [PATCH] Disable GPU in WPF and Offscreen examples until #1634 has been resolved --- CefSharp.MinimalExample.OffScreen/Program.cs | 6 +++++- CefSharp.MinimalExample.Wpf/App.xaml.cs | 3 +++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/CefSharp.MinimalExample.OffScreen/Program.cs b/CefSharp.MinimalExample.OffScreen/Program.cs index 850c3aa..75b0c7d 100644 --- a/CefSharp.MinimalExample.OffScreen/Program.cs +++ b/CefSharp.MinimalExample.OffScreen/Program.cs @@ -22,8 +22,12 @@ namespace CefSharp.MinimalExample.OffScreen Console.WriteLine("You may see Chromium debugging output, please wait..."); Console.WriteLine(); + var settings = new CefSettings(); + // Disable GPU in WPF and Offscreen examples until #1634 has been resolved + settings.CefCommandLineArgs.Add("disable-gpu", "1"); + //Perform dependency check to make sure all relevant resources are in our output directory. - Cef.Initialize(new CefSettings(), shutdownOnProcessExit: true, performDependencyCheck: true); + Cef.Initialize(settings, shutdownOnProcessExit: true, performDependencyCheck: true); // Create the offscreen Chromium browser. browser = new ChromiumWebBrowser(testUrl); diff --git a/CefSharp.MinimalExample.Wpf/App.xaml.cs b/CefSharp.MinimalExample.Wpf/App.xaml.cs index dd72b16..6836df0 100644 --- a/CefSharp.MinimalExample.Wpf/App.xaml.cs +++ b/CefSharp.MinimalExample.Wpf/App.xaml.cs @@ -9,6 +9,9 @@ namespace CefSharp.MinimalExample.Wpf //Perform dependency check to make sure all relevant resources are in our output directory. var settings = new CefSettings(); settings.EnableInternalPdfViewerOffScreen(); + // Disable GPU in WPF and Offscreen examples until #1634 has been resolved + settings.CefCommandLineArgs.Add("disable-gpu", "1"); + Cef.Initialize(settings, shutdownOnProcessExit: true, performDependencyCheck: true); } }