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

Side by Side Diff: third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.h

Issue 1816623002: Reenable IOSurface Canvas2D. Disable new trace tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Continue to rebase. Created 4 years, 9 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
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 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 class WebGraphicsContext3D; 59 class WebGraphicsContext3D;
60 class WebGraphicsContext3DProvider; 60 class WebGraphicsContext3DProvider;
61 class SharedContextRateLimiter; 61 class SharedContextRateLimiter;
62 62
63 #if OS(MACOSX) 63 #if OS(MACOSX)
64 // Canvas hibernation is currently disabled on MacOS X due to a bug that causes content loss 64 // Canvas hibernation is currently disabled on MacOS X due to a bug that causes content loss
65 // TODO: Find a better fix for crbug.com/588434 65 // TODO: Find a better fix for crbug.com/588434
66 #define CANVAS2D_HIBERNATION_ENABLED 0 66 #define CANVAS2D_HIBERNATION_ENABLED 0
67 67
68 // IOSurfaces are a primitive only present on OS X. 68 // IOSurfaces are a primitive only present on OS X.
69 // TODO(erikchen): Re-enable this after debugging for 69 #define USE_IOSURFACE_FOR_2D_CANVAS 1
70 // https://bugs.chromium.org/p/chromium/issues/detail?id=595754.
71 #define USE_IOSURFACE_FOR_2D_CANVAS 0
72 #else 70 #else
73 #define CANVAS2D_HIBERNATION_ENABLED 1 71 #define CANVAS2D_HIBERNATION_ENABLED 1
74 #define USE_IOSURFACE_FOR_2D_CANVAS 0 72 #define USE_IOSURFACE_FOR_2D_CANVAS 0
75 #endif 73 #endif
76 74
77 class PLATFORM_EXPORT Canvas2DLayerBridge : public WebExternalTextureLayerClient , public WebThread::TaskObserver, public RefCounted<Canvas2DLayerBridge> { 75 class PLATFORM_EXPORT Canvas2DLayerBridge : public WebExternalTextureLayerClient , public WebThread::TaskObserver, public RefCounted<Canvas2DLayerBridge> {
78 WTF_MAKE_NONCOPYABLE(Canvas2DLayerBridge); 76 WTF_MAKE_NONCOPYABLE(Canvas2DLayerBridge);
79 public: 77 public:
80 enum AccelerationMode { 78 enum AccelerationMode {
81 DisableAcceleration, 79 DisableAcceleration,
(...skipping 191 matching lines...) Expand 10 before | Expand all | Expand 10 after
273 // Each element in this vector represents an IOSurface backed texture that 271 // Each element in this vector represents an IOSurface backed texture that
274 // is ready to be reused. 272 // is ready to be reused.
275 // Elements in this vector can safely be purged in low memory conditions. 273 // Elements in this vector can safely be purged in low memory conditions.
276 Vector<ImageInfo> m_imageInfoCache; 274 Vector<ImageInfo> m_imageInfoCache;
277 #endif // USE_IOSURFACE_FOR_2D_CANVAS 275 #endif // USE_IOSURFACE_FOR_2D_CANVAS
278 }; 276 };
279 277
280 } // namespace blink 278 } // namespace blink
281 279
282 #endif 280 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698