Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(222)

Unified Diff: chrome/browser/extensions/chrome_content_browser_client_extensions_part.cc

Issue 453063002: Only allow webrtc HW offload for H264 encode for extension process. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: add ifdef for WEBRTC Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/extensions/chrome_content_browser_client_extensions_part.cc
diff --git a/chrome/browser/extensions/chrome_content_browser_client_extensions_part.cc b/chrome/browser/extensions/chrome_content_browser_client_extensions_part.cc
index b0dfa85ab4918ed0de2f5ab7da035cbc8585108c..36cd96ba9eb5a7b499adb419853c80c8b2857e30 100644
--- a/chrome/browser/extensions/chrome_content_browser_client_extensions_part.cc
+++ b/chrome/browser/extensions/chrome_content_browser_client_extensions_part.cc
@@ -29,6 +29,7 @@
#include "content/public/browser/render_view_host.h"
#include "content/public/browser/site_instance.h"
#include "content/public/browser/web_contents.h"
+#include "content/public/common/content_switches.h"
#include "extensions/browser/extension_host.h"
#include "extensions/browser/extension_message_filter.h"
#include "extensions/browser/extension_registry.h"
@@ -526,8 +527,12 @@ void ChromeContentBrowserClientExtensionsPart::
if (!process)
return;
DCHECK(profile);
- if (ProcessMap::Get(profile)->Contains(process->GetID()))
+ if (ProcessMap::Get(profile)->Contains(process->GetID())) {
command_line->AppendSwitch(switches::kExtensionProcess);
+#if defined(ENABLE_WEBRTC)
+ command_line->AppendSwitch(::switches::kEnableWebRtcHWH264Encoding);
+#endif
+ }
}
} // namespace extensions
« no previous file with comments | « chrome/browser/chromeos/login/chrome_restart_request.cc ('k') | content/browser/renderer_host/render_process_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698