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

Side by Side Diff: content/renderer/render_view_impl.cc

Issue 10831291: Temporarily disabling H/W video decode on Windows to see if the crashes in the gpu process (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "content/renderer/render_view_impl.h" 5 #include "content/renderer/render_view_impl.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 2389 matching lines...) Expand 10 before | Expand all | Expand 10 after
2400 // Add the chrome specific audio renderer, using audio_source_provider 2400 // Add the chrome specific audio renderer, using audio_source_provider
2401 // as the sink. 2401 // as the sink.
2402 media::AudioRendererImpl* audio_renderer = 2402 media::AudioRendererImpl* audio_renderer =
2403 new media::AudioRendererImpl(audio_source_provider); 2403 new media::AudioRendererImpl(audio_source_provider);
2404 collection->AddAudioRenderer(audio_renderer); 2404 collection->AddAudioRenderer(audio_renderer);
2405 } 2405 }
2406 2406
2407 // Accelerated video decode is not enabled by default on Linux. 2407 // Accelerated video decode is not enabled by default on Linux.
2408 // crbug.com/137247 2408 // crbug.com/137247
2409 bool use_accelerated_video_decode = false; 2409 bool use_accelerated_video_decode = false;
2410 #if defined(OS_CHROMEOS) || defined(OS_WIN) 2410 #if defined(OS_CHROMEOS)
2411 use_accelerated_video_decode = true; 2411 use_accelerated_video_decode = true;
2412 #endif 2412 #elif defined(OS_WIN)
Ami GONE FROM CHROMIUM 2012/08/13 19:38:28 This isn't necessary (false is the default value a
ananta 2012/08/13 19:43:59 I added the #else to prevent the CommandLine switc
Ami GONE FROM CHROMIUM 2012/08/13 19:51:47 Did you miss that there's an &= in there?
ananta 2012/08/13 19:52:12 Removed the #elif OS_WIN check here. The &= expres
2413 use_accelerated_video_decode = false;
2414 #else
2413 use_accelerated_video_decode &= !CommandLine::ForCurrentProcess()->HasSwitch( 2415 use_accelerated_video_decode &= !CommandLine::ForCurrentProcess()->HasSwitch(
2414 switches::kDisableAcceleratedVideoDecode); 2416 switches::kDisableAcceleratedVideoDecode);
2417 #endif
2415 base::WeakPtr<WebGraphicsContext3DCommandBufferImpl> context3d = 2418 base::WeakPtr<WebGraphicsContext3DCommandBufferImpl> context3d =
2416 use_accelerated_video_decode ? 2419 use_accelerated_video_decode ?
2417 RenderThreadImpl::current()->GetGpuVDAContext3D() : 2420 RenderThreadImpl::current()->GetGpuVDAContext3D() :
2418 base::WeakPtr<WebGraphicsContext3DCommandBufferImpl>(); 2421 base::WeakPtr<WebGraphicsContext3DCommandBufferImpl>();
2419 if (context3d) { 2422 if (context3d) {
2420 MessageLoop* factories_loop = 2423 MessageLoop* factories_loop =
2421 RenderThreadImpl::current()->compositor_thread() ? 2424 RenderThreadImpl::current()->compositor_thread() ?
2422 RenderThreadImpl::current()->compositor_thread()->GetWebThread() 2425 RenderThreadImpl::current()->compositor_thread()->GetWebThread()
2423 ->message_loop() : 2426 ->message_loop() :
2424 MessageLoop::current(); 2427 MessageLoop::current();
(...skipping 3350 matching lines...) Expand 10 before | Expand all | Expand 10 after
5775 bool RenderViewImpl::WebWidgetHandlesCompositorScheduling() const { 5778 bool RenderViewImpl::WebWidgetHandlesCompositorScheduling() const {
5776 return !!RenderThreadImpl::current()->compositor_thread(); 5779 return !!RenderThreadImpl::current()->compositor_thread();
5777 } 5780 }
5778 5781
5779 void RenderViewImpl::OnJavaBridgeInit() { 5782 void RenderViewImpl::OnJavaBridgeInit() {
5780 DCHECK(!java_bridge_dispatcher_); 5783 DCHECK(!java_bridge_dispatcher_);
5781 #if defined(ENABLE_JAVA_BRIDGE) 5784 #if defined(ENABLE_JAVA_BRIDGE)
5782 java_bridge_dispatcher_ = new JavaBridgeDispatcher(this); 5785 java_bridge_dispatcher_ = new JavaBridgeDispatcher(this);
5783 #endif 5786 #endif
5784 } 5787 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698