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

Side by Side Diff: third_party/WebKit/Source/platform/image-encoders/ImageEncoder.cpp

Issue 2940933003: DO NOT SUBMIT results of new clang-format (Closed)
Patch Set: Created 3 years, 6 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
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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 "platform/image-encoders/ImageEncoder.h" 5 #include "platform/image-encoders/ImageEncoder.h"
6 6
7 namespace blink { 7 namespace blink {
8 8
9 bool ImageEncoder::Encode(Vector<unsigned char>* dst, 9 bool ImageEncoder::Encode(Vector<unsigned char>* dst,
10 const SkPixmap& src, 10 const SkPixmap& src,
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 options.fCompression = SkWebpEncoder::Compression::kLossless; 74 options.fCompression = SkWebpEncoder::Compression::kLossless;
75 options.fQuality = 75.0f; 75 options.fQuality = 75.0f;
76 } else { 76 } else {
77 options.fQuality = 80.0f; // Default value 77 options.fQuality = 80.0f; // Default value
78 if (0.0f <= quality && quality <= 1.0) 78 if (0.0f <= quality && quality <= 1.0)
79 options.fQuality = quality * 100.0f; 79 options.fQuality = quality * 100.0f;
80 } 80 }
81 81
82 return options; 82 return options;
83 } 83 }
84 }; 84 }; // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698