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

Unified Diff: Source/platform/graphics/filters/FEGaussianBlur.cpp

Issue 519463002: Removing "using" declarations that import names in the C++ Standard library.(Source/platform/[geome… (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebasing Created 6 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 side-by-side diff with in-line comments
Download patch
Index: Source/platform/graphics/filters/FEGaussianBlur.cpp
diff --git a/Source/platform/graphics/filters/FEGaussianBlur.cpp b/Source/platform/graphics/filters/FEGaussianBlur.cpp
index 529bfb80c3a3389b7633aa6a6a413af22d883c7e..149f7a80f3ffb62bc278fb3e5e4339fe3701cf50 100644
--- a/Source/platform/graphics/filters/FEGaussianBlur.cpp
+++ b/Source/platform/graphics/filters/FEGaussianBlur.cpp
@@ -37,8 +37,6 @@
#include "SkBlurImageFilter.h"
-using namespace std;
-
static inline float gaussianKernelFactor()
{
return 3 / 4.f * sqrtf(twoPiFloat);
@@ -88,13 +86,13 @@ IntSize FEGaussianBlur::calculateUnscaledKernelSize(const FloatPoint& std)
// Limit the kernel size to 1000. A bigger radius won't make a big difference for the result image but
// inflates the absolute paint rect to much. This is compatible with Firefox' behavior.
if (std.x()) {
- int size = max<unsigned>(2, static_cast<unsigned>(floorf(std.x() * gaussianKernelFactor() + 0.5f)));
- kernelSize.setWidth(min(size, gMaxKernelSize));
+ int size = std::max<unsigned>(2, static_cast<unsigned>(floorf(std.x() * gaussianKernelFactor() + 0.5f)));
+ kernelSize.setWidth(std::min(size, gMaxKernelSize));
}
if (std.y()) {
- int size = max<unsigned>(2, static_cast<unsigned>(floorf(std.y() * gaussianKernelFactor() + 0.5f)));
- kernelSize.setHeight(min(size, gMaxKernelSize));
+ int size = std::max<unsigned>(2, static_cast<unsigned>(floorf(std.y() * gaussianKernelFactor() + 0.5f)));
+ kernelSize.setHeight(std::min(size, gMaxKernelSize));
}
return kernelSize;
« no previous file with comments | « Source/platform/graphics/filters/FEDropShadow.cpp ('k') | Source/platform/graphics/filters/FEMorphology.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698