https://bugs.webkit.org/show_bug.cgi?id=76239
Patch by Yongsheng Zhu <yongsheng.zhu@intel.com> on 2012-01-17
Reviewed by Kenneth Russell.
Clear the resources of DrawingBuffer but don't clear 'm_size'. This makes
's_currentResourceUsePixels' is not calculated correctly.
* platform/graphics/gpu/DrawingBuffer.cpp:
(WebCore::DrawingBuffer::clear):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@105233
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
+2012-01-17 Yongsheng Zhu <yongsheng.zhu@intel.com>
+
+ Clear 'm_size' of DrawingBuffer in the 'clear' function
+ https://bugs.webkit.org/show_bug.cgi?id=76239
+
+ Reviewed by Kenneth Russell.
+
+ Clear the resources of DrawingBuffer but don't clear 'm_size'. This makes
+ 's_currentResourceUsePixels' is not calculated correctly.
+
+ * platform/graphics/gpu/DrawingBuffer.cpp:
+ (WebCore::DrawingBuffer::clear):
+
2012-01-17 Philip Rogers <pdr@google.com>
Fix getBBox for perpendicular paths
return;
m_context->makeContextCurrent();
- if (!m_size.isEmpty())
+ if (!m_size.isEmpty()) {
s_currentResourceUsePixels -= m_size.width() * m_size.height();
+ m_size = IntSize();
+ }
if (m_colorBuffer) {
m_context->deleteTexture(m_colorBuffer);