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

Side by Side Diff: content/renderer/pepper/video_encoder_shim.cc

Issue 1276633004: convince gcc that cpu_used et al are always initialized (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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
« 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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/pepper/video_encoder_shim.h" 5 #include "content/renderer/pepper/video_encoder_shim.h"
6 6
7 #include <inttypes.h> 7 #include <inttypes.h>
8 8
9 #include <deque> 9 #include <deque>
10 10
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 *cpu_used = kVp8DefaultCpuUsed; 70 *cpu_used = kVp8DefaultCpuUsed;
71 break; 71 break;
72 case media::VP9PROFILE_ANY: 72 case media::VP9PROFILE_ANY:
73 *vpx_codec = vpx_codec_vp9_cx(); 73 *vpx_codec = vpx_codec_vp9_cx();
74 *min_quantizer = kVp9DefaultMinQuantizer; 74 *min_quantizer = kVp9DefaultMinQuantizer;
75 *max_quantizer = kVp9DefaultMaxQuantizer; 75 *max_quantizer = kVp9DefaultMaxQuantizer;
76 *cpu_used = kVp9DefaultCpuUsed; 76 *cpu_used = kVp9DefaultCpuUsed;
77 break; 77 break;
78 default: 78 default:
79 *vpx_codec = nullptr; 79 *vpx_codec = nullptr;
80 *min_quantizer = kVp9DefaultMinQuantizer;
81 *max_quantizer = kVp9DefaultMaxQuantizer;
82 *cpu_used = kVp9DefaultCpuUsed;
bbudge-google 2015/08/06 12:26:25 nit: Just zero them to make it clear this is an er
80 NOTREACHED(); 83 NOTREACHED();
81 } 84 }
82 } 85 }
83 86
84 } // namespace 87 } // namespace
85 88
86 class VideoEncoderShim::EncoderImpl { 89 class VideoEncoderShim::EncoderImpl {
87 public: 90 public:
88 explicit EncoderImpl(const base::WeakPtr<VideoEncoderShim>& shim); 91 explicit EncoderImpl(const base::WeakPtr<VideoEncoderShim>& shim);
89 ~EncoderImpl(); 92 ~EncoderImpl();
(...skipping 369 matching lines...) Expand 10 before | Expand all | Expand 10 after
459 } 462 }
460 463
461 void VideoEncoderShim::OnNotifyError( 464 void VideoEncoderShim::OnNotifyError(
462 media::VideoEncodeAccelerator::Error error) { 465 media::VideoEncodeAccelerator::Error error) {
463 DCHECK(RenderThreadImpl::current()); 466 DCHECK(RenderThreadImpl::current());
464 467
465 host_->NotifyError(error); 468 host_->NotifyError(error);
466 } 469 }
467 470
468 } // namespace content 471 } // namespace content
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