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

Side by Side Diff: third_party/WebKit/Source/platform/graphics/filters/SkiaImageFilterBuilder.cpp

Issue 2307343002: Remove dead uses of FilterEffect::determineMaximumEffectRect (Closed)
Patch Set: Created 4 years, 3 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 | « third_party/WebKit/Source/platform/graphics/filters/FilterEffect.cpp ('k') | 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 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 for (size_t i = 0; i < operations.size(); ++i) { 107 for (size_t i = 0; i < operations.size(); ++i) {
108 const FilterOperation& op = *operations.at(i); 108 const FilterOperation& op = *operations.at(i);
109 switch (op.type()) { 109 switch (op.type()) {
110 case FilterOperation::REFERENCE: { 110 case FilterOperation::REFERENCE: {
111 Filter* referenceFilter = toReferenceFilterOperation(op).getFilter() ; 111 Filter* referenceFilter = toReferenceFilterOperation(op).getFilter() ;
112 if (referenceFilter && referenceFilter->lastEffect()) { 112 if (referenceFilter && referenceFilter->lastEffect()) {
113 populateSourceGraphicImageFilters(referenceFilter->getSourceGrap hic(), nullptr, currentColorSpace); 113 populateSourceGraphicImageFilters(referenceFilter->getSourceGrap hic(), nullptr, currentColorSpace);
114 114
115 FilterEffect* filterEffect = referenceFilter->lastEffect(); 115 FilterEffect* filterEffect = referenceFilter->lastEffect();
116 currentColorSpace = filterEffect->operatingColorSpace(); 116 currentColorSpace = filterEffect->operatingColorSpace();
117 filterEffect->determineMaximumEffectRect(MapRectForward);
118 filters->appendReferenceFilter(SkiaImageFilterBuilder::build(fil terEffect, currentColorSpace)); 117 filters->appendReferenceFilter(SkiaImageFilterBuilder::build(fil terEffect, currentColorSpace));
119 } 118 }
120 break; 119 break;
121 } 120 }
122 case FilterOperation::GRAYSCALE: 121 case FilterOperation::GRAYSCALE:
123 case FilterOperation::SEPIA: 122 case FilterOperation::SEPIA:
124 case FilterOperation::SATURATE: 123 case FilterOperation::SATURATE:
125 case FilterOperation::HUE_ROTATE: { 124 case FilterOperation::HUE_ROTATE: {
126 float amount = toBasicColorMatrixFilterOperation(op).amount(); 125 float amount = toBasicColorMatrixFilterOperation(op).amount();
127 switch (op.type()) { 126 switch (op.type()) {
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
208 } else { 207 } else {
209 maskedInput = input; 208 maskedInput = input;
210 } 209 }
211 sk_sp<SkImageFilter> flipImageFilter = SkImageFilter::MakeMatrixFilter( 210 sk_sp<SkImageFilter> flipImageFilter = SkImageFilter::MakeMatrixFilter(
212 reflection.reflectionMatrix(), kLow_SkFilterQuality, std::move(maskedInp ut)); 211 reflection.reflectionMatrix(), kLow_SkFilterQuality, std::move(maskedInp ut));
213 return SkXfermodeImageFilter::Make(nullptr, std::move(flipImageFilter), std: :move(input), nullptr); 212 return SkXfermodeImageFilter::Make(nullptr, std::move(flipImageFilter), std: :move(input), nullptr);
214 } 213 }
215 214
216 } // namespace SkiaImageFilterBuilder 215 } // namespace SkiaImageFilterBuilder
217 } // namespace blink 216 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/platform/graphics/filters/FilterEffect.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698