Changeset 222264 in webkit
- Timestamp:
- Sep 20, 2017 9:02:51 AM (7 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r222263 r222264 1 2017-09-20 Miguel Gomez <magomez@igalia.com> 2 3 [GTK] Completely garbled display in GMail 4 https://bugs.webkit.org/show_bug.cgi?id=168964 5 6 Reviewed by Carlos Garcia Campos. 7 8 Do not try to decode images that are bigger than 32768 pixels, as cairo won't be able to render them, 9 and they will break the rendering of the rest of the page. 10 11 Covered by existent tests. 12 13 * platform/graphics/ImageBackingStore.h: 14 (WebCore::ImageBackingStore::isOverSize): 15 1 16 2017-09-20 Antti Koivisto <antti@apple.com> 2 17 -
trunk/Source/WebCore/platform/graphics/ImageBackingStore.h
r219702 r222264 34 34 namespace WebCore { 35 35 36 #if USE(CAIRO) 37 // Due to the pixman 16.16 floating point representation, cairo is not able to handle 38 // images whose size is bigger than 32768. 39 static const int cairoMaxImageSize = 32768; 40 #endif 41 36 42 class ImageBackingStore { 37 43 WTF_MAKE_FAST_ALLOCATED; … … 172 178 static bool isOverSize(const IntSize& size) 173 179 { 180 #if USE(CAIRO) 181 // FIXME: this is a workaround to avoid the cairo image size limit, but we should implement support for 182 // bigger images. See https://bugs.webkit.org/show_bug.cgi?id=177227. 183 // 184 // If the image is bigger than the cairo limit it can't be displayed, so we don't even try to decode it. 185 if (size.width() > cairoMaxImageSize || size.height() > cairoMaxImageSize) 186 return true; 187 #endif 174 188 static unsigned long long MaxPixels = ((1 << 29) - 1); 175 189 unsigned long long pixels = static_cast<unsigned long long>(size.width()) * static_cast<unsigned long long>(size.height());
Note: See TracChangeset
for help on using the changeset viewer.