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

Side by Side Diff: Source/core/paint/DeprecatedPaintLayer.cpp

Issue 1326183002: Merge ReferenceFilter into Filter (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved.
3 * 3 *
4 * Portions are Copyright (C) 1998 Netscape Communications Corporation. 4 * Portions are Copyright (C) 1998 Netscape Communications Corporation.
5 * 5 *
6 * Other contributors: 6 * Other contributors:
7 * Robert O'Callahan <roc+@cs.cmu.edu> 7 * Robert O'Callahan <roc+@cs.cmu.edu>
8 * David Baron <dbaron@fas.harvard.edu> 8 * David Baron <dbaron@fas.harvard.edu>
9 * Christian Biesinger <cbiesinger@web.de> 9 * Christian Biesinger <cbiesinger@web.de>
10 * Randall Jesup <rjesup@wgate.com> 10 * Randall Jesup <rjesup@wgate.com>
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 #include "core/layout/svg/ReferenceFilterBuilder.h" 71 #include "core/layout/svg/ReferenceFilterBuilder.h"
72 #include "core/page/Page.h" 72 #include "core/page/Page.h"
73 #include "core/page/scrolling/ScrollingCoordinator.h" 73 #include "core/page/scrolling/ScrollingCoordinator.h"
74 #include "core/paint/FilterEffectBuilder.h" 74 #include "core/paint/FilterEffectBuilder.h"
75 #include "platform/LengthFunctions.h" 75 #include "platform/LengthFunctions.h"
76 #include "platform/RuntimeEnabledFeatures.h" 76 #include "platform/RuntimeEnabledFeatures.h"
77 #include "platform/TraceEvent.h" 77 #include "platform/TraceEvent.h"
78 #include "platform/geometry/FloatPoint3D.h" 78 #include "platform/geometry/FloatPoint3D.h"
79 #include "platform/geometry/FloatRect.h" 79 #include "platform/geometry/FloatRect.h"
80 #include "platform/geometry/TransformState.h" 80 #include "platform/geometry/TransformState.h"
81 #include "platform/graphics/filters/ReferenceFilter.h" 81 #include "platform/graphics/filters/Filter.h"
82 #include "platform/graphics/filters/SourceGraphic.h" 82 #include "platform/graphics/filters/SourceGraphic.h"
83 #include "platform/transforms/ScaleTransformOperation.h" 83 #include "platform/transforms/ScaleTransformOperation.h"
84 #include "platform/transforms/TransformationMatrix.h" 84 #include "platform/transforms/TransformationMatrix.h"
85 #include "platform/transforms/TranslateTransformOperation.h" 85 #include "platform/transforms/TranslateTransformOperation.h"
86 #include "public/platform/Platform.h" 86 #include "public/platform/Platform.h"
87 #include "wtf/Partitions.h" 87 #include "wtf/Partitions.h"
88 #include "wtf/StdLibExtras.h" 88 #include "wtf/StdLibExtras.h"
89 #include "wtf/text/CString.h" 89 #include "wtf/text/CString.h"
90 90
91 namespace blink { 91 namespace blink {
(...skipping 2477 matching lines...) Expand 10 before | Expand all | Expand 10 after
2569 namespace { 2569 namespace {
2570 2570
2571 FilterOperations computeFilterOperationsHandleReferenceFilters(const FilterOpera tions& filters, float effectiveZoom, Node* enclosingElement) 2571 FilterOperations computeFilterOperationsHandleReferenceFilters(const FilterOpera tions& filters, float effectiveZoom, Node* enclosingElement)
2572 { 2572 {
2573 if (filters.hasReferenceFilter()) { 2573 if (filters.hasReferenceFilter()) {
2574 for (size_t i = 0; i < filters.size(); ++i) { 2574 for (size_t i = 0; i < filters.size(); ++i) {
2575 FilterOperation* filterOperation = filters.operations().at(i).get(); 2575 FilterOperation* filterOperation = filters.operations().at(i).get();
2576 if (filterOperation->type() != FilterOperation::REFERENCE) 2576 if (filterOperation->type() != FilterOperation::REFERENCE)
2577 continue; 2577 continue;
2578 ReferenceFilterOperation& referenceOperation = toReferenceFilterOper ation(*filterOperation); 2578 ReferenceFilterOperation& referenceOperation = toReferenceFilterOper ation(*filterOperation);
2579 // FIXME: Cache the ReferenceFilter if it didn't change. 2579 // FIXME: Cache the Filter if it didn't change.
2580 RefPtrWillBeRawPtr<ReferenceFilter> referenceFilter = ReferenceFilte rBuilder::build(effectiveZoom, toElement(enclosingElement), nullptr, referenceOp eration); 2580 RefPtrWillBeRawPtr<Filter> referenceFilter = ReferenceFilterBuilder: :build(effectiveZoom, toElement(enclosingElement), nullptr, referenceOperation);
2581 referenceOperation.setFilter(referenceFilter.release()); 2581 referenceOperation.setFilter(referenceFilter.release());
2582 } 2582 }
2583 } 2583 }
2584 2584
2585 return filters; 2585 return filters;
2586 } 2586 }
2587 2587
2588 } // unnamed namespace 2588 } // unnamed namespace
2589 2589
2590 FilterOperations DeprecatedPaintLayer::computeFilterOperations(const ComputedSty le& style) 2590 FilterOperations DeprecatedPaintLayer::computeFilterOperations(const ComputedSty le& style)
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after
2744 2744
2745 void showLayerTree(const blink::LayoutObject* layoutObject) 2745 void showLayerTree(const blink::LayoutObject* layoutObject)
2746 { 2746 {
2747 if (!layoutObject) { 2747 if (!layoutObject) {
2748 fprintf(stderr, "Cannot showLayerTree. Root is (nil)\n"); 2748 fprintf(stderr, "Cannot showLayerTree. Root is (nil)\n");
2749 return; 2749 return;
2750 } 2750 }
2751 showLayerTree(layoutObject->enclosingLayer()); 2751 showLayerTree(layoutObject->enclosingLayer());
2752 } 2752 }
2753 #endif 2753 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698