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

Side by Side Diff: remoting/base/decoder_vp8.cc

Issue 8511068: Initialize clip_rect_ member to be empty until explicitly set. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 1 month 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "remoting/base/decoder_vp8.h" 5 #include "remoting/base/decoder_vp8.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "media/base/media.h" 8 #include "media/base/media.h"
9 #include "media/base/yuv_convert.h" 9 #include "media/base/yuv_convert.h"
10 #include "remoting/base/util.h" 10 #include "remoting/base/util.h"
11 11
12 extern "C" { 12 extern "C" {
13 #define VPX_CODEC_DISABLE_COMPAT 1 13 #define VPX_CODEC_DISABLE_COMPAT 1
14 #include "third_party/libvpx/libvpx.h" 14 #include "third_party/libvpx/libvpx.h"
15 } 15 }
16 16
17 namespace remoting { 17 namespace remoting {
18 18
19 DecoderVp8::DecoderVp8() 19 DecoderVp8::DecoderVp8()
20 : state_(kUninitialized), 20 : state_(kUninitialized),
21 codec_(NULL), 21 codec_(NULL),
22 last_image_(NULL), 22 last_image_(NULL),
23 clip_rect_(SkIRect::MakeEmpty()),
23 horizontal_scale_ratio_(1.0), 24 horizontal_scale_ratio_(1.0),
24 vertical_scale_ratio_(1.0) { 25 vertical_scale_ratio_(1.0) {
25 } 26 }
26 27
27 DecoderVp8::~DecoderVp8() { 28 DecoderVp8::~DecoderVp8() {
28 if (codec_) { 29 if (codec_) {
29 vpx_codec_err_t ret = vpx_codec_destroy(codec_); 30 vpx_codec_err_t ret = vpx_codec_destroy(codec_);
30 CHECK(ret == VPX_CODEC_OK) << "Failed to destroy codec"; 31 CHECK(ret == VPX_CODEC_OK) << "Failed to destroy codec";
31 } 32 }
32 delete codec_; 33 delete codec_;
(...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after
226 dest_rect, 227 dest_rect,
227 scaled_rect, 228 scaled_rect,
228 last_image_->stride[0], 229 last_image_->stride[0],
229 last_image_->stride[1], 230 last_image_->stride[1],
230 stride); 231 stride);
231 output_rects->push_back(scaled_rect); 232 output_rects->push_back(scaled_rect);
232 } 233 }
233 } 234 }
234 235
235 } // namespace remoting 236 } // namespace remoting
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