Title: [176931] trunk/Source/WebCore
- Revision
- 176931
- Author
- [email protected]
- Date
- 2014-12-07 14:00:59 -0800 (Sun, 07 Dec 2014)
Log Message
[TextureMapper] Normalize pattern transform for pattern compositing
https://bugs.webkit.org/show_bug.cgi?id=139374
Reviewed by Martin Robinson.
In CoordGfx/TexMapGL, pattern compositing (for background image) uses
the patternTransform shader uniform. However, current implementation
miscalculates its transform matrix. It uses simple rectToRect
transformationMatrix which produces unnormalized garbage term.
This causes unexpected behavior at the fragmentation stage in some
mobile GPUs.
It should calculate its scale based on tileSize and contentSize,
and its position based on tilePhase and contentSize.
No new tests because the bug only occurs on some mobile GPUs.
* platform/graphics/texmap/TextureMapperLayer.cpp:
(WebCore::TextureMapperLayer::computePatternTransformIfNeeded):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (176930 => 176931)
--- trunk/Source/WebCore/ChangeLog 2014-12-07 20:05:17 UTC (rev 176930)
+++ trunk/Source/WebCore/ChangeLog 2014-12-07 22:00:59 UTC (rev 176931)
@@ -1,3 +1,25 @@
+2014-12-07 Gwang Yoon Hwang <[email protected]>
+
+ [TextureMapper] Normalize pattern transform for pattern compositing
+ https://bugs.webkit.org/show_bug.cgi?id=139374
+
+ Reviewed by Martin Robinson.
+
+ In CoordGfx/TexMapGL, pattern compositing (for background image) uses
+ the patternTransform shader uniform. However, current implementation
+ miscalculates its transform matrix. It uses simple rectToRect
+ transformationMatrix which produces unnormalized garbage term.
+ This causes unexpected behavior at the fragmentation stage in some
+ mobile GPUs.
+
+ It should calculate its scale based on tileSize and contentSize,
+ and its position based on tilePhase and contentSize.
+
+ No new tests because the bug only occurs on some mobile GPUs.
+
+ * platform/graphics/texmap/TextureMapperLayer.cpp:
+ (WebCore::TextureMapperLayer::computePatternTransformIfNeeded):
+
2014-12-07 Youenn Fablet <[email protected]>
[Soup][Curl] HTTP header values should be treated as latin1, not UTF-8
Modified: trunk/Source/WebCore/platform/graphics/texmap/TextureMapperLayer.cpp (176930 => 176931)
--- trunk/Source/WebCore/platform/graphics/texmap/TextureMapperLayer.cpp 2014-12-07 20:05:17 UTC (rev 176930)
+++ trunk/Source/WebCore/platform/graphics/texmap/TextureMapperLayer.cpp 2014-12-07 22:00:59 UTC (rev 176931)
@@ -99,7 +99,7 @@
m_patternTransformDirty = false;
m_patternTransform =
- TransformationMatrix::rectToRect(FloatRect(FloatPoint::zero(), m_state.contentsTileSize), m_state.contentsRect)
+ TransformationMatrix::rectToRect(FloatRect(FloatPoint::zero(), m_state.contentsTileSize), FloatRect(FloatPoint::zero(), m_state.contentsRect.size()))
.multiply(TransformationMatrix().translate(m_state.contentsTilePhase.x() / m_state.contentsRect.width(), m_state.contentsTilePhase.y() / m_state.contentsRect.height()));
}
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes