Changeset 56735 in webkit
- Timestamp:
- Mar 29, 2010 11:28:08 AM (14 years ago)
- Location:
- trunk/WebCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/WebCore/ChangeLog
r56732 r56735 1 2010-03-29 Kenneth Russell <kbr@google.com> 2 3 Reviewed by Darin Fisher. 4 5 Eliminate use of GL_BGRA in GraphicsContext3DSkia.cpp 6 https://bugs.webkit.org/show_bug.cgi?id=36737 7 8 No new tests; ran WebGL demos in Chromium on Windows to verify fix. 9 10 * platform/graphics/skia/GraphicsContext3DSkia.cpp: 11 (WebCore::GraphicsContext3D::getImageData): 12 1 13 2010-03-29 Alexander Pavlov <apavlov@chromium.org> 2 14 -
trunk/WebCore/platform/graphics/skia/GraphicsContext3DSkia.cpp
r54907 r56735 34 34 #include "NativeImageSkia.h" 35 35 36 #include <algorithm> 37 36 38 namespace WebCore { 37 39 … … 60 62 uint8_t* pixels = reinterpret_cast<uint8_t*>(skiaImage->getPixels()); 61 63 outputVector.resize(rowBytes * height); 62 memcpy(outputVector.data(), pixels, rowBytes * height); 64 int size = rowBytes * height; 65 memcpy(outputVector.data(), pixels, size); 63 66 *hasAlphaChannel = true; 64 67 if (!premultiplyAlpha) 65 68 // FIXME: must fetch the image data before the premultiplication step 66 69 *neededAlphaOp = kAlphaDoUnmultiply; 67 // FIXME: remove this dependency on desktop OpenGL 68 *format = 0x80E1; // GL_BGRA 70 // Convert from BGRA to RGBA. FIXME: add GL_BGRA extension support 71 // to all underlying OpenGL implementations. 72 for (int i = 0; i < size; i += 4) 73 std::swap(outputVector[i], outputVector[i + 2]); 74 *format = RGBA; 69 75 return true; 70 76 }
Note: See TracChangeset
for help on using the changeset viewer.