Changeset 128223 in webkit
- Timestamp:
- Sep 11, 2012, 1:54:05 PM (13 years ago)
- Location:
- trunk
- Files:
-
- 1 added
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r128222 r128223 1 2012-09-11 Stephen White <senorblanco@chromium.org> 2 3 [chromium] Mark some tests as needing a rebaseline due to SVG filters change. 4 https://bugs.webkit.org/show_bug.cgi?id=95238 5 6 Reviewed by Dirk Schulze. 7 8 * platform/chromium/TestExpectations: 9 1 10 2012-09-11 Kevin Ellis <kevers@chromium.org> 2 11 -
trunk/LayoutTests/platform/chromium/TestExpectations
r128216 r128223 1319 1319 BUGWK93589 LINUX SNOWLEOPARD DEBUG : svg/dom/SVGScriptElement/script-change-externalResourcesRequired-while-loading.svg = TIMEOUT PASS TEXT 1320 1320 1321 // Need rebaseline for slight pixel changes 1322 BUGWK95238 : svg/W3C-SVG-1.1/filters-comptran-01-b.svg = IMAGE 1323 BUGWK95238 : svg/custom/feComponentTransfer-Discrete.svg = IMAGE 1324 BUGWK95238 : svg/custom/feComponentTransfer-Gamma.svg = IMAGE 1325 BUGWK95238 : svg/custom/feComponentTransfer-Linear.svg = IMAGE 1326 BUGWK95238 : svg/custom/feComponentTransfer-Table.svg = IMAGE 1327 BUGWK95238 : svg/dynamic-updates/SVGFEComponentTransferElement-dom-tableValues-attr.html = IMAGE 1328 BUGWK95238 : svg/dynamic-updates/SVGFEComponentTransferElement-svgdom-tableValues-prop.html = IMAGE 1329 BUGWK95238 : css3/filters/effect-reference-ordering.html = IMAGE 1330 BUGWK95238 : css3/filters/effect-combined.html = IMAGE 1331 BUGWK95238 : css3/filters/effect-opacity.html = IMAGE 1332 1321 1333 // ----------------------------------------------------------------- 1322 1334 // End SVG TESTS -
trunk/Source/WebCore/ChangeLog
r128222 r128223 1 2012-09-11 Stephen White <senorblanco@chromium.org> 2 3 [skia] Switch FEComponentTransfer filter to use skia's SkColorFilter 4 https://bugs.webkit.org/show_bug.cgi?id=95238 5 6 Reviewed by Dirk Schulze. 7 8 Covered by existing tests in svg/, such as svg/custom/feComponentTransfer-Discrete.svg. 9 10 * WebCore.gypi: 11 * platform/graphics/filters/FEComponentTransfer.cpp: 12 (WebCore::FEComponentTransfer::platformApplySoftware): 13 Add a check for the skia implementation. 14 (WebCore::FEComponentTransfer::getValues): 15 * platform/graphics/filters/FEComponentTransfer.h: 16 Factor out the retrieval of LUT values into its own function, so we 17 can call it from the Skia implementation. 18 * platform/graphics/filters/skia/FEComponentTransferSkia.cpp: Added. 19 (WebCore::FEComponentTransfer::platformApplySkia): 20 1 21 2012-09-11 Kevin Ellis <kevers@chromium.org> 2 22 -
trunk/Source/WebCore/WebCore.gypi
r128159 r128223 4997 4997 'platform/graphics/filters/skia/FEBlendSkia.cpp', 4998 4998 'platform/graphics/filters/skia/FEColorMatrixSkia.cpp', 4999 'platform/graphics/filters/skia/FEComponentTransferSkia.cpp', 4999 5000 'platform/graphics/filters/skia/FEGaussianBlurSkia.cpp', 5000 5001 'platform/graphics/filters/skia/FEMorphologySkia.cpp', -
trunk/Source/WebCore/platform/graphics/filters/FEComponentTransfer.cpp
r114992 r128223 160 160 161 161 unsigned char rValues[256], gValues[256], bValues[256], aValues[256]; 162 for (unsigned i = 0; i < 256; ++i) 163 rValues[i] = gValues[i] = bValues[i] = aValues[i] = i; 162 getValues(rValues, gValues, bValues, aValues); 164 163 unsigned char* tables[] = { rValues, gValues, bValues, aValues }; 165 ComponentTransferFunction transferFunction[] = {m_redFunc, m_greenFunc, m_blueFunc, m_alphaFunc};166 TransferType callEffect[] = {identity, identity, table, discrete, linear, gamma};167 168 for (unsigned channel = 0; channel < 4; channel++) {169 ASSERT(static_cast<size_t>(transferFunction[channel].type) < WTF_ARRAY_LENGTH(callEffect));170 (*callEffect[transferFunction[channel].type])(tables[channel], transferFunction[channel]);171 }172 164 173 165 IntRect drawingRect = requestedRegionOfInputImageData(in->absolutePaintRect()); … … 180 172 pixelArray->set(pixelOffset + channel, tables[channel][c]); 181 173 } 174 } 175 } 176 177 void FEComponentTransfer::getValues(unsigned char rValues[256], unsigned char gValues[256], unsigned char bValues[256], unsigned char aValues[256]) 178 { 179 for (unsigned i = 0; i < 256; ++i) 180 rValues[i] = gValues[i] = bValues[i] = aValues[i] = i; 181 unsigned char* tables[] = { rValues, gValues, bValues, aValues }; 182 ComponentTransferFunction transferFunction[] = {m_redFunc, m_greenFunc, m_blueFunc, m_alphaFunc}; 183 TransferType callEffect[] = {identity, identity, table, discrete, linear, gamma}; 184 185 for (unsigned channel = 0; channel < 4; channel++) { 186 ASSERT(static_cast<size_t>(transferFunction[channel].type) < WTF_ARRAY_LENGTH(callEffect)); 187 (*callEffect[transferFunction[channel].type])(tables[channel], transferFunction[channel]); 182 188 } 183 189 } -
trunk/Source/WebCore/platform/graphics/filters/FEComponentTransfer.h
r97853 r128223 80 80 81 81 virtual void platformApplySoftware(); 82 #if USE(SKIA) 83 virtual bool platformApplySkia(); 84 #endif 82 85 virtual void dump(); 83 86 … … 87 90 FEComponentTransfer(Filter*, const ComponentTransferFunction& redFunc, const ComponentTransferFunction& greenFunc, 88 91 const ComponentTransferFunction& blueFunc, const ComponentTransferFunction& alphaFunc); 92 93 void getValues(unsigned char rValues[256], unsigned char gValues[256], unsigned char bValues[256], unsigned char aValues[256]); 89 94 90 95 ComponentTransferFunction m_redFunc;
Note:
See TracChangeset
for help on using the changeset viewer.