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

Side by Side Diff: chrome/renderer/render_view.cc

Issue 3978002: Disable GPU features AcceleratingCompositing and WebGL by default. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 10 years, 2 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/renderer/render_view.h" 5 #include "chrome/renderer/render_view.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <cmath> 8 #include <cmath>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 2532 matching lines...) Expand 10 before | Expand all | Expand 10 after
2543 new media::FilterFactoryCollection(); 2543 new media::FilterFactoryCollection();
2544 // Add in any custom filter factories first. 2544 // Add in any custom filter factories first.
2545 const CommandLine* cmd_line = CommandLine::ForCurrentProcess(); 2545 const CommandLine* cmd_line = CommandLine::ForCurrentProcess();
2546 if (!cmd_line->HasSwitch(switches::kDisableAudio)) { 2546 if (!cmd_line->HasSwitch(switches::kDisableAudio)) {
2547 // Add the chrome specific audio renderer. 2547 // Add the chrome specific audio renderer.
2548 factory->AddFactory( 2548 factory->AddFactory(
2549 AudioRendererImpl::CreateFactory(audio_message_filter())); 2549 AudioRendererImpl::CreateFactory(audio_message_filter()));
2550 } 2550 }
2551 2551
2552 if (cmd_line->HasSwitch(switches::kEnableAcceleratedDecoding) && 2552 if (cmd_line->HasSwitch(switches::kEnableAcceleratedDecoding) &&
2553 !cmd_line->HasSwitch(switches::kDisableAcceleratedCompositing)) { 2553 cmd_line->HasSwitch(switches::kEnableAcceleratedCompositing)) {
2554 // Add the hardware video decoder factory. 2554 // Add the hardware video decoder factory.
2555 // TODO(hclam): This assumes that ggl::Context is set to current 2555 // TODO(hclam): This assumes that ggl::Context is set to current
2556 // internally. I need to make it more explicit to get the context. 2556 // internally. I need to make it more explicit to get the context.
2557 bool ret = frame->view()->graphicsContext3D()->makeContextCurrent(); 2557 bool ret = frame->view()->graphicsContext3D()->makeContextCurrent();
2558 CHECK(ret) << "Failed to switch context"; 2558 CHECK(ret) << "Failed to switch context";
2559 2559
2560 factory->AddFactory(IpcVideoDecoder::CreateFactory( 2560 factory->AddFactory(IpcVideoDecoder::CreateFactory(
2561 MessageLoop::current(), ggl::GetCurrentContext())); 2561 MessageLoop::current(), ggl::GetCurrentContext()));
2562 } 2562 }
2563 2563
(...skipping 3465 matching lines...) Expand 10 before | Expand all | Expand 10 after
6029 } 6029 }
6030 6030
6031 void RenderView::OnAsyncFileOpened(base::PlatformFileError error_code, 6031 void RenderView::OnAsyncFileOpened(base::PlatformFileError error_code,
6032 IPC::PlatformFileForTransit file_for_transit, 6032 IPC::PlatformFileForTransit file_for_transit,
6033 int message_id) { 6033 int message_id) {
6034 pepper_delegate_.OnAsyncFileOpened( 6034 pepper_delegate_.OnAsyncFileOpened(
6035 error_code, 6035 error_code,
6036 IPC::PlatformFileForTransitToPlatformFile(file_for_transit), 6036 IPC::PlatformFileForTransitToPlatformFile(file_for_transit),
6037 message_id); 6037 message_id);
6038 } 6038 }
OLDNEW
« no previous file with comments | « chrome/renderer/render_thread.cc ('k') | chrome/renderer/webgraphicscontext3d_command_buffer_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698